-
Notifications
You must be signed in to change notification settings - Fork 137
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
FELIX-6736 Emit properties in alphabetical order #345
base: master
Are you sure you want to change the base?
FELIX-6736 Emit properties in alphabetical order #345
Conversation
@cziegeler Please have a look, this test fails without sorting the keys first. |
bf51840
to
ab01dae
Compare
@@ -16,7 +16,7 @@ | |||
* specific language governing permissions and limitations | |||
* under the License. | |||
*/ | |||
@Version("1.0.0") | |||
@Version("1.1.0") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to increase the minor version here in order to ease depending on this fixed version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As you only changed internal behavior, package versions are not for "easing" anything but to allow semantic versioning so increasing the minor is wrong here.
@Version("1.1.0") | |
@Version("1.0.1") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a potentially backward incompatible semantical change (affecting consumers). Just a change which is not detected by baselining because the method signature did not change. Therefore adjusting the minor version is IMHO the right thing to do!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it affects consumers you need a major version bump.
ab01dae
to
fdaf9c6
Compare
It is expected that the tests fail, the configuration object preserves insertion order - if you read and write the same feature without changes, it should be identical (maybe minus whitespaces, indention). |
I just aligned with the logic from felix-dev/configadmin/src/main/java/org/apache/felix/cm/file/ConfigurationHandler.java Line 210 in 958c28d
|
ConfigurationHandler is not really a public API. The configuration writer is used for the various feature model implementations and it would be pretty annoying if it would destroy out of the sudden the order of things. So yes, opt-in makes sense to me. |
No description provided.