public class LastExecutionAwareListener extends Object implements ProxyExecutionListener
| Constructor and Description |
|---|
LastExecutionAwareListener() |
public void beforeQuery(QueryExecutionInfo execInfo)
ProxyExecutionListenerBatch.execute() or Statement.execute()).
Note: this callback is called when the publisher, result of the execute(), is being
subscribed. Not at the time of execute() is called,
beforeQuery in interface ProxyExecutionListenerexecInfo - query execution contextpublic void afterQuery(QueryExecutionInfo execInfo)
ProxyExecutionListenerBatch.execute() or Statement.execute()).
The callback order is:
ProxyExecutionListener.beforeQuery(QueryExecutionInfo)
ProxyExecutionListener.eachQueryResult(QueryExecutionInfo) for 1st result
ProxyExecutionListener.eachQueryResult(QueryExecutionInfo) for 2nd result
ProxyExecutionListener.eachQueryResult(QueryExecutionInfo) for Nth result
ProxyExecutionListener.afterQuery(QueryExecutionInfo)
QueryExecutionInfo.getExecuteDuration() is available in this callback and it holds
the duration since ProxyExecutionListener.beforeQuery(QueryExecutionInfo).
Note: this callback is called when the publisher, result of the execute(), is being
subscribed. Not at the time of execute() is called,
afterQuery in interface ProxyExecutionListenerexecInfo - query execution contextpublic void eachQueryResult(QueryExecutionInfo execInfo)
ProxyExecutionListenerResult.
While processing query results Result, this callback
is called per result.
QueryExecutionInfo.getCurrentMappedResult() contains the mapped result.
eachQueryResult in interface ProxyExecutionListenerexecInfo - query execution contextpublic void beforeMethod(MethodExecutionInfo executionInfo)
ProxyExecutionListenerbeforeMethod in interface ProxyExecutionListenerexecutionInfo - method execution contextpublic void afterMethod(MethodExecutionInfo executionInfo)
ProxyExecutionListenerafterMethod in interface ProxyExecutionListenerexecutionInfo - method execution contextpublic QueryExecutionInfo getBeforeQueryExecutionInfo()
QueryExecutionInfo in ProxyExecutionListener.beforeQuery(QueryExecutionInfo).QueryExecutionInfo. Can be null if not invoked yet.public QueryExecutionInfo getAfterQueryExecutionInfo()
QueryExecutionInfo in ProxyExecutionListener.afterQuery(QueryExecutionInfo).QueryExecutionInfo. Can be null if not invoked yet.public QueryExecutionInfo getEachQueryResultExecutionInfo()
QueryExecutionInfo in ProxyExecutionListener.eachQueryResult(QueryExecutionInfo).QueryExecutionInfo. Can be null if not invoked yet.public MethodExecutionInfo getBeforeMethodExecutionInfo()
MethodExecutionInfo in ProxyExecutionListener.beforeMethod(MethodExecutionInfo).MethodExecutionInfo. Can be null if not invoked yet.public MethodExecutionInfo getAfterMethodExecutionInfo()
MethodExecutionInfo in ProxyExecutionListener.afterMethod(MethodExecutionInfo).MethodExecutionInfo. Can be null if not invoked yet.Copyright © 2024. All rights reserved.