org.mule.module.jca
Class MuleResourceAdapter

java.lang.Object
  extended by org.mule.module.jca.MuleResourceAdapter
All Implemented Interfaces:
java.io.Serializable, javax.resource.spi.ResourceAdapter

public class MuleResourceAdapter
extends java.lang.Object
implements javax.resource.spi.ResourceAdapter, java.io.Serializable

MuleResourceAdapter TODO

See Also:
Serialized Form

Field Summary
protected  javax.resource.spi.BootstrapContext bootstrapContext
           
protected  java.lang.String defaultJcaModelName
           
protected  java.util.Map<MuleEndpointKey,Service> endpoints
           
protected  Log logger
          logger used by this class
protected  MuleContext muleContext
           
 
Constructor Summary
MuleResourceAdapter()
           
 
Method Summary
protected  Service createJcaService(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory, JcaModel model, InboundEndpoint endpoint)
           
protected  InboundEndpoint createMessageInflowEndpoint(MuleActivationSpec muleActivationSpec)
           
 void endpointActivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory, javax.resource.spi.ActivationSpec activationSpec)
           
 void endpointDeactivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory, javax.resource.spi.ActivationSpec activationSpec)
           
 boolean equals(java.lang.Object obj)
           
 javax.resource.spi.BootstrapContext getBootstrapContext()
           
 java.lang.String getClusterId()
           
 java.lang.String getConfigurationBuilder()
           
 java.lang.String getConfigurations()
           
 java.lang.String getDefaultEncoding()
           
 int getDefaultQueueTimeout()
           
 int getDefaultResponseTimeout()
           
 int getDefaultTransactionTimeout()
           
 java.lang.String getDomainId()
           
 java.lang.String getId()
           
protected  JcaModel getJcaModel(java.lang.String modelName)
           
 java.lang.String getModelName()
           
 java.lang.String getMuleHomeDirectory()
           
 java.lang.String getPassword()
           
 int getShutdownTimeout()
           
 java.lang.String getSystemModelType()
           
 java.lang.String getSystemName()
           
 java.lang.String getUserName()
           
 java.lang.String getWorkingDirectory()
           
 javax.transaction.xa.XAResource[] getXAResources(javax.resource.spi.ActivationSpec[] activationSpecs)
          We only connect to one resource manager per ResourceAdapter instance, so any ActivationSpec will return the same XAResource.
 int hashCode()
           
 boolean isAutoWrapMessageAwareTransform()
           
 boolean isCacheMessageAsBytes()
           
 boolean isCacheMessageOriginalPayload()
           
 boolean isClientMode()
           
 boolean isEnableStreaming()
           
protected  java.lang.String resolveModelName(MuleActivationSpec activationSpec)
           
 void setAutoWrapMessageAwareTransform(java.lang.Boolean autoWrapMessageAwareTransform)
           
 void setCacheMessageAsBytes(java.lang.Boolean cacheMessageAsBytes)
           
 void setCacheMessageOriginalPayload(java.lang.Boolean cacheMessageOriginalPayload)
           
 void setClusterId(java.lang.String clusterId)
           
 void setConfigurationBuilder(java.lang.String configbuilder)
           
 void setConfigurations(java.lang.String configurations)
           
 void setDefaultEncoding(java.lang.String encoding)
           
 void setDefaultQueueTimeout(java.lang.Integer defaultQueueTimeout)
           
 void setDefaultResponseTimeout(java.lang.Integer responseTimeout)
           
 void setDefaultSynchronousEndpoints(java.lang.Boolean synchronous)
           
 void setDefaultTransactionTimeout(java.lang.Integer defaultTransactionTimeout)
           
 void setDomainId(java.lang.String domainId)
           
 void setModelName(java.lang.String modelName)
           
 void setPassword(java.lang.String password)
           
 void setServerId(java.lang.String serverId)
           
 void setShutdownTimeout(java.lang.Integer shutdownTimeout)
           
 void setUserName(java.lang.String userid)
           
 void setWorkingDirectory(java.lang.String workingDirectory)
           
 void start(javax.resource.spi.BootstrapContext bootstrapContext)
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected transient Log logger
logger used by this class


muleContext

protected transient MuleContext muleContext

bootstrapContext

protected transient javax.resource.spi.BootstrapContext bootstrapContext

endpoints

protected final java.util.Map<MuleEndpointKey,Service> endpoints

defaultJcaModelName

protected java.lang.String defaultJcaModelName
Constructor Detail

MuleResourceAdapter

public MuleResourceAdapter()
Method Detail

start

public void start(javax.resource.spi.BootstrapContext bootstrapContext)
           throws javax.resource.spi.ResourceAdapterInternalException
Specified by:
start in interface javax.resource.spi.ResourceAdapter
Throws:
javax.resource.spi.ResourceAdapterInternalException
See Also:
ResourceAdapter.start(javax.resource.spi.BootstrapContext)

stop

public void stop()
Specified by:
stop in interface javax.resource.spi.ResourceAdapter
See Also:
ResourceAdapter.stop()

getBootstrapContext

public javax.resource.spi.BootstrapContext getBootstrapContext()
Returns:
the bootstrap context for this adapter

endpointActivation

public void endpointActivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory,
                               javax.resource.spi.ActivationSpec activationSpec)
                        throws javax.resource.ResourceException
Specified by:
endpointActivation in interface javax.resource.spi.ResourceAdapter
Throws:
javax.resource.ResourceException
See Also:
ResourceAdapter.endpointActivation(javax.resource.spi.endpoint.MessageEndpointFactory, javax.resource.spi.ActivationSpec)

endpointDeactivation

public void endpointDeactivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory,
                                 javax.resource.spi.ActivationSpec activationSpec)
Specified by:
endpointDeactivation in interface javax.resource.spi.ResourceAdapter
See Also:
ResourceAdapter.endpointDeactivation(javax.resource.spi.endpoint.MessageEndpointFactory, javax.resource.spi.ActivationSpec)

resolveModelName

protected java.lang.String resolveModelName(MuleActivationSpec activationSpec)
                                     throws javax.resource.ResourceException
Throws:
javax.resource.ResourceException

getJcaModel

protected JcaModel getJcaModel(java.lang.String modelName)
                        throws MuleException,
                               javax.resource.ResourceException
Throws:
MuleException
javax.resource.ResourceException

createJcaService

protected Service createJcaService(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory,
                                   JcaModel model,
                                   InboundEndpoint endpoint)
                            throws MuleException
Throws:
MuleException

createMessageInflowEndpoint

protected InboundEndpoint createMessageInflowEndpoint(MuleActivationSpec muleActivationSpec)
                                               throws MuleException
Throws:
MuleException

getXAResources

public javax.transaction.xa.XAResource[] getXAResources(javax.resource.spi.ActivationSpec[] activationSpecs)
                                                 throws javax.resource.ResourceException
We only connect to one resource manager per ResourceAdapter instance, so any ActivationSpec will return the same XAResource.

Specified by:
getXAResources in interface javax.resource.spi.ResourceAdapter
Throws:
javax.resource.ResourceException
See Also:
ResourceAdapter.getXAResources(javax.resource.spi.ActivationSpec[])

setPassword

public void setPassword(java.lang.String password)
Parameters:
password -

setConfigurations

public void setConfigurations(java.lang.String configurations)
Parameters:
configurations -

setUserName

public void setUserName(java.lang.String userid)
Parameters:
userid -

setConfigurationBuilder

public void setConfigurationBuilder(java.lang.String configbuilder)

setModelName

public void setModelName(java.lang.String modelName)

setAutoWrapMessageAwareTransform

public void setAutoWrapMessageAwareTransform(java.lang.Boolean autoWrapMessageAwareTransform)

setCacheMessageAsBytes

public void setCacheMessageAsBytes(java.lang.Boolean cacheMessageAsBytes)

setCacheMessageOriginalPayload

public void setCacheMessageOriginalPayload(java.lang.Boolean cacheMessageOriginalPayload)

setClusterId

public void setClusterId(java.lang.String clusterId)

setDefaultEncoding

public void setDefaultEncoding(java.lang.String encoding)

setDefaultQueueTimeout

public void setDefaultQueueTimeout(java.lang.Integer defaultQueueTimeout)

setDefaultResponseTimeout

public void setDefaultResponseTimeout(java.lang.Integer responseTimeout)

setDefaultSynchronousEndpoints

public void setDefaultSynchronousEndpoints(java.lang.Boolean synchronous)

setDefaultTransactionTimeout

public void setDefaultTransactionTimeout(java.lang.Integer defaultTransactionTimeout)

setDomainId

public void setDomainId(java.lang.String domainId)

setServerId

public void setServerId(java.lang.String serverId)

setShutdownTimeout

public void setShutdownTimeout(java.lang.Integer shutdownTimeout)

setWorkingDirectory

public void setWorkingDirectory(java.lang.String workingDirectory)

getConfigurationBuilder

public java.lang.String getConfigurationBuilder()

getConfigurations

public java.lang.String getConfigurations()

getUserName

public java.lang.String getUserName()

getPassword

public java.lang.String getPassword()

getModelName

public java.lang.String getModelName()

getClusterId

public java.lang.String getClusterId()

getDefaultEncoding

public java.lang.String getDefaultEncoding()

getDefaultQueueTimeout

public int getDefaultQueueTimeout()

getDefaultResponseTimeout

public int getDefaultResponseTimeout()

getDefaultTransactionTimeout

public int getDefaultTransactionTimeout()

getDomainId

public java.lang.String getDomainId()

getId

public java.lang.String getId()

getMuleHomeDirectory

public java.lang.String getMuleHomeDirectory()

getShutdownTimeout

public int getShutdownTimeout()

getSystemModelType

public java.lang.String getSystemModelType()

getSystemName

public java.lang.String getSystemName()

getWorkingDirectory

public java.lang.String getWorkingDirectory()

isAutoWrapMessageAwareTransform

public boolean isAutoWrapMessageAwareTransform()

isCacheMessageAsBytes

public boolean isCacheMessageAsBytes()

isCacheMessageOriginalPayload

public boolean isCacheMessageOriginalPayload()

isClientMode

public boolean isClientMode()

isEnableStreaming

public boolean isEnableStreaming()

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object


Copyright © 2003-2010 MuleSoft, Inc.. All Rights Reserved.