@@ -54,10 +54,10 @@ public SessionOpenEvent beginSessionOpenEvent() {
54
54
55
55
@ Override
56
56
public void completeSessionOpenEvent (
57
- HibernateMonitoringEvent event ,
57
+ HibernateMonitoringEvent monitoringEvent ,
58
58
SharedSessionContractImplementor session ) {
59
- if ( event != null ) {
60
- final SessionOpenEvent sessionOpenEvent = (SessionOpenEvent ) event ;
59
+ if ( monitoringEvent != null ) {
60
+ final SessionOpenEvent sessionOpenEvent = (SessionOpenEvent ) monitoringEvent ;
61
61
sessionOpenEvent .end ();
62
62
if ( sessionOpenEvent .shouldCommit () ) {
63
63
sessionOpenEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -80,10 +80,10 @@ public SessionClosedEvent beginSessionClosedEvent() {
80
80
81
81
@ Override
82
82
public void completeSessionClosedEvent (
83
- HibernateMonitoringEvent event ,
83
+ HibernateMonitoringEvent monitoringEvent ,
84
84
SharedSessionContractImplementor session ) {
85
- if ( event != null ) {
86
- final SessionClosedEvent sessionClosedEvent = (SessionClosedEvent ) event ;
85
+ if ( monitoringEvent != null ) {
86
+ final SessionClosedEvent sessionClosedEvent = (SessionClosedEvent ) monitoringEvent ;
87
87
sessionClosedEvent .end ();
88
88
if ( sessionClosedEvent .shouldCommit () ) {
89
89
sessionClosedEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -106,11 +106,11 @@ public JdbcConnectionAcquisitionEvent beginJdbcConnectionAcquisitionEvent() {
106
106
107
107
@ Override
108
108
public void completeJdbcConnectionAcquisitionEvent (
109
- HibernateMonitoringEvent event ,
109
+ HibernateMonitoringEvent monitoringEvent ,
110
110
SharedSessionContractImplementor session ,
111
111
Object tenantId ) {
112
- if ( event != null ) {
113
- final JdbcConnectionAcquisitionEvent jdbcConnectionAcquisitionEvent = (JdbcConnectionAcquisitionEvent ) event ;
112
+ if ( monitoringEvent != null ) {
113
+ final JdbcConnectionAcquisitionEvent jdbcConnectionAcquisitionEvent = (JdbcConnectionAcquisitionEvent ) monitoringEvent ;
114
114
jdbcConnectionAcquisitionEvent .end ();
115
115
if ( jdbcConnectionAcquisitionEvent .shouldCommit () ) {
116
116
jdbcConnectionAcquisitionEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -136,11 +136,11 @@ public JdbcConnectionReleaseEvent beginJdbcConnectionReleaseEvent() {
136
136
137
137
@ Override
138
138
public void completeJdbcConnectionReleaseEvent (
139
- HibernateMonitoringEvent event ,
139
+ HibernateMonitoringEvent monitoringEvent ,
140
140
SharedSessionContractImplementor session ,
141
141
Object tenantId ) {
142
- if ( event != null ) {
143
- final JdbcConnectionReleaseEvent jdbcConnectionReleaseEvent = (JdbcConnectionReleaseEvent ) event ;
142
+ if ( monitoringEvent != null ) {
143
+ final JdbcConnectionReleaseEvent jdbcConnectionReleaseEvent = (JdbcConnectionReleaseEvent ) monitoringEvent ;
144
144
jdbcConnectionReleaseEvent .end ();
145
145
if ( jdbcConnectionReleaseEvent .shouldCommit () ) {
146
146
jdbcConnectionReleaseEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -166,10 +166,10 @@ public JdbcPreparedStatementCreationEvent beginJdbcPreparedStatementCreationEven
166
166
167
167
@ Override
168
168
public void completeJdbcPreparedStatementCreationEvent (
169
- HibernateMonitoringEvent event ,
169
+ HibernateMonitoringEvent monitoringEvent ,
170
170
String preparedStatementSql ) {
171
- if ( event != null ) {
172
- final JdbcPreparedStatementCreationEvent jdbcPreparedStatementCreation = (JdbcPreparedStatementCreationEvent ) event ;
171
+ if ( monitoringEvent != null ) {
172
+ final JdbcPreparedStatementCreationEvent jdbcPreparedStatementCreation = (JdbcPreparedStatementCreationEvent ) monitoringEvent ;
173
173
jdbcPreparedStatementCreation .end ();
174
174
if ( jdbcPreparedStatementCreation .shouldCommit () ) {
175
175
jdbcPreparedStatementCreation .sql = preparedStatementSql ;
@@ -192,10 +192,10 @@ public JdbcPreparedStatementExecutionEvent beginJdbcPreparedStatementExecutionEv
192
192
193
193
@ Override
194
194
public void completeJdbcPreparedStatementExecutionEvent (
195
- HibernateMonitoringEvent event ,
195
+ HibernateMonitoringEvent monitoringEvent ,
196
196
String preparedStatementSql ) {
197
- if ( event != null ) {
198
- final JdbcPreparedStatementExecutionEvent jdbcPreparedStatementExecutionEvent = (JdbcPreparedStatementExecutionEvent ) event ;
197
+ if ( monitoringEvent != null ) {
198
+ final JdbcPreparedStatementExecutionEvent jdbcPreparedStatementExecutionEvent = (JdbcPreparedStatementExecutionEvent ) monitoringEvent ;
199
199
jdbcPreparedStatementExecutionEvent .end ();
200
200
if ( jdbcPreparedStatementExecutionEvent .shouldCommit () ) {
201
201
jdbcPreparedStatementExecutionEvent .sql = preparedStatementSql ;
@@ -218,10 +218,10 @@ public JdbcBatchExecutionEvent beginJdbcBatchExecutionEvent() {
218
218
219
219
@ Override
220
220
public void completeJdbcBatchExecutionEvent (
221
- HibernateMonitoringEvent event ,
221
+ HibernateMonitoringEvent monitoringEvent ,
222
222
String statementSql ) {
223
- if ( event != null ) {
224
- final JdbcBatchExecutionEvent jdbcBatchExecutionEvent = (JdbcBatchExecutionEvent ) event ;
223
+ if ( monitoringEvent != null ) {
224
+ final JdbcBatchExecutionEvent jdbcBatchExecutionEvent = (JdbcBatchExecutionEvent ) monitoringEvent ;
225
225
jdbcBatchExecutionEvent .end ();
226
226
if ( jdbcBatchExecutionEvent .shouldCommit () ) {
227
227
jdbcBatchExecutionEvent .sql = statementSql ;
@@ -244,13 +244,13 @@ public HibernateMonitoringEvent beginCachePutEvent() {
244
244
245
245
@ Override
246
246
public void completeCachePutEvent (
247
- HibernateMonitoringEvent event ,
247
+ HibernateMonitoringEvent monitoringEvent ,
248
248
SharedSessionContractImplementor session ,
249
249
Region region ,
250
250
boolean cacheContentChanged ,
251
251
CacheActionDescription description ) {
252
- if ( event != null ) {
253
- final CachePutEvent cachePutEvent = (CachePutEvent ) event ;
252
+ if ( monitoringEvent != null ) {
253
+ final CachePutEvent cachePutEvent = (CachePutEvent ) monitoringEvent ;
254
254
cachePutEvent .end ();
255
255
if ( cachePutEvent .shouldCommit () ) {
256
256
cachePutEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -264,14 +264,14 @@ public void completeCachePutEvent(
264
264
265
265
@ Override
266
266
public void completeCachePutEvent (
267
- HibernateMonitoringEvent event ,
267
+ HibernateMonitoringEvent monitoringEvent ,
268
268
SharedSessionContractImplementor session ,
269
269
CachedDomainDataAccess cachedDomainDataAccess ,
270
270
EntityPersister persister ,
271
271
boolean cacheContentChanged ,
272
272
CacheActionDescription description ) {
273
273
completeCachePutEvent (
274
- event ,
274
+ monitoringEvent ,
275
275
session ,
276
276
cachedDomainDataAccess ,
277
277
persister ,
@@ -283,15 +283,15 @@ public void completeCachePutEvent(
283
283
284
284
@ Override
285
285
public void completeCachePutEvent (
286
- HibernateMonitoringEvent event ,
286
+ HibernateMonitoringEvent monitoringEvent ,
287
287
SharedSessionContractImplementor session ,
288
288
CachedDomainDataAccess cachedDomainDataAccess ,
289
289
EntityPersister persister ,
290
290
boolean cacheContentChanged ,
291
291
boolean isNatualId ,
292
292
CacheActionDescription description ) {
293
- if ( event != null ) {
294
- final CachePutEvent cachePutEvent = (CachePutEvent ) event ;
293
+ if ( monitoringEvent != null ) {
294
+ final CachePutEvent cachePutEvent = (CachePutEvent ) monitoringEvent ;
295
295
cachePutEvent .end ();
296
296
if ( cachePutEvent .shouldCommit () ) {
297
297
cachePutEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -307,14 +307,14 @@ public void completeCachePutEvent(
307
307
308
308
@ Override
309
309
public void completeCachePutEvent (
310
- HibernateMonitoringEvent event ,
310
+ HibernateMonitoringEvent monitoringEvent ,
311
311
SharedSessionContractImplementor session ,
312
312
CachedDomainDataAccess cachedDomainDataAccess ,
313
313
CollectionPersister persister ,
314
314
boolean cacheContentChanged ,
315
315
CacheActionDescription description ) {
316
- if ( event != null ) {
317
- final CachePutEvent cachePutEvent = (CachePutEvent ) event ;
316
+ if ( monitoringEvent != null ) {
317
+ final CachePutEvent cachePutEvent = (CachePutEvent ) monitoringEvent ;
318
318
cachePutEvent .end ();
319
319
if ( cachePutEvent .shouldCommit () ) {
320
320
cachePutEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -341,12 +341,12 @@ public HibernateMonitoringEvent beginCacheGetEvent() {
341
341
342
342
@ Override
343
343
public void completeCacheGetEvent (
344
- HibernateMonitoringEvent event ,
344
+ HibernateMonitoringEvent monitoringEvent ,
345
345
SharedSessionContractImplementor session ,
346
346
Region region ,
347
347
boolean hit ) {
348
- if ( event != null ) {
349
- final CacheGetEvent cacheGetEvent = (CacheGetEvent ) event ;
348
+ if ( monitoringEvent != null ) {
349
+ final CacheGetEvent cacheGetEvent = (CacheGetEvent ) monitoringEvent ;
350
350
cacheGetEvent .end ();
351
351
if ( cacheGetEvent .shouldCommit () ) {
352
352
cacheGetEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -359,14 +359,14 @@ public void completeCacheGetEvent(
359
359
360
360
@ Override
361
361
public void completeCacheGetEvent (
362
- HibernateMonitoringEvent event ,
362
+ HibernateMonitoringEvent monitoringEvent ,
363
363
SharedSessionContractImplementor session ,
364
364
Region region ,
365
365
EntityPersister persister ,
366
366
boolean isNaturalKey ,
367
367
boolean hit ) {
368
- if ( event != null ) {
369
- final CacheGetEvent cacheGetEvent = (CacheGetEvent ) event ;
368
+ if ( monitoringEvent != null ) {
369
+ final CacheGetEvent cacheGetEvent = (CacheGetEvent ) monitoringEvent ;
370
370
cacheGetEvent .end ();
371
371
if ( cacheGetEvent .shouldCommit () ) {
372
372
cacheGetEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -381,13 +381,13 @@ public void completeCacheGetEvent(
381
381
382
382
@ Override
383
383
public void completeCacheGetEvent (
384
- HibernateMonitoringEvent event ,
384
+ HibernateMonitoringEvent monitoringEvent ,
385
385
SharedSessionContractImplementor session ,
386
386
Region region ,
387
387
CollectionPersister persister ,
388
388
boolean hit ) {
389
- if ( event != null ) {
390
- final CacheGetEvent cacheGetEvent = (CacheGetEvent ) event ;
389
+ if ( monitoringEvent != null ) {
390
+ final CacheGetEvent cacheGetEvent = (CacheGetEvent ) monitoringEvent ;
391
391
cacheGetEvent .end ();
392
392
if ( cacheGetEvent .shouldCommit () ) {
393
393
cacheGetEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -420,18 +420,18 @@ public void completeFlushEvent(
420
420
421
421
@ Override
422
422
public void completeFlushEvent (
423
- HibernateMonitoringEvent hibernateMonitoringEvent ,
424
- org .hibernate .event .spi .FlushEvent event ,
423
+ HibernateMonitoringEvent monitoringEvent ,
424
+ org .hibernate .event .spi .FlushEvent hibernateFlushEvent ,
425
425
boolean autoFlush ) {
426
- if ( hibernateMonitoringEvent != null ) {
427
- final FlushEvent flushEvent = (FlushEvent ) hibernateMonitoringEvent ;
428
- flushEvent .end ();
429
- if ( flushEvent .shouldCommit () ) {
430
- flushEvent .sessionIdentifier = getSessionIdentifier ( event .getSession () );
431
- flushEvent .numberOfEntitiesProcessed = event .getNumberOfEntitiesProcessed ();
432
- flushEvent .numberOfCollectionsProcessed = event .getNumberOfCollectionsProcessed ();
433
- flushEvent .isAutoFlush = autoFlush ;
434
- flushEvent .commit ();
426
+ if ( monitoringEvent != null ) {
427
+ final FlushEvent jfrFlushEvent = (FlushEvent ) monitoringEvent ;
428
+ jfrFlushEvent .end ();
429
+ if ( jfrFlushEvent .shouldCommit () ) {
430
+ jfrFlushEvent .sessionIdentifier = getSessionIdentifier ( hibernateFlushEvent .getSession () );
431
+ jfrFlushEvent .numberOfEntitiesProcessed = hibernateFlushEvent .getNumberOfEntitiesProcessed ();
432
+ jfrFlushEvent .numberOfCollectionsProcessed = hibernateFlushEvent .getNumberOfCollectionsProcessed ();
433
+ jfrFlushEvent .isAutoFlush = autoFlush ;
434
+ jfrFlushEvent .commit ();
435
435
}
436
436
}
437
437
}
@@ -450,17 +450,17 @@ public PartialFlushEvent beginPartialFlushEvent() {
450
450
451
451
@ Override
452
452
public void completePartialFlushEvent (
453
- HibernateMonitoringEvent hibernateMonitoringEvent ,
454
- AutoFlushEvent event ) {
455
- if ( event != null && hibernateMonitoringEvent != null ) {
456
- final PartialFlushEvent flushEvent = (PartialFlushEvent ) hibernateMonitoringEvent ;
457
- flushEvent .end ();
458
- if ( flushEvent .shouldCommit () ) {
459
- flushEvent .sessionIdentifier = getSessionIdentifier ( event .getSession () );
460
- flushEvent .numberOfEntitiesProcessed = event .getNumberOfEntitiesProcessed ();
461
- flushEvent .numberOfCollectionsProcessed = event .getNumberOfCollectionsProcessed ();
462
- flushEvent .isAutoFlush = true ;
463
- flushEvent .commit ();
453
+ HibernateMonitoringEvent monitoringEvent ,
454
+ AutoFlushEvent hibernateAutoFlushEvent ) {
455
+ if ( monitoringEvent != null ) {
456
+ final PartialFlushEvent jfrPartialFlushEvent = (PartialFlushEvent ) monitoringEvent ;
457
+ jfrPartialFlushEvent .end ();
458
+ if ( jfrPartialFlushEvent .shouldCommit () ) {
459
+ jfrPartialFlushEvent .sessionIdentifier = getSessionIdentifier ( hibernateAutoFlushEvent .getSession () );
460
+ jfrPartialFlushEvent .numberOfEntitiesProcessed = hibernateAutoFlushEvent .getNumberOfEntitiesProcessed ();
461
+ jfrPartialFlushEvent .numberOfCollectionsProcessed = hibernateAutoFlushEvent .getNumberOfCollectionsProcessed ();
462
+ jfrPartialFlushEvent .isAutoFlush = true ;
463
+ jfrPartialFlushEvent .commit ();
464
464
}
465
465
}
466
466
}
@@ -479,13 +479,13 @@ public DirtyCalculationEvent beginDirtyCalculationEvent() {
479
479
480
480
@ Override
481
481
public void completeDirtyCalculationEvent (
482
- HibernateMonitoringEvent event ,
482
+ HibernateMonitoringEvent monitoringEvent ,
483
483
SharedSessionContractImplementor session ,
484
484
EntityPersister persister ,
485
485
EntityEntry entry ,
486
486
int [] dirtyProperties ) {
487
- if ( event != null ) {
488
- final DirtyCalculationEvent dirtyCalculationEvent = (DirtyCalculationEvent ) event ;
487
+ if ( monitoringEvent != null ) {
488
+ final DirtyCalculationEvent dirtyCalculationEvent = (DirtyCalculationEvent ) monitoringEvent ;
489
489
dirtyCalculationEvent .end ();
490
490
if ( dirtyCalculationEvent .shouldCommit () ) {
491
491
dirtyCalculationEvent .sessionIdentifier = getSessionIdentifier ( session );
@@ -511,10 +511,10 @@ public PrePartialFlushEvent beginPrePartialFlush() {
511
511
512
512
@ Override
513
513
public void completePrePartialFlush (
514
- HibernateMonitoringEvent event ,
514
+ HibernateMonitoringEvent monitoringEvent ,
515
515
SharedSessionContractImplementor session ) {
516
- if ( event != null ) {
517
- final PrePartialFlushEvent prePartialFlushEvent = (PrePartialFlushEvent ) event ;
516
+ if ( monitoringEvent != null ) {
517
+ final PrePartialFlushEvent prePartialFlushEvent = (PrePartialFlushEvent ) monitoringEvent ;
518
518
prePartialFlushEvent .end ();
519
519
if ( prePartialFlushEvent .shouldCommit () ) {
520
520
prePartialFlushEvent .sessionIdentifier = getSessionIdentifier ( session );
0 commit comments