try {
// set message in history size
ConfigBean bean = getWSEPBean(event, false);
if (bean instanceof WebServiceEndpoint) {
WebServiceEndpoint wsep = (WebServiceEndpoint) bean;
WebServiceEndpoint oWsep =
(WebServiceEndpoint) getWSEPBean(event, true);
// monitoring level
String newMonitoring = wsep.getMonitoring();
String oldMonitoring = oWsep.getMonitoring();
// history size
int historySize = 25;
// end point name
String epName = wsep.getName();
String hs = wsep.getMaxHistorySize();
if (hs != null) {
historySize = Integer.parseInt(hs);
}
// application id
String appId = getApplicationId(wsep);
// message trace manager
MessageTraceMgr traceMgr = MessageTraceMgr.getInstance();
// monitoring level changed
if ( (newMonitoring != null) && (oldMonitoring != null)
&& (!newMonitoring.equals(oldMonitoring)) ) {
// monitoring level is changed to HIGH
if ("HIGH".equalsIgnoreCase(newMonitoring)) {
traceMgr.enable(appId, epName, historySize);
// monitoirng level is changed from HIGH to LOW or OFF
} else if ("HIGH".equalsIgnoreCase(oldMonitoring)) {
traceMgr.disable(appId, epName);
}
} else {
// old history size
String oldHs = oWsep.getMaxHistorySize();
int oldHistorySize = 0;
if (oldHs != null) {
oldHistorySize = Integer.parseInt(oldHs);
}
// history size has changed and monitoring level is HIGH
if ((historySize != oldHistorySize)
&& ("HIGH".equalsIgnoreCase(newMonitoring))) {
traceMgr.setMessageHistorySize(appId, epName,
historySize);
}
}
AppServWSMonitorLifeCycleProvider aplifeProv =
new AppServWSMonitorLifeCycleProvider();
aplifeProv.reconfigureMonitoring(wsep, appId,
MonitoringLevel.instance(oldMonitoring),
MonitoringLevel.instance(newMonitoring));
// Check for jbiEnabled Flag
boolean jbiEnabledFlag = wsep.isJbiEnabled();
boolean oldJbiEnabledSetting =oWsep.isJbiEnabled();
if(jbiEnabledFlag != oldJbiEnabledSetting) {
String endpointURI = WebServiceMgrBackEnd.getManager().
getEndpointURI(getApplicationId(wsep) + "#" + epName);
if(endpointURI != null && (ServiceEngineRtObjectFactory.getInstance().getFacade() != null)) {
ServiceEngineRtObjectFactory.getInstance().