use of org.restcomm.protocols.ss7.map.api.MAPProvider in project smscgateway by RestComm.
the class RsdsSbb method setSbbContext.
@Override
public void setSbbContext(SbbContext sbbContext) {
this.sbbContext = (SbbContextExt) sbbContext;
try {
Context ctx = (Context) new InitialContext().lookup("java:comp/env");
this.mapAcif = (MAPContextInterfaceFactory) ctx.lookup("slee/resources/map/2.0/acifactory");
this.mapProvider = (MAPProvider) ctx.lookup("slee/resources/map/2.0/provider");
this.mapParameterFactory = this.mapProvider.getMAPParameterFactory();
this.mapSmsTpduParameterFactory = this.mapProvider.getMAPSmsTpduParameterFactory();
this.logger = this.sbbContext.getTracer(this.className);
this.persistence = (PersistenceRAInterface) this.sbbContext.getResourceAdaptorInterface(PERSISTENCE_ID, PERSISTENCE_LINK);
this.sccpParameterFact = new ParameterFactoryImpl();
} catch (Exception ne) {
logger.severe("Could not set SBB context:", ne);
}
// TODO : Handle proper error
}
use of org.restcomm.protocols.ss7.map.api.MAPProvider in project smscgateway by RestComm.
the class RxSmppServerSbb method setSbbContext.
// *********
// SBB staff
@Override
public void setSbbContext(SbbContext sbbContext) {
super.setSbbContext(sbbContext);
try {
Context ctx = (Context) new InitialContext().lookup("java:comp/env");
maxMessagesPerStep = ((Integer) ctx.lookup("maxMessagesPerStep"));
this.smppServerTransactionACIFactory = (SmppTransactionACIFactory) ctx.lookup("slee/resources/smppp/server/1.0/acifactory");
this.smppServerSessions = (SmppSessions) ctx.lookup("slee/resources/smpp/server/1.0/provider");
MAPProvider mapProvider = (MAPProvider) ctx.lookup("slee/resources/map/2.0/provider");
this.mapSmsTpduParameterFactory = mapProvider.getMAPSmsTpduParameterFactory();
} catch (Exception ne) {
logger.severe("Could not set SBB context:", ne);
}
}
use of org.restcomm.protocols.ss7.map.api.MAPProvider in project smscgateway by RestComm.
the class MtCommonSbb method setSbbContext.
// *********
// SBB staff
@Override
public void setSbbContext(SbbContext sbbContext) {
super.setSbbContext(sbbContext);
try {
Context ctx = (Context) new InitialContext().lookup("java:comp/env");
this.mapAcif = (MAPContextInterfaceFactory) ctx.lookup("slee/resources/map/2.0/acifactory");
this.mapProvider = (MAPProvider) ctx.lookup("slee/resources/map/2.0/provider");
this.mapParameterFactory = this.mapProvider.getMAPParameterFactory();
this.mapSmsTpduParameterFactory = this.mapProvider.getMAPSmsTpduParameterFactory();
this.sccpParameterFact = new ParameterFactoryImpl();
} catch (Exception ne) {
logger.severe("Could not set SBB context:", ne);
}
}
use of org.restcomm.protocols.ss7.map.api.MAPProvider in project smscgateway by RestComm.
the class HomeRoutingCommonSbb method setSbbContext.
@Override
public void setSbbContext(SbbContext sbbContext) {
this.sbbContext = (SbbContextExt) sbbContext;
try {
Context ctx = (Context) new InitialContext().lookup("java:comp/env");
this.mapAcif = (MAPContextInterfaceFactory) ctx.lookup("slee/resources/map/2.0/acifactory");
this.mapProvider = (MAPProvider) ctx.lookup("slee/resources/map/2.0/provider");
this.mapParameterFactory = this.mapProvider.getMAPParameterFactory();
this.mapErrorMessageFactory = this.mapProvider.getMAPErrorMessageFactory();
this.sccpParameterFact = new ParameterFactoryImpl();
// this.smppServerSessions = (SmppSessions) ctx
// .lookup("slee/resources/smpp/server/1.0/provider");
this.persistence = (PersistenceRAInterface) this.sbbContext.getResourceAdaptorInterface(PERSISTENCE_ID, PERSISTENCE_LINK);
this.logger = this.sbbContext.getTracer(this.className);
itsMProcRa = (MProcRuleRaProvider) this.sbbContext.getResourceAdaptorInterface(MPROC_RATYPE_ID, MPROC_RA_LINK);
} catch (Exception ne) {
logger.severe("Could not set SBB context:", ne);
}
// TODO : Handle proper error
}
use of org.restcomm.protocols.ss7.map.api.MAPProvider in project smscgateway by RestComm.
the class AlertSbb method setSbbContext.
@Override
public void setSbbContext(SbbContext sbbContext) {
this.sbbContext = (SbbContextExt) sbbContext;
try {
Context ctx = (Context) new InitialContext().lookup("java:comp/env");
this.mapAcif = (MAPContextInterfaceFactory) ctx.lookup("slee/resources/map/2.0/acifactory");
this.mapProvider = (MAPProvider) ctx.lookup("slee/resources/map/2.0/provider");
this.mapParameterFactory = this.mapProvider.getMAPParameterFactory();
this.logger = this.sbbContext.getTracer(AlertSbb.class.getSimpleName());
this.persistence = (PersistenceRAInterface) this.sbbContext.getResourceAdaptorInterface(PERSISTENCE_ID, PERSISTENCE_LINK);
this.scheduler = (SchedulerRaSbbInterface) this.sbbContext.getResourceAdaptorInterface(SCHEDULER_ID, SCHEDULER_LINK);
} catch (Exception ne) {
logger.severe("Could not set SBB context:", ne);
}
}
Aggregations