Define and verify behavior of schema extension properties#736
Conversation
|
Draft for now. The bnd plugin does not like the overridden methods where a type parameter is specified in
This may be a bug in the plugin, but we'll need to resolve this somehow. @Azquelt before I make any TCK changes, can you please take a look at the JavaDoc changes and let me know if you catch anything that conflicts with the intent of #698 ? |
|
How odd. Ordinarily I would trust the bnd baseline checker, but here it seems wrong. Generally, changing a method's return type (which confusingly we are doing here, after erasure it used to return However, the compiled interface seems to still include the method signature returning Output from Given this, I'm unsure why the bnd baseline tool reports the method as having been removed. It looks like the Possibly that's why the bnd baseline plugin ignores them? Needs more looking into |
|
The plugin supports a way to ignore particular elements for baselines earlier than a specified version (second commit). This seems like a reasonable work-around to me. |
|
Do we still need a minor package version bump? You could have a |
I'm not entirely sure. |
Yeah, I think so, and the previous version wouldn't require that (you could get away with |
Signed-off-by: Michael Edgar <michael@xlate.io>
Add `BaselineIgnore` annotation to Schema methods addExtension and extensions for versions prior to 4.2.0. These methods were added/overridden in Schema from Extensible to refine/clarify specific details about how they behave on Schema. This is required because the bnd-baseline Maven plugin believes these methods to be breaking API changes due to the change of return type from a generic type in `Extensible` to `Schema` in the overrides. Signed-off-by: Michael Edgar <michael@xlate.io>
Signed-off-by: Michael Edgar <michael@xlate.io>
|
The last commit adds the version bump to the package. Let me know if you spot anything incorrect with the docs and I'll try to get the TCK updates pushed later today to align with that. |
Signed-off-by: Michael Edgar <michael@xlate.io>
|
Tests look good, my only concern is around whether we're correct about the baseline plugin being wrong. Do you think we should raise a defect for that? Worst case we get an explanation of why the plugin is actually right. |
|
If it were actually somehow a breaking change for consumers, we could just not override the extension methods on |
|
Based on the comments from the bnd issue, I'm happy to approve this. |
Closes #698