-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Updated documentation as per Jira HHH-15049 #4898
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
Conversation
|
Thanks for your pull request! This pull request appears to follow the contribution rules. › This message was automatically generated. |
|
It would be great to tweak your git commit message to start with "HHH-15049". |
|
@NathanQingyangXu - Updated commit message to start with |
@beikov could you take a look? Seems a good catch! |
|
This is a bit more complicated I think as the default value depends on whether Hibernate is bootstrapped via JPA or via the Hibernate native boot API. The default value for JPA boot is Whereas So IMO we should adapt the documentation to make this clear. Wdyt @sebersole and @dreab8? |
|
@beikov yeap I agree with you that it would be better if the documentation mentioned that for JPA boot this setting is ignored and the value is always false. |
I saw it is set to TRUE by default in Line 320 in 9e9a813
Is it true that the default value depends on whether it is in JPA boot mode or Hibernate mode? |
Hold on. I think the configuration we are talking about is Hibernate specific and it should be TRUE by default; for JPA compliance configuration, we have a separate suite. Maybe we need to add a new entry as following in the JPA Compliance section (https://docs.jboss.org/hibernate/orm/current/userguide/html_single/Hibernate_User_Guide.html#configurations-jpa-compliance) and set its default value to FALSE.
@sebersole how do you think? |
|
@NathanQingyangXu for Jpa bootsrapping the |
|
Thanks for letting me know. So the default value is true for non-jpa boot,
right? Should we update the doc and how?
…On Thu., Apr. 28, 2022, 4:17 a.m. Andrea Boriero, ***@***.***> wrote:
@NathanQingyangXu <https://github.com/NathanQingyangXu> for Jpa
bootsrapping the EntityManagerFactoryBuilderImpl
<https://github.com/hibernate/hibernate-orm/blob/main/hibernate-core/src/main/java/org/hibernate/jpa/boot/internal/EntityManagerFactoryBuilderImpl.java#L256>
is executed first and then SessionFactoryOptionsBuilder
<https://github.com/hibernate/hibernate-orm/blob/9e9a8135dc705a7fc5e5154e89fd11465f5f6589/hibernate-core/src/main/java/org/hibernate/boot/internal/SessionFactoryOptionsBuilder.java#L320>
so the value of flushBeforeCompletionEnabled is always false
—
Reply to this email directly, view it on GitHub
<#4898 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AB6UYAR7YFHJWYQD7F7KLKDVHJCSJANCNFSM5RMELPAQ>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
|
Maybe I misunderstood. Anyway.
On Thu., Apr. 28, 2022, 12:24 p.m. Nathan Xu, ***@***.***>
wrote:
… Thanks for letting me know. So the default value is true for non-jpa boot,
right? Should we update the doc and how?
On Thu., Apr. 28, 2022, 4:17 a.m. Andrea Boriero, <
***@***.***> wrote:
> @NathanQingyangXu <https://github.com/NathanQingyangXu> for Jpa
> bootsrapping the EntityManagerFactoryBuilderImpl
> <https://github.com/hibernate/hibernate-orm/blob/main/hibernate-core/src/main/java/org/hibernate/jpa/boot/internal/EntityManagerFactoryBuilderImpl.java#L256>
> is executed first and then SessionFactoryOptionsBuilder
> <https://github.com/hibernate/hibernate-orm/blob/9e9a8135dc705a7fc5e5154e89fd11465f5f6589/hibernate-core/src/main/java/org/hibernate/boot/internal/SessionFactoryOptionsBuilder.java#L320>
> so the value of flushBeforeCompletionEnabled is always false
>
> —
> Reply to this email directly, view it on GitHub
> <#4898 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AB6UYAR7YFHJWYQD7F7KLKDVHJCSJANCNFSM5RMELPAQ>
> .
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
|
| `*hibernate.transaction.flush_before_completion*` (e.g. `true` (default value) or `false` ):: | ||
| Causes the session be flushed during the before completion phase of the transaction. If possible, use built-in and automatic session context management instead. |
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 think the following would be better
| `*hibernate.transaction.flush_before_completion*` (e.g. `true` (default value) or `false` ):: | |
| Causes the session be flushed during the before completion phase of the transaction. If possible, use built-in and automatic session context management instead. | |
| `*hibernate.transaction.flush_before_completion*` (e.g. `true` (Hibernate boot default value) or `false` (JPA boot default value) ):: | |
| Causes the session be flushed during the before completion phase of the transaction. If possible, use built-in and automatic session context management instead. When Hibernate is link:https://docs.jboss.org/hibernate/orm/current/quickstart/html_single/#hibernate-gsg-tutorial-basic-test[booted through the native API], the default value is `true`, otherwise `false`. |
|
We now generate these docs from the javadoc, where this setting is documented correctly. |
No description provided.