Releases: ssaarela/javersion
Releases · ssaarela/javersion
Reflection fixes
Minor improvements to reflection toString and error messages
v0.15.2 Release 0.15.2: minor fixes
Reflection exceptions and toStrings
- Improved exception handling: add context to ReflectionExceptions
- Improve Descriptors’ toString methods
- Fix TypeDescriptors cache
Reflection Improvements
- Use byte code inspection as fallback to get parameter names.
- Expose JavaMemberDescriptor.getElement
- Rename too generic Property to AccessibleProperty
- Getters for visibility modifiers
JDBC Persistence Optimization
New Features
- JDBC VersionStore
- VersionGraph load optimization
- Configurable when and what (versions) to optimize - default is not to optimize anything
- Documents are automatically optimized in background when needed
- Configurable Executor for optimizations: ASYNC, SYNC, NONE or custom
- Automatic publishing
- Configurable executor: ASYNC, SYNC, NONE or custom
- Configurable cache
- Guava Cache based implementation
- Configurable compaction strategy (when and what)
- PostgreSQL specific optimizations
- javersion-jdbc/src/test/resources/db/migration/postgresql
- Querydsl SQLTemplates:
org.javersion.store.jdbc.PostgreSQLTemplatesForNoKeyUpdate
- VersionGraph load optimization
Breaking Changes
- Core
- VersionGraph as an interface with simplified generic signature: <K, V, M> (key, value, meta)
- Switch Revision(node, timeSeq) constructor parameters: Revision(timeSeq, node) that is more in sync with serialization
- JDBC
- Interface for VersionStore with simplified generic signature: <Id, M> (id-type, meta)
- Rename VersionStore load* methods to get*Graph
getFullGraph(docId)- load full (original/unoptimized) VersionGraphgetOptimizedGraph(docId)- load optimized VersionGraphgetGraph(docId)- load VersionGraph using the fastest method available (e.g. cache)getGraph(docId, revisions)- as getGraph(Id) but fallback to getFullGraph if all revisions are not found
- Interface for UpdateBatch with simplified generic signature: <Id, M>
- Rename module
javersion-spring-jdbctojaversion-jdbc - Make Spring dependency optional
- Configurable
Transactionsinterface withSpringTransactionsimplementation instead of@Transactional
- Configurable
- Database schema changes
REPOSITORYtable is no longer needed - version rows locked insteadVERSION_TYPEtable is no longer needed - uses check constraint instead- Status column added to all tables
- Changes to column types and indexes
- Options
repositoryandrepositoryNameare dropped from StoreOptions
Update Querydsl from 3 to 4
Release 0.13.0 Update Querydsl from 3 to 4
Fix PropertyPath parser for escaped forward slash
v0.12.1 Patch release 0.12.1: fix property path parser
Object mapping: delegates and configurable annotation handler
- Configurable search path for annotation/reflection based configurations
- Delegate mapping with @VersionValue/@jsonvalue and @VersionCreator/@JsonCreator: use alternate representation for versioning (e.g. String)
- Functional se key mapping with @setkey(by=Class<? extends Function>)
- Support for rebasing commits: analyse changes based on original base but then rebase new version on top of latest head(s). This creates linear version history which is more efficient (less/simpler merging) than having multiple concurrent versions, but it sweeps conflicts under the rug.
Bean Properties, Constructor Injection and Composite Keys
@VersionPropertyannotation on a getter with matching setter makes Java Bean property (get/is/set) versionable.- Value of
@VersionPropertycan be used to rename versionable property to other than default field/property name. - Algorithmic identifiers with
@Idon a getter without matching setter. - Constructor injection with
@VersionConstructoror Jackson's@JsonCreator(optional dependency). - Constructor parameter names with
@Param,javac -parametersor Jackson's@JsonProperty. - Composite key for a Set with
@SetKeyannotation on a field/getter or element type. - Improved support for generics: generic field, method and parameter types are resolved against owner type.