HHH-13197 Reduce bootstrap log verbosity

This commit is contained in:
Guillaume Smet 2019-01-11 10:21:32 +01:00
parent 070c14e149
commit 3317ca5105
3 changed files with 15 additions and 15 deletions

View File

@ -162,7 +162,7 @@ public class EnhancerImpl implements Enhancer {
PersistentAttributeTransformer transformer = PersistentAttributeTransformer.collectPersistentFields( managedCtClass, enhancementContext, typePool );
if ( enhancementContext.isEntityClass( managedCtClass ) ) {
log.infof( "Enhancing [%s] as Entity", managedCtClass.getName() );
log.debugf( "Enhancing [%s] as Entity", managedCtClass.getName() );
builder = builder.implement( ManagedEntity.class )
.defineMethod( EnhancerConstants.ENTITY_INSTANCE_GETTER_NAME, Object.class, Visibility.PUBLIC )
.intercept( FixedValue.self() );
@ -294,7 +294,7 @@ public class EnhancerImpl implements Enhancer {
return transformer.applyTo( builder, false );
}
else if ( enhancementContext.isCompositeClass( managedCtClass ) ) {
log.infof( "Enhancing [%s] as Composite", managedCtClass.getName() );
log.debugf( "Enhancing [%s] as Composite", managedCtClass.getName() );
builder = builder.implement( ManagedComposite.class );
builder = addInterceptorHandling( builder, managedCtClass );
@ -327,13 +327,13 @@ public class EnhancerImpl implements Enhancer {
return transformer.applyTo( builder, false );
}
else if ( enhancementContext.isMappedSuperclassClass( managedCtClass ) ) {
log.infof( "Enhancing [%s] as MappedSuperclass", managedCtClass.getName() );
log.debugf( "Enhancing [%s] as MappedSuperclass", managedCtClass.getName() );
builder = builder.implement( ManagedMappedSuperclass.class );
return transformer.applyTo( builder, true );
}
else if ( enhancementContext.doExtendedEnhancement( managedCtClass ) ) {
log.infof( "Extended enhancement of [%s]", managedCtClass.getName() );
log.debugf( "Extended enhancement of [%s]", managedCtClass.getName() );
return transformer.applyExtended( builder );
}
else {

View File

@ -132,22 +132,22 @@ public class EnhancerImpl implements Enhancer {
}
if ( enhancementContext.isEntityClass( managedCtClass ) ) {
log.infof( "Enhancing [%s] as Entity", managedCtClass.getName() );
log.debugf( "Enhancing [%s] as Entity", managedCtClass.getName() );
new EntityEnhancer( enhancementContext ).enhance( managedCtClass );
return true;
}
else if ( enhancementContext.isCompositeClass( managedCtClass ) ) {
log.infof( "Enhancing [%s] as Composite", managedCtClass.getName() );
log.debugf( "Enhancing [%s] as Composite", managedCtClass.getName() );
new CompositeEnhancer( enhancementContext ).enhance( managedCtClass );
return true;
}
else if ( enhancementContext.isMappedSuperclassClass( managedCtClass ) ) {
log.infof( "Enhancing [%s] as MappedSuperclass", managedCtClass.getName() );
log.debugf( "Enhancing [%s] as MappedSuperclass", managedCtClass.getName() );
new MappedSuperclassEnhancer( enhancementContext ).enhance( managedCtClass );
return true;
}
else if ( enhancementContext.doExtendedEnhancement( managedCtClass ) ) {
log.infof( "Extended enhancement of [%s]", managedCtClass.getName() );
log.debugf( "Extended enhancement of [%s]", managedCtClass.getName() );
new PersistentAttributesEnhancer( enhancementContext ).extendedEnhancement( managedCtClass );
return true;
}

View File

@ -640,14 +640,14 @@ public interface CoreMessageLogger extends BasicLogger {
void processEqualityExpression();
@LogMessage(level = INFO)
@Message(value = "Processing PersistenceUnitInfo [\n\tname: %s\n\t...]", id = 204)
@Message(value = "Processing PersistenceUnitInfo [name: %s]", id = 204)
void processingPersistenceUnitInfoName(String persistenceUnitName);
@LogMessage(level = INFO)
@Message(value = "Loaded properties from resource hibernate.properties: %s", id = 205)
void propertiesLoaded(Properties maskOut);
@LogMessage(level = INFO)
@LogMessage(level = DEBUG)
@Message(value = "hibernate.properties not found", id = 206)
void propertiesNotFound();
@ -877,7 +877,7 @@ public interface CoreMessageLogger extends BasicLogger {
@Message(value = "Type [%s] defined no registration keys; ignoring", id = 269)
void typeDefinedNoRegistrationKeys(BasicType type);
@LogMessage(level = INFO)
@LogMessage(level = DEBUG)
@Message(value = "Type registration [%s] overrides previous : %s", id = 270)
void typeRegistrationOverridesPrevious(
String key,
@ -1483,20 +1483,20 @@ public interface CoreMessageLogger extends BasicLogger {
@Message(value = "Closing un-released batch", id = 420)
void closingUnreleasedBatch();
@LogMessage(level = INFO)
@LogMessage(level = DEBUG)
@Message(value = "Disabling contextual LOB creation as %s is true", id = 421)
void disablingContextualLOBCreation(String nonContextualLobCreation);
@LogMessage(level = INFO)
@LogMessage(level = DEBUG)
@Message(value = "Disabling contextual LOB creation as connection was null", id = 422)
void disablingContextualLOBCreationSinceConnectionNull();
@LogMessage(level = INFO)
@LogMessage(level = DEBUG)
@Message(value = "Disabling contextual LOB creation as JDBC driver reported JDBC version [%s] less than 4",
id = 423)
void disablingContextualLOBCreationSinceOldJdbcVersion(int jdbcMajorVersion);
@LogMessage(level = INFO)
@LogMessage(level = DEBUG)
@Message(value = "Disabling contextual LOB creation as createClob() method threw error : %s", id = 424)
void disablingContextualLOBCreationSinceCreateClobFailed(Throwable t);