-
Notifications
You must be signed in to change notification settings - Fork 17
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
v3 - include context (& maybe specialValue) in series? #42
Comments
The series is a merely an additional json structure. I don't see a value add of putting the context into the series rather than directly into the (Process-)Measurement. Also, the Special Values are in that scope as well. So the a custom context could apply to them as well. |
Hmmm --- obviously I didn't got the concept behind it. From the standpoint of a sender or receiver - is any telegram that passes the schema valid? Or is the schema definition really only a syntactical thing without any additional significance? And it is part of the shared assumptions of a sender/receiver pair to define some kind of "grammar" how naming of series/specialValues/etc relates to each other? Or is this rule-set part of the unide specification, but not represented in the schema (e.g. as textual comments)? I tend to believe it could be useful to have something stricter than a pure naming convention - so the idea was to avoid the references by just putting the annotations into the series element (because there seems to be a 0..1-relationship anyway). Attention! Only guesswork: |
Hi @alaendle, |
Hello @ameinhardt, sorry if you got me wrong, I'm certainly not arguing against JSON schema. The idea was only to evolve the schema in a way that if a message is valid the chances it's also reasonable are high. With this mindset I wondered if it would be advisable to simplify the schema by avoiding the references from context-elements to a series-element by including the context-object in the series-object. E.g.:
might be changed to a structure like the following to avoid name mismatches/inconsistencies:
Since I now have recognized that specialValues are special to the process telegram and might include different series lets just focus on context for now. I'm aware of the trade-off to introduce an additional series-Object - on the other hand we avoid the redundant naming of the series (but since the context is optional this benefit not always takes effect). I just wanted to convey the idea. I hope I could clarify my intention now; if the proposal is conflicts with the PPMP design principles please close this issue. |
@alaendle, |
@ameinhardt I didn't get the redundancy argument - the current draft collects all context fields under an object with a series name - so where is redundancy created if this objects moves into the series (it will still be optional). The only redundancy I encounter is the overhead of the series object. To build up an example: v3-style:
proposal:
|
In my opinion that is too much flexibility to allow different namespaces even in different measurement points. I'd rather move it a level up to telegram level |
The schema should enforce the semantic of an telegram as good as possible - so I stumble over the context design where the key of a context "...shall be the name of a measurement point (element of series element)". This leaves room for interpretation - first a simple check of the schema could no longer determine if the content of a telegram is valid; second how should a recipient handle invalid context references - just ignore them or discard the whole message, or just store/forward them in/to 3rd party systems. So I wonder why you haven't created a series object that includes an optional context? My guess is that you want to be as much as possible backwards compatible with v2 - but since you introduce breaking changes anyway (e.g. mandatory/renamed time field) maybe it's time to reconsider this design decision. The same is true for special values - and maybe even things like data types could/should be encoded in a way that a schema check really validates a PPMP telegram.
The text was updated successfully, but these errors were encountered: