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

Add streaming parser #22

Closed
wants to merge 18 commits into from
Closed

Add streaming parser #22

wants to merge 18 commits into from

Conversation

andig
Copy link
Contributor

@andig andig commented Feb 26, 2025

Fix #19

This PR adds a streaming reveicer and parser to handle RCT messages asynchronously. It has the following changes:

  • connection continuously reads incoming data
  • data is continuously being parsed by channel-based ParseAsync
  • async parser adds support for long messages that didn't fit the buffer size before
  • responses are cached for use with the synchronous Get api (to be removed?)
  • the synchronous Query/Get api is complemented by channel-based Subscribe/Unsubscribe
  • connection cache is removed- it's no longer needed
  • legacy sychronous Parser is deprecated

TODO

  • deduplicate legacy parser code
  • decide async api removal (including the cache)
  • make broker private
  • make QueryXYZ connection methods global

Since this PR breaks the existing API, it should be behind a v2 version.

@andig andig marked this pull request as ready for review March 1, 2025 14:52
@andig andig marked this pull request as draft March 1, 2025 14:52
@andig
Copy link
Contributor Author

andig commented Mar 1, 2025

@mlnoga wdyt regarding v2? If that's still an option for you we could finally move v2 to evcc-io and make the breaking change via new url.

@andig
Copy link
Contributor Author

andig commented Mar 14, 2025

ping @mlnoga any thoughts?

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

Successfully merging this pull request may close these issues.

Add async handling
1 participant