-
Notifications
You must be signed in to change notification settings - Fork 169
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
Hypersistentence Optimizer reports an issue marked as blocker #2204
Comments
@chrisknoll I believe it is seeing the following in DataAccessConfig and suggest it be set to true.
Setting this to true sets the hibernate strategy to leverage org.hibernate.id.enhanced.SequenceStyleGenerator which i see is set for each Generator defined in code base. So this might be a false positive since you are using SequenceStyleGenerator everywhere. Updating the above to removes the issue from being raised in Hypersistence Optimizer report.
|
So, this commit what added that line. This was done in 2017, but is related to updating to hibernate 5.0.12. I believe that this was necessary because of the information included in your report:
I do recall something related with HiLo sequencers that were in use prior to moving completely to Edit:
Edit 2: I suppose the positive finding here is that we captured the legacy of this code in github issues and PRs, so I'm glad we can find the reasons and history behind these changes. |
I'll submit PR for setting value to true. |
Expected behavior
No issues should be listed as blocker.
Actual behavior
When analysis application with Hypersisitance Optimizer, it points out the following:
BLOCKER - PooledSequenceOptimizerEvent - You should set the [hibernate.id.new_generator_mappings] configuration property to the value of [true], as Hibernate can then use the pooled or pooled-lo identifier optimizers for sequence-based entity identifiers. Note that the pooled and pooled-lo optimizers are not backward compatible with the legacy hilo optimizer that you might have used with Hibernate ORM 3 or 4. So, if you were using the hilo optimizer, then you would need to increase the current sequence number so that is greater than any previously allocated entity identifiers. For more info about this event, check out this User Guide link - https://vladmihalcea.com/hypersistence-optimizer/docs/user-guide/#PooledSequenceOptimizerEvent
Steps to reproduce behavior
Run analysis with Hypersisitance Optimizer against a application test that uses SportBootTest that application
The text was updated successfully, but these errors were encountered: