This document discusses semantic versioning for APIs and applications. It explains that the major, minor, and micro parts of a semantic version number indicate different levels of backward compatibility. A higher major version means the API is not backward compatible, a higher minor version means the API is backward compatible for consumers but not providers, and a higher micro version does not impact backward compatibility. It also mentions some tools for implementing semantic versioning.
3. Semantic Versioning
Version=1.0.0
Application
Consumer API Provider
Version=1.0.0 Version=1.0.0
4. Semantic Versioning
Version=1.0.1
Version=1.0.0
Application
Consumer API Provider
1
Version=1.0.0 Version=1.0.0
Version=1.0.1
1 API Bugfix (in Exported Packages).
E.g. JavaDoc change, Method parameter rename, …
5. Semantic Versioning
Version=1.0.2
Version=1.0.0
Application
Consumer API Provider
1
Version=1.0.0 Version=1.0.1
Version=1.0.2
1 Provider internal change.
E.g. bugfix in the class ServiceImpl.
6. Semantic Versioning
Version=1.0.3
Version=1.0.2
Application
Consumer API Provider
1
Version=1.0.0 Version=1.0.2
Version=1.0.1
1 Consumer internal change.
E.g. bugfix in the class MyListener.
7. Semantic Versioning
Version=1.1.0
Version=1.0.3
Application
Consumer API Provider
1
Version=1.0.1 Version=1.0.2
Version=1.1.0
1 API backward compatible change.
E.g. add a method to service class.
8. Semantic Versioning
Version=2.0.0
Version=1.0.3
Application
Consumer API Provider
1
Version=1.0.1 Version=1.1.0
Version=1.0.2 Version=2.0.0
1 API not backward compatible
e.g. add a method to the Listener class.
9. Semantic Versioning
• Major
Must be increase if the changes effects providers as well as consumers.
• Minor
Must be increase if the changes are backward compatible for the
consumers, but not backward compatible for the providers.
• Micro
A difference in micro part does not signal any backward compatibility
issues.
• Qualifier
The qualifier is used to indicate a build.
For more details see the “ OSGi Technical Whitepaper about Semantic
Versioning”
10. Tools
• Bnd / Bndtools Semantic Versioning for OSGi
based Applications
http://bndtools.org/
• Semantic Versioning for Jars and Maven
https://github.com/jeluard/semantic-
versioning