Updates on migration topics Java/Node#2696
Merged
Merged
Conversation
sjvans
reviewed
Jul 3, 2026
Co-authored-by: sjvans <30337871+sjvans@users.noreply.github.com>
Contributor
Author
|
I'll merge this for now, but @agoerler please follow up if needed |
renejeglinsky
commented
Jul 3, 2026
| By default, any kind of first interaction with the Persistence Service will begin the transaction. Once a transaction has been started, a connection for that transaction is reserved from the connection pool. This connection is only returned to the connection pool on commit or rollback of the transaction. | ||
|
|
||
| However, `READ` events which run simple Select queries don't actually require transactions in most cases. When setting the property `cds.persistence.changeSet.enforceTransactional` to `false` most Select queries do not cause a transaction to be started any longer. A connection for these queries is obtained from the connection pool and returned immediately after executing the queries on the database. This can increase throughput of an application, by making connections available for concurrent requests faster. As soon as a modifying statement is executed on the Persistence Service, a transaction is started. All subsequent Select queries will participate in that transaction. Note, that this behaviour is only transparent when using the default transaction isolation level "Read Committed". | ||
| However, `READ` events which run simple Select queries don't actually require transactions in most cases. As the property `cds.persistence.changeSet.enforceTransactional` is `false` by default, most Select queries do not cause a transaction to be started any longer. A connection for these queries is obtained from the connection pool and returned immediately after executing the queries on the database. This can increase throughput of an application, by making connections available for concurrent requests faster. As soon as a modifying statement is executed on the Persistence Service, a transaction is started. All subsequent Select queries will participate in that transaction. Note, that this behaviour is only transparent when using the default transaction isolation level "Read Committed". |
Contributor
Author
There was a problem hiding this comment.
@agoerler please check this one if this is sufficient
renejeglinsky
commented
Jul 3, 2026
| In that case you can use the annotation `@requires: 'any'` on service-level to make the service and its entities public again. | ||
| You can only make an endpoint public if the full endpoint path is also considered public. | ||
| For example you can only make an entity public, if the service that contains it is also considered public. | ||
| By default the authentication mode is set to `model-relaxed`. |
Contributor
Author
There was a problem hiding this comment.
@BraunMatthias Please check if we need to adapt more on that.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
These are some findings. Please use that as a trigger to check if more details around those changes are needed.