Package org.apache.ofbiz.service.jms
Class JmsServiceEngine
java.lang.Object
org.apache.ofbiz.service.engine.AbstractEngine
org.apache.ofbiz.service.jms.JmsServiceEngine
- All Implemented Interfaces:
GenericEngine
AbstractJMSEngine
-
Field Summary
Fields inherited from interface org.apache.ofbiz.service.engine.GenericEngine
ASYNC_MODE, SYNC_MODE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected JmsService
getServiceElement
(ModelService modelService) Gets service element.protected javax.jms.Message
makeMessage
(javax.jms.Session session, ModelService modelService, Map<String, Object> context) Make message message.run
(ModelService modelService, Map<String, Object> context) Run map.void
Run the service asynchronously and IGNORE the result.void
runAsync
(String localName, ModelService modelService, Map<String, Object> context, GenericRequester requester, boolean persist) Run the service asynchronously, passing an instance of GenericRequester that will receive the result.Run queue map.Run the service synchronously and return the result.void
runSyncIgnore
(String localName, ModelService modelService, Map<String, Object> context) Run the service synchronously and IGNORE the result.Run topic map.runXaQueue
(ModelService modelService, Map<String, Object> context, Element server) Run xa queue map.serverList
(Element serviceElement) Server list list.Methods inherited from class org.apache.ofbiz.service.engine.AbstractEngine
allowCallbacks, createLocationMap, getDispatcher, getLocation, sendCallbacks, sendCallbacks, sendCallbacks
-
Constructor Details
-
JmsServiceEngine
-
-
Method Details
-
getServiceElement
Gets service element.- Parameters:
modelService
- the model service- Returns:
- the service element
- Throws:
GenericServiceException
- the generic service exception
-
makeMessage
protected javax.jms.Message makeMessage(javax.jms.Session session, ModelService modelService, Map<String, Object> context) throws GenericServiceException, javax.jms.JMSExceptionMake message message.- Parameters:
session
- the sessionmodelService
- the model servicecontext
- the context- Returns:
- the message
- Throws:
GenericServiceException
- the generic service exceptionjavax.jms.JMSException
- the jms exception
-
serverList
Server list list.- Parameters:
serviceElement
- the service element- Returns:
- the list
- Throws:
GenericServiceException
- the generic service exception
-
runTopic
protected Map<String,Object> runTopic(ModelService modelService, Map<String, Object> context, Server server) throws GenericServiceExceptionRun topic map.- Parameters:
modelService
- the model servicecontext
- the contextserver
- the server- Returns:
- the map
- Throws:
GenericServiceException
- the generic service exception
-
runQueue
protected Map<String,Object> runQueue(ModelService modelService, Map<String, Object> context, Server server) throws GenericServiceExceptionRun queue map.- Parameters:
modelService
- the model servicecontext
- the contextserver
- the server- Returns:
- the map
- Throws:
GenericServiceException
- the generic service exception
-
runXaQueue
protected Map<String,Object> runXaQueue(ModelService modelService, Map<String, Object> context, Element server) throws GenericServiceExceptionRun xa queue map.- Parameters:
modelService
- the model servicecontext
- the contextserver
- the server- Returns:
- the map
- Throws:
GenericServiceException
- the generic service exception
-
run
protected Map<String,Object> run(ModelService modelService, Map<String, Object> context) throws GenericServiceExceptionRun map.- Parameters:
modelService
- the model servicecontext
- the context- Returns:
- the map
- Throws:
GenericServiceException
- the generic service exception
-
runSync
public Map<String,Object> runSync(String localName, ModelService modelService, Map<String, Object> context) throws GenericServiceExceptionDescription copied from interface:GenericEngine
Run the service synchronously and return the result.- Parameters:
localName
- Name of the LocalDispatcher.modelService
- Service model object.context
- Map of name, value pairs composing the context.- Returns:
- Map of name, value pairs composing the result.
- Throws:
GenericServiceException
-
runSyncIgnore
public void runSyncIgnore(String localName, ModelService modelService, Map<String, Object> context) throws GenericServiceExceptionDescription copied from interface:GenericEngine
Run the service synchronously and IGNORE the result.- Parameters:
localName
- Name of the LocalDispatcher.modelService
- Service model object.context
- Map of name, value pairs composing the context.- Throws:
GenericServiceException
-
runAsync
public void runAsync(String localName, ModelService modelService, Map<String, Object> context, GenericRequester requester, boolean persist) throws GenericServiceExceptionDescription copied from interface:GenericEngine
Run the service asynchronously, passing an instance of GenericRequester that will receive the result.- Parameters:
localName
- Name of the LocalDispatcher.modelService
- Service model object.context
- Map of name, value pairs composing the context.requester
- Object implementing GenericRequester interface which will receive the result.persist
- True for store/run; False for run.- Throws:
GenericServiceException
-
runAsync
public void runAsync(String localName, ModelService modelService, Map<String, Object> context, boolean persist) throws GenericServiceExceptionDescription copied from interface:GenericEngine
Run the service asynchronously and IGNORE the result.- Parameters:
localName
- Name of the LocalDispatcher.modelService
- Service model object.context
- Map of name, value pairs composing the context.persist
- True for store/run; False for run.- Throws:
GenericServiceException
-