After Berlin AMM Enhancements and Information Layer API update to support JSON-RPC 2.0#86
Conversation
Signed-off-by: Christian Muehlbauer <christian.cm.muehlbauer@bmw.de>
…he persistence mode to file, satisfying the new required defaults. Signed-off-by: Christian Muehlbauer <christian.cm.muehlbauer@bmw.de>
* Update the messaging format between servers/clients to JSON-RPC 2.0 into the COVESA Knowledge Layer.
* Remove all tests that are not conpatible any more with the new JSON RPC 2.0 format.
Signed-off-by: Haonan Qiu <haonan.qiu@bmw.de>
* Allows strings or integer for the field id in IL request validator
* Applies method field to json message in KL
* Extract schema type e.g. Vehicle from data points list in txt file in the KL
* Fix missing class declaration in the constructor in KL
* Add implementation for root and format options on the GET endpoint in IL
* Apply format
* Apply format
* Add Test to cover all escenarios for the root and format functionality
* - Subscription state now includes request metadata (requestId, path, root, format) and stores them per client subscription.
- Replacement on same id: when a client subscribes again with the same requestId, the existing subscription is replaced (vin, datapoints, path, root, format updated).
- Updates now respect get‑style formatting: emitted data changes use stored root, format, path, and set response id to requestId.
- The Unsubscription method finds all matching subscriptions by filtering for both:
- VIN matching (message.instance)
- Exact datapoints (same count and all items match)
- Removes all matching subscriptions, if there were multiple subscriptions for the same VIN with identical datapoint sets, they'll all be removed.
- Cleans up correctly, if no subscriptions remain for the client, removes the websocket from the map.
- Some code optimation.
- Tests has updated for new fields and replacement behavior for subscription and unsubscription.
* Update the README with the current supported messages and parameters.
* Fix wrong default parameter for root into the message parameters
* Fix console message, when status message is received in the KL
---------
Update IL Readme to reflect the new API
Move ErrorMessage.ts content into NewMessage.ts where all other BO objects are defined.
- add DTOs for data, ok, and error responses
- map BOs to response DTOs
- propagate requestId into responses
- separate ok vs error handling in websocket server
Migrate IL websocket request messages to new API version.
* Add jsonrpc envelope to requests
* Add DTOs for request messages (GET/SET/SUBSCRIBE/UNSUBSCRIBE)
* Adjust validation for this DTOs
* Add DTO to BO mapper
Signed-off-by: Haonan Qiu <haonan.qiu@bmw.de>
…e efficient and stable. Signed-off-by: Christian Muehlbauer <christian.cm.muehlbauer@bmw.de>
Add documentation for adding certificate to knowledge layer docker file. Update documentation for using the services from the docker folder Signed-off-by: Christian Muehlbauer <christian.cm.muehlbauer@bmw.de>
|
Does this PR mean that the C4 Model needs to also be updated? |
|
In today's COVESA data architecture call @chrizmc explained that this PR is tested and running and ready for review |
There was a problem hiding this comment.
Hi,
Thanks for the PR!
Sanity testing of this PR to build and run KL/IL failed for me.
I hit two KL build issues:
- The Dockerfile does not support adding CA Certificates for internet fetches and so they failed in my corporate environment. This is documented as observation number 6 in my text notes on the original KL/IL code that @chrizmc attached to #77.
- The KL Dockerfile issue documented below related to the used Ubuntu version. See #88
Whilst it would be better if the Dockerfile supported adding CA Certificates I can see that the PR contains a tip in the docker Readme for how to resolve the issue. I think that is sufficient to merge.
The second build failure is not introduced by this code and instead already exists in the KL code. Using one of the workarounds in #88 allowed me to build. Did you do a clean build when you retested? If not, then it might explain why you did not see the issue. If yes, then more investigation may be needed.
Once built I could start the components.
I am aware there is a push to get this merged so the new KL/IL code can be based off it. As the changes are self-contained too those components I think we can do that if we can agree how to address the second issue.
There was a problem hiding this comment.
PR fails to build as Ubuntu 24.10 release is no longer available causing the next command to install pkgs to fail. 24.10 is an interim release. See #88
install cmake >= 3.30 required for CMP0167 policy
replace ubuntu:24.10 with ubuntu:24.04 LTS
Signed-off-by: Haonan Qiu <haonan.qiu@bmw.de>
|
Confirmed through local build that a3ac5de fixes the second build issue. Can now successfully build KL. It's an incomplete review on my part - for example an updated RDFox license has not been obtained to test the KL - as commented previously a new set of updates are coming soon. This PR also contains a fix to issue #88 which affects the existing code base as well as this. Taking into account that BMW report that they have successfully tested the PR and it is self-contained to the KL and IL components decision is made to merge. |
No description provided.