import org.hibernate.engine.spi.SessionImplementor;
import org.hibernate.engine.spi.Status;
import org.hibernate.engine.spi.TypedValue;
+import org.hibernate.internal.CoreLogging;
+import org.hibernate.internal.CoreMessageLogger;
import org.hibernate.internal.SessionFactoryRegistry;
import org.hibernate.internal.util.MarkerObject;
import org.hibernate.internal.util.collections.EmptyIterator;
* @author Cherian Mathew
*/
public abstract class AbstractPersistentCollection implements Serializable, PersistentCollection {
- private static final Logger log = Logger.getLogger( AbstractPersistentCollection.class );
+ private static final CoreMessageLogger LOG = CoreLogging.messageLogger( AbstractPersistentCollection.class );
/**
* <b>IMPORTANT:</b><br>
// In remoting we are sure that session is null
// both when using property paths and switching off conversations
if(session == null && remoting) {
- log.info("--> readSize, of " + getRole() + " with key " + getKey());
+ LOG.info("--> readSize, of " + getRole() + " with key " + getKey());
read();
} else {
boolean isExtraLazy = withTemporarySessionIfNeeded(
( (Session) session ).close();
}
catch (Exception e) {
- log.warn( "Unable to close temporary session used to load lazy collection associated to no session" );
+ LOG.warn( "Unable to close temporary session used to load lazy collection associated to no session" );
}
session = originalSession;
}
// In remoting we are sure that session is null
// both when using property paths and switching off conversations
if(session == null && remoting) {
- log.info("--> readIndexExistence, of " + getRole() + " with key " + getKey());
+ LOG.info("--> readIndexExistence, of " + getRole() + " with key " + getKey());
read();
} else {
Boolean extraLazyExistenceCheck = withTemporarySessionIfNeeded(
// In remoting we are sure that session is null
// both when using property paths and switching off conversations
if(session == null && remoting) {
- log.info("--> readElementExistence, of " + getRole() + " with key " + getKey());
+ LOG.info("--> readElementExistence, of " + getRole() + " with key " + getKey());
read();
} else {
// In remoting we are sure that session is null
// both when using property paths and switching off conversations
if(session == null && remoting) {
- log.info("--> readElementByIndex, of " + getRole() + " with key " + getKey());
+ LOG.info("--> readElementByIndex, of " + getRole() + " with key " + getKey());
read();
} else {
try {
String role = getRole();
String fieldName = role.substring(role.lastIndexOf(".") + 1);
- log.info("--> Remote Lazy Initializing Collection " + getRole() + " , owner : " + getOwner().getClass() + "/" + getKey() + " , field : " + fieldName);
+ LOG.info("--> Remote Lazy Initializing Collection " + getRole() + " , owner : " + getOwner().getClass() + "/" + getKey() + " , field : " + fieldName);
Object owner = getOwner();
CdmBase cdmBase;
if(owner instanceof CdmBase) {