Default display name format changed from version 4.x.x to 5.x.x
Hello everyone,
we encountered an issue when migrating from 4.2.0 to 5.x.x due to changes in the display name format. The new plugin configuration introduces the "Enable New Data Format" setting, which can be switched on or off.
Behavior:
-
Enable New Data Format = unchecked:
- Display name changes from
<AF-Attribute-Name>to<AF-Element><pipe><AF-Attribute-Name>. - Example:
- In version 4.2.0:
pressure - In version 5.x.x:
pump|pressure
- In version 4.2.0:
- Display name changes from
-
Enable New Data Format = checked:
- Display name changes from
<AF-Attribute-Name>to<AF-Attribute-Name> {element=<AF-Element> name=<AF-Attribute-Name> type=...}. - Example:
- In version 4.2.0:
pressure - In version 5.x.x:
pressure {element=pump name=pressure type=...}
- In version 4.2.0:
- Display name changes from
Issues: The following problems occurred when testing both options:
- Field overrides by name in panel configuration no longer work as expected.
- Referencing fields in standard panel transformations fails.
- Series names changed in histograms, legends, ...
- ...
Expected Behavior:
We expected Enable New Data Format=unchecked to keep the exact display name format from version 4.2.0 for backward compatibility.
Was it intentional that the unchecked option differs from the old format? If not, can this be fixed in a future patch?
Dear @coderReview I'd be really grateful if you could take a look. Thank you so much in advance!
@asenfter I am not planning to move back to the old format in 4.2.0.
Hi @coderReview thank for the answer. Do you consider merging a PR with possibility of enabling attribute name compatibility with version 4.x ?
This could work in following way:
- Custom Configuration section will receive a new option - "Enable attribute name backward compatibility"
- If the option enabled and an option "Enable new data format" is disabled, then backend will send
{"name": "pressure"}instead of{"name": "pump|pressure"}
We could work on a PR if there are chances to add the functionality to version 5 of the plugin.
@malaman feel free to provide the PR. This is an opensource project. More contributions the better.