Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trigger reported not found even though registered (also not shown in GUI) - Possible issue with triggertypes limit? #1034

Open
TimothyDJones opened this issue Feb 18, 2025 · 1 comment

Comments

@TimothyDJones
Copy link

TimothyDJones commented Feb 18, 2025

SUMMARY

Some of the triggers that are properly registered report as "Trigger is missing" in their associated rules. Likewise, clicking on the link to trigger from the rule opens an empty display in the "Triggers" view. Furthermore, the trigger is not listed in the list of triggers in the "Triggers" view.

The problem seems to be related to the implicit limit of 100 items in triggertypes API results.

Image

STACKSTORM VERSION

Paste the output of st2 --version: st2 3.8.1, on Python 3.8.17

OS, environment, install method

Rocky Linux: Linux version 4.18.0-553.27.1.el8_10.x86_64 ([email protected]) (gcc version 8.5.0 20210514 (Red Hat 8.5.0-22) (GCC)) #1 SMP Wed Nov 6 14:29:02 UTC 2024

Regular standalone install with co-hosted Mongo DB, Redis, and Rabbit MQ.

Steps to reproduce the problem

To observe the problem:

  1. Open ANY rule which has an associated (properly registered) trigger for which the trigger is NOT listed in the available triggers in the "Triggers" view. (Note: This problem only appears to happen if MORE THAN 100 triggers are registered on the system.)
  2. The rule will display the trigger as a hyperlink, but with the notation "Trigger is missing".
  3. Clicking on the hyperlinked trigger opens an empty view in the "Triggers" section. Likewise, the subject trigger cannot be found by name/reference in the list of triggers in the "Triggers" section.

Expected Results

Expected that, since the trigger is properly registered, it would be displayed in the "Triggers" section, along with instances.

Actual Results

See above.

NOTE: When executing observing the response to the triggertypes API call in the ST2 GUI via the browser web developer tools (https://st2host/api/v1/triggertypes), the number of results returned in exactly 100. However, when re-running the API (directly via browser tools or via cURL) with limit=-1 (https://st2host/api/v1/triggertypes?limit=-1), significantly more results (in our case, 144) are returned, including the trigger that had been flagged/notated as "Trigger is missing".

@TimothyDJones TimothyDJones changed the title Trigger reported not found even though registered (also not shown in GUI) - Possible issue with triggertype limit? Trigger reported not found even though registered (also not shown in GUI) - Possible issue with triggertypes limit? Feb 18, 2025
@nzlosh nzlosh transferred this issue from StackStorm/st2 Feb 21, 2025
@nzlosh
Copy link
Contributor

nzlosh commented Feb 21, 2025

Thank you for this detailed report. I agree with your conclusion that st2web isn't providing the limit value to the API causing missing items in the display. A patch to address this issue would be most welcomed if you're willing and able.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants