}
public void publish(Event event) {
checkInit();
if (event instanceof SessionBound) {
SessionEvent sessionEvent = ((SessionBound) event);
// update context
eventContext.setIdentifier(sessionEvent.getSessionTypeIdentifier(), sessionEvent.getId());
} else if (event instanceof RequestEnd) {
// be very careful with pooled threads, ensuring threadlocals are cleaned up
eventContext.clearIdentifiers();
}
super.publish(event);