Skip to main content



      Home
Home » Eclipse Projects » EclipseLink » Documentation for refresh.cascade query hint(Can someone explain to me what the various options do, exactly?)
Documentation for refresh.cascade query hint [message #1840407] Wed, 14 April 2021 12:05 Go to next message
Eclipse UserFriend
I found the following query hints for the refresh.cascade query hint, but I'm having a hard time finding a good explanation of the implications of choosing one over another.

The best hit I found was at
https://docs.oracle.com/middleware/1212/toplink/TLJPA/q_refresh_cache.htm#TLJPA1056


Table 4-37 Valid Values for eclipselink.refresh.cascade
Value	                                          Description
CascadeAllParts	                 Cascade to all associations.
CascadeByMapping	         Cascade by mapping metadata.
CascadePrivateParts	         Cascade to privately-owned relationships.
NoCascade	                         Do not cascade.



The NoCascade option is clear to me, but the others are not.

Re: Documentation for refresh.cascade query hint [message #1840569 is a reply to message #1840407] Mon, 19 April 2021 10:02 Go to previous messageGo to next message
Eclipse UserFriend
These are with the EclipseLink (TopLink) api. Since this is applied to queries, the CascadeAllParts tells it to apply the current operation (write, refresh etc) to the entire object graph it is given, ignoring any cascade options set on individual mappings.
CascadeByMapping is the default in JPA queries, and has the query look at the object graph and traverse it, letting the mappings decide if it should cascade the operation further or not.
CascadePrivateParts is more restrictive and only looks at what are known as private mappings (aka embedded in JPA), and will only cascade to those mappings from the base object in the query, regardless of mapping settings.

Best Regards,
Chris
Re: Documentation for refresh.cascade query hint [message #1840571 is a reply to message #1840569] Mon, 19 April 2021 11:16 Go to previous messageGo to next message
Eclipse UserFriend
Thank you, Chris
Re: Documentation for refresh.cascade query hint [message #1840572 is a reply to message #1840571] Mon, 19 April 2021 11:16 Go to previous message
Eclipse UserFriend
Thank you, Chris
Previous Topic:Trying to send array of objects on json
Next Topic:DYNAMIC ENTITY SERIALIZATION ISSUE
Goto Forum:
  


Current Time: Wed Jul 02 17:00:27 EDT 2025

Powered by FUDForum. Page generated in 0.05356 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top