Do we still want the hardcoded metadata? I think it is ieasy enough to load a VSS model, and our containers ship with batteires included.
Furthermore, there seems to be a bug, were metadata is always loaded (I think the intention is to only do it, when --dummy-metadata is set, i.e. see
docker run -it --rm --net=host ghcr.io/eclipse/kuksa.val/databroker:master --insecure --port 55556
2023-09-22T23:00:16.960912Z INFO databroker: Init logging from RUST_LOG (environment variable not found)
2023-09-22T23:00:16.960937Z INFO databroker: Starting Kuksa Databroker 4d758d4967cfa6af583cab61457fd30c13499dbe
2023-09-22T23:00:16.960941Z INFO databroker: Populating (hardcoded) metadata <------- WHY?
2023-09-22T23:00:16.960968Z INFO databroker: Populating metadata from file 'vss_release_4.0.json'
2023-09-22T23:00:17.063353Z WARN databroker: Authorization is not enabled.
2023-09-22T23:00:17.063427Z INFO databroker::broker: Starting housekeeping task
2023-09-22T23:00:17.063436Z INFO databroker::grpc::server: TLS is not enabled
2023-09-22T23:00:17.063438Z INFO databroker::grpc::server: Authorization is not enabled.
2023-09-22T23:00:17.063453Z INFO databroker::grpc::server: Listening on 0.0.0.0:55556
Also I think, when the JSON is loaded it will not override (all) settings that may be in the hardcoded metadata, but I am not sure. as I was hacking on the JSON parsing anway (so my code might be buggy),
In any case IMO the cleanest "solution" here is getting rid of the hard coded metadata, as it is not a very obvious (helpful?) feature anyway
Do we still want the hardcoded metadata? I think it is ieasy enough to load a VSS model, and our containers ship with batteires included.
Furthermore, there seems to be a bug, were metadata is always loaded (I think the intention is to only do it, when
--dummy-metadata
is set, i.e. seeAlso I think, when the JSON is loaded it will not override (all) settings that may be in the hardcoded metadata, but I am not sure. as I was hacking on the JSON parsing anway (so my code might be buggy),
In any case IMO the cleanest "solution" here is getting rid of the hard coded metadata, as it is not a very obvious (helpful?) feature anyway