Class AbstractServiceDefinition
java.lang.Object
org.kuali.rice.ksb.api.bus.support.AbstractServiceDefinition
- All Implemented Interfaces:
ServiceDefinition
- Direct Known Subclasses:
JavaServiceDefinition,SoapServiceDefinition
The definition of a service on the service bus.
- Author:
- Kuali Rice Team (rice.collab@kuali.org)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract ServiceConfigurationbooleanEstablishes and returns anEndpointto this service which generates theServiceConfigurationfor this service definition as well as including the actual service implementation as provided byServiceDefinition.getService().Returns the id of the application which owns this service.Returns true if this service is secured by standard KSB security features.Returns the type of security credentials that should be used when attempting to authorize access to this service.Returns the URL of the endpoint which provides this service.Returns the id of the specific instance of the application which owns this serviceReturns the name of the exception handler to invoke whenever messages to this service fail to be sent.Returns the maximum amount of milliseconds a message to this service can live and attempt to be processed successfully by this service before it's forced into processing by it's exception handler.Returns the processing priority for messages that are sent to this service.Returns the retry attempts to use when processing messages sent to this service.Return the actual service implementation to publish and export to the service bus.Returns theClassLoaderthat should be set as the context classloader on the thread prior to any invocations on the serviceReturns the qualified name for this service.Returns the url path to export the service under.Returns the version of this service.inthashCode()booleanReturns whether the service is secured with basic authenticationbooleanisQueue()Return true if this service uses queue-style messaging, false if it uses topic-style messaging.voidsetApplicationId(String applicationId) voidsetBasicAuthentication(boolean basicAuthentication) voidsetBusSecurity(Boolean busSecurity) voidsetCredentialsType(CredentialsType credentialsType) voidsetEndpointUrl(URL endpointUrl) voidsetInstanceId(String instanceId) voidsetLocalServiceName(String serviceName) voidsetMessageExceptionHandler(String messageExceptionHandler) voidsetMillisToLive(Long millisToLive) voidsetPriority(Integer priority) voidsetQueue(boolean queue) voidsetRetryAttempts(Integer retryAttempts) voidsetService(Object service) voidsetServiceClassLoader(ClassLoader serviceClassLoader) voidsetServiceName(QName serviceName) voidsetServiceNameSpaceURI(String serviceNameSpaceURI) voidsetServicePath(String servicePath) voidsetServiceVersion(String serviceVersion) toString()voidvalidate()Validates the service definition after creation of the service definition.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.kuali.rice.ksb.api.bus.ServiceDefinition
getType
-
Constructor Details
-
AbstractServiceDefinition
protected AbstractServiceDefinition()
-
-
Method Details
-
isBasicAuthentication
public boolean isBasicAuthentication()Description copied from interface:ServiceDefinitionReturns whether the service is secured with basic authentication- Specified by:
isBasicAuthenticationin interfaceServiceDefinition- Returns:
- the basicAuthentication
-
setBasicAuthentication
public void setBasicAuthentication(boolean basicAuthentication) - Parameters:
basicAuthentication- the basicAuthentication to set
-
getService
Description copied from interface:ServiceDefinitionReturn the actual service implementation to publish and export to the service bus.- Specified by:
getServicein interfaceServiceDefinition- Returns:
- the service to publish
-
setService
-
getLocalServiceName
-
setLocalServiceName
-
getMessageExceptionHandler
Description copied from interface:ServiceDefinitionReturns the name of the exception handler to invoke whenever messages to this service fail to be sent. If null, the default message exception handler will be used.- Specified by:
getMessageExceptionHandlerin interfaceServiceDefinition- Returns:
- the name of the message exception handler for this service, or null if the default handler should be used
-
setMessageExceptionHandler
-
getPriority
Description copied from interface:ServiceDefinitionReturns the processing priority for messages that are sent to this service.- Specified by:
getPriorityin interfaceServiceDefinition- Returns:
- the message processing priority for this service
-
setPriority
-
isQueue
public boolean isQueue()Description copied from interface:ServiceDefinitionReturn true if this service uses queue-style messaging, false if it uses topic-style messaging.- Specified by:
isQueuein interfaceServiceDefinition- Returns:
- true if this service uses queue-style messaging, false if it uses topic-style messaging
-
setQueue
public void setQueue(boolean queue) -
getRetryAttempts
Description copied from interface:ServiceDefinitionReturns the retry attempts to use when processing messages sent to this service.- Specified by:
getRetryAttemptsin interfaceServiceDefinition- Returns:
- the retry attempts for this service
-
setRetryAttempts
-
getServiceName
Description copied from interface:ServiceDefinitionReturns the qualified name for this service.- Specified by:
getServiceNamein interfaceServiceDefinition- Returns:
- the qualified name for this service
-
setServiceName
-
getEndpointUrl
Description copied from interface:ServiceDefinitionReturns the URL of the endpoint which provides this service.- Specified by:
getEndpointUrlin interfaceServiceDefinition- Returns:
- the endpoint URL of the service
-
setEndpointUrl
-
setCredentialsType
-
getCredentialsType
Description copied from interface:ServiceDefinitionReturns the type of security credentials that should be used when attempting to authorize access to this service.- Specified by:
getCredentialsTypein interfaceServiceDefinition- Returns:
- the type of security credentials to use when access this service
-
getServiceVersion
Description copied from interface:ServiceDefinitionReturns the version of this service.- Specified by:
getServiceVersionin interfaceServiceDefinition- Returns:
- the version of this service
-
setServiceVersion
-
getApplicationId
Description copied from interface:ServiceDefinitionReturns the id of the application which owns this service.- Specified by:
getApplicationIdin interfaceServiceDefinition- Returns:
- the id of the application which owns this service
-
setApplicationId
-
getInstanceId
Description copied from interface:ServiceDefinitionReturns the id of the specific instance of the application which owns this service- Specified by:
getInstanceIdin interfaceServiceDefinition- Returns:
- the id of the specific instance of the application which owns this service
-
setInstanceId
-
getServiceClassLoader
Description copied from interface:ServiceDefinitionReturns theClassLoaderthat should be set as the context classloader on the thread prior to any invocations on the service- Specified by:
getServiceClassLoaderin interfaceServiceDefinition- Returns:
- the classloader for this service
-
setServiceClassLoader
-
validate
public void validate()Description copied from interface:ServiceDefinitionValidates the service definition after creation of the service definition. It's intended that portions of the KSB that handle publication and export of services to the bus will execute this prior to successful export of the service.- Specified by:
validatein interfaceServiceDefinition
-
establishEndpoint
Description copied from interface:ServiceDefinitionEstablishes and returns anEndpointto this service which generates theServiceConfigurationfor this service definition as well as including the actual service implementation as provided byServiceDefinition.getService().The
ServiceDefinition.validate()method should be invoked prior to executing this method in order to ensure that the appropriate internal state for theServiceDefinitionhas been established.- Specified by:
establishEndpointin interfaceServiceDefinition- Returns:
- the established endpoint, should never return null
-
configure
-
getServiceNameSpaceURI
-
setServiceNameSpaceURI
-
getMillisToLive
Description copied from interface:ServiceDefinitionReturns the maximum amount of milliseconds a message to this service can live and attempt to be processed successfully by this service before it's forced into processing by it's exception handler.- Specified by:
getMillisToLivein interfaceServiceDefinition- Returns:
- the maximum lifetime for this message, if null then this message has an infinite lifetime
-
setMillisToLive
-
getBusSecurity
Description copied from interface:ServiceDefinitionReturns true if this service is secured by standard KSB security features.- Specified by:
getBusSecurityin interfaceServiceDefinition- Returns:
- true if this service is secured, false otherwise
-
setBusSecurity
-
getServicePath
Description copied from interface:ServiceDefinitionReturns the url path to export the service under.- Specified by:
getServicePathin interfaceServiceDefinition- Returns:
- the servicePath
-
setServicePath
- Parameters:
servicePath- the servicePath to set
-
toString
-
equals
-
hashCode
public int hashCode()
-