AWS IoT Events
Developer Guide

Troubleshooting AWS IoT Events

Use the following information to troubleshoot common issues in AWS IoT Events.

I deleted or updated a detector model a few minutes ago. Why am I still getting state updates from the old detector model via MQTT messaging or SNS alerts?

If you update or republish a detector model (see UpdateDetectorModel), there is some delay before all spawned detectors (instances) are deleted and the new model is used to recreate the detectors. They will be recreated when the new detector model takes effect and as new inputs arrive. During this time, inputs might continue to be processed by the detectors spawned by the previous version of the detector model. You might continue to receive alerts defined by the previous detector model during this period. Wait for at least seven minutes before you recheck the deletion or update, or before you report an error.

I specified an event to trigger an action (or transition to a new state), but the action (transition) doesn't happen when the condition is met.

Check your event's condition expression to verify that the result of the evaluation of the expression is a Boolean value. If the result isn't a Boolean value, it's equivalent to false and won't trigger the actions or transition to the nextState specified in the event.

I'm getting errors when creating a detector model.

Keep the following limitations in mind when creating a detector model.

  • Only one action is allowed in each action field.

  • The condition is required for transitionEvents. It's optional in other cases.

  • If the condition field isn't present, it's equivalent to "condition": true.

  • The result of the evaluation of a condition expression should be a Boolean value. If the result isn't a Boolean value, it's equivalent to false and won't trigger the actions or transition to the nextState specified in the event.

I defined a condition to trigger an event or a transition event when a variable reaches a certain value, but it doesn't work (or doesn't work until the value of the variable is more or less than I expect).

If the value of a variable is set (setVariable) in any event defined within an onInput, onEnter or onExit field, its new value isn't used when evaluating any condition during that processing cycle (that is, during the processing of the input, or during entry or exit). Instead, the current value (if any) is used throughout that cycle.

You can change this behavior by setting the evaluationMethod parameter in the detector model definition. When evaluationMethod is set to SERIAL, variables are updated and event conditions evaluated in the order that the events are defined. When set to BATCH (the default), variables are updated and events performed only after all event conditions are evaluated.

My detectors are entering the wrong states given the inputs (messages) they ingest.

If you send multiple messages to inputs using BatchPutMessage, the order in which the messages/inputs are processed isn't guaranteed. To guarantee ordering, send messages one at a time and wait each time for BatchPutMessage to acknowledge success.

When I call (invoke) an API, I get a 'Connection aborted' error.

If you are using TLS 1.0 to establish the connection, you might see an error like the following.

('Connection aborted.', error(54, 'Connection reset by peer'))

Verify that OpenSSL is using TLS 1.1 or TLS 1.2. This should already be the default under most Linux distributions or Windows version 7 and later. Users of macOS might need to upgrade OpenSSL. For more information, see How to upgrade OpenSSL (macOS).