An interface for ad-hoc (explicit) run of configured service jobs (in the moqui.service.job.ServiceJob entity). This interface has minimal options as most should be configured using ServiceJob entity fields.
| Type | Name and description |
|---|---|
ServiceCallJob |
parameter(java.lang.String name, java.lang.Object value)Single name, value pairs to put in the context (in parameters) passed to the service. |
ServiceCallJob |
parameters(java.util.Map<java.lang.String, ?> context)Map of name, value pairs that make up the context (in parameters) passed to the service. |
java.lang.String |
run()Run a service job. |
| Methods inherited from class | Name |
|---|---|
interface ServiceCall |
getCurrentParameters, getServiceName |
interface java.util.concurrent.Future |
java.util.concurrent.Future#cancel(boolean), java.util.concurrent.Future#isCancelled(), java.util.concurrent.Future#isDone(), java.util.concurrent.Future#get(), java.util.concurrent.Future#get(long, java.util.concurrent.TimeUnit) |
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Single name, value pairs to put in the context (in parameters) passed to the service.
Map of name, value pairs that make up the context (in parameters) passed to the service.
Run a service job. The job will always run asynchronously. To get the results of the service call without looking at the ServiceJobRun.results field keep a reference to this object and use the methods on the java.util.concurrent.Future interface. If the ServiceJob.topic field has a value a notification will be sent to the current user and all users configured using ServiceJobUser records. The NotificationMessage.message field will be the results of this service call.