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

StreamManager KeyError #15

Open
THEhEROLocker opened this issue Sep 10, 2021 · 0 comments
Open

StreamManager KeyError #15

THEhEROLocker opened this issue Sep 10, 2021 · 0 comments

Comments

@THEhEROLocker
Copy link

ERROR:StreamManagerClient:Unhandled exception occurred
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/greengrasssdk/stream_manager/streammanagerclient.py", line 201, in __read_loop
    await self.__handle_read_response(payload, response)
  File "/usr/local/lib/python3.8/site-packages/greengrasssdk/stream_manager/streammanagerclient.py", line 226, in __handle_read_response
    await self.__requests[response.request_id].put(response)
KeyError: '3e299203-e8a6-4341-ac86-e1db7eae1636'
{"message": "Unhandled exception occurred", "exc_info": "Traceback (most recent call last):\n  File \"/usr/local/lib/python3.8/site-packages/greengrasssdk/stream_manager/streammanagerclient.py\", line 201, in __read_loop\n    await self.__handle_read_response(payload, response)\n  File \"/usr/local/lib/python3.8/site-packages/greengrasssdk/stream_manager/streammanagerclient.py\", line 226, in __handle_read_response\n    await self.__requests[response.request_id].put(response)\nKeyError: '3e299203-e8a6-4341-ac86-e1db7eae1636'"}
ERROR:root:error writing data to stream manager
{"message": "error writing data to stream manager"}

Current Setup:
Streaming a small amount of IOT sensor data(250 events a minute) through StreamManager for extended periods of time.

The stack ran in a healthy state for around 18 hours after which all events to Kinesis stopped when we saw this error in the logs. A restart of the component containing the stream manager client did not fix the problem. A full restart of greengrass with systemd fixed it and events were again flowing all the way to Kinesis.

How do we handle this issue? Appreciate any help on this.

Stream Manager Client Config

  exports = ExportDefinition(kinesis=[KinesisConfig(identifier="KinesisExport" + self.stream_name, kinesis_stream_name=kinesis_stream_name,  batch_size=250)] )

  MessageStreamDefinition(name=self.stream_name, strategy_on_full=StrategyOnFull.OverwriteOldestData, persistence=Persistence.File, flush_on_write=True, export_definition=exports)
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

1 participant