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

EV369b: drop update transactional messages if necessary #285

Merged
merged 9 commits into from
Dec 6, 2023

Conversation

klemmpnx
Copy link
Contributor

Part II of EV-369: drop transaction update messages if necessary:

  • Slight refactoring if ControlMessage template
  • Heuristic implementation to drop every second update message (does not consider transaction ids, but should be fine for a realistic use case; stop/end transaction events are never dropped) ; behavior is also be explained by unit test

…nt dropping non-transactional; tests

- Extract MessageQueue config into dedicated struct
- add parameters for limiting queue size and Queueing all message types
- add check for message sizes and removal logic
- restructure unit tests (common executuable)

Signed-off-by: Fabian Klemm <[email protected]>
Signed-off-by: Fabian Klemm <[email protected]>
Signed-off-by: Fabian Klemm <[email protected]>
Signed-off-by: Fabian Klemm <[email protected]>
Signed-off-by: Fabian Klemm <[email protected]>
@klemmpnx klemmpnx requested a review from hikinggrass November 29, 2023 16:38
@klemmpnx klemmpnx self-assigned this Nov 29, 2023
Copy link
Contributor

@hikinggrass hikinggrass left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 pretty much just the missing license header

Co-authored-by: Kai Hermann <[email protected]>
Signed-off-by: corneliusclaussen <[email protected]>
Base automatically changed from feature/fk-ev369-message-queue-buffering to main December 6, 2023 16:30
…messages

Signed-off-by: Fabian Klemm <[email protected]>

# Conflicts:
#	include/ocpp/common/message_queue.hpp
#	lib/ocpp/v16/charge_point_impl.cpp
#	lib/ocpp/v201/charge_point.cpp
#	tests/lib/ocpp/common/test_message_queue.cpp
@klemmpnx klemmpnx merged commit bb11e09 into main Dec 6, 2023
@klemmpnx klemmpnx deleted the feature/fk-ev369b-drop-update-transactional-messages branch December 6, 2023 16:46
couryrr-afs pushed a commit to US-JOET/libocpp that referenced this pull request Dec 18, 2023
* MessageQueue: add config struct; add parameters for queueing; implement dropping non-transactional; tests

- Extract MessageQueue config into dedicated struct
- add parameters for limiting queue size and Queueing all message types
- add check for message sizes and removal logic
- restructure unit tests (common executuable)

Signed-off-by: Fabian Klemm <[email protected]>

* add v201 config var for queue size threshold

Signed-off-by: Fabian Klemm <[email protected]>

* add queue config parameters

Signed-off-by: Fabian Klemm <[email protected]>

* remove temporary tests

Signed-off-by: Fabian Klemm <[email protected]>

* add missing test resources

Signed-off-by: Fabian Klemm <[email protected]>

* clang format

Signed-off-by: Fabian Klemm <[email protected]>

* EV269 Part II: drop transaction update events if necessary

Signed-off-by: Fabian Klemm <[email protected]>

* Update tests/lib/ocpp/common/test_message_queue.cpp

Co-authored-by: Kai Hermann <[email protected]>
Signed-off-by: corneliusclaussen <[email protected]>

---------

Signed-off-by: Fabian Klemm <[email protected]>
Signed-off-by: corneliusclaussen <[email protected]>
Co-authored-by: corneliusclaussen <[email protected]>
Co-authored-by: Kai Hermann <[email protected]>
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.

3 participants