Previous Topic Next topic Print topic


Class MFECIResourceAdapter

This represents a resource adapter instance and contains operations for lifecycle management and message endpoint setup.
java.lang.Object

extended by com.microfocus.cics.connector.spi.ResourceAdapter

All Implemented Interfaces

Serializable, javax.resource.spi.ResourceAdapter

Class Specifications

public class ResourceAdapter

extends Object

implements javax.resource.spi.ResourceAdapter, Serializable

See Also:

Serialized Form

Constructor Summary

MFECIResourceAdapter()
Constructor.

Methods

Method Summary
void endpointActivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory, javax.resource.spi.ActivationSpec spec)

Called by the Application Server when a message-driven bean (MessageEndpoint) is deployed.

void endpointDeactivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory, javax.resource.spi.ActivationSpec spec)

Called by Application Server when the MessageEndpoint (message-driven bean) is undeployed.

javax.resource.spi.ActivationSpec getEnterpriseServerSocketCloseDueToInactivity()
Integer getReadTimeoutInSeconds()
Boolean getSecureConnection()
Boolean getSecureGUID()

Get secure GUID

String getServerHost()

Get the server host.

String getServerPort()

Get the server port.

Boolean getTrace()

Check to ensure tracing is enabled.

XAResource[] getXAResources(javax.resource.spi.ActivationSpec[] specs)

This method is called by the application server on the restart of the application server when there are potential pending transactions.

void setEnterpriseServerSocketCloseDueToInactivity(Integer t)
void setReadTimeoutInSeconds(Integer readTimeoutInSeconds)

Set ReadTimeoutInSeconds

void setSecureConnection(Boolean secureConnection)
void setSecureGUID(Boolean s)

Set secure GUID.

void setServerHost(String serverHost)

Set the server host.

void setServerPort(String serverPort)

Set the server port.

void setTrace(Boolean trace)

Set tracing.

void start(javax.resource.spi.BootstrapContext ctx)

Called by the application server to initialize the resource adapter.

stop stop()
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail

serverHost
protected String serverHost
serverPort
protected String serverPort
logHost
protected String logHost
logPort
protected String logPort
trace
protected Boolean trace
secureGUID
protected Boolean secureGUID
readTimeoutInSeconds
protected Integer readTimeoutInSeconds

Constructor Detail

MFECIResourceAdapter
public MFECIResourceAdapter

Constructor.

Method Detail

start
public void start(javax.resource.spi.BootstrapContext ctx)
                        throws javax.resource.spi.ResourceAdapterInternalException

Called by the AppServer to initialize the Resource Adapter.

Specified by:
start in interface javax.resource.spi.ResourceAdapter
Parameters:
ctx The bootstrapContext.
Throws:
javax.resource.spi.ResourceAdapterInternalException
stop
public void stop()
Specified by:
stop in interface javax.resource.spi.ResourceAdapter
endPointActivation
public void endPointActivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory,
                               javax.resource.spi.ActivationSpec spec)
                        throws javax.resource.NotSupportedException

Called by the Application Server when a message-driven bean (MessageEndpoint) is deployed. Causes the resource adapter instance to do the necessary setup (setting up message delivery for the message endpoint with a message provider).

Specified by:
endpointActivation in interface javax.resource.spi.ResourceAdapter
Parameters:
endpointFactory A message endpoint factory instance.
spec An ActivationSpec instance.
Throws:
javax.resource.NotSupportedException

If message endpoint activation is rejected because of incorrect activation setup information.

endpointDeactivation
public void endPointDeactivation(javax.resource.spi.endpoint.MessageEndpointFactory endpointFactory,
                                 javax.resource.spi.ActivationSpec spec)

Called by Application Server when the MessageEndpoint (message-driven bean) is undeployed. The instance passed as arguments to this method call should be identical to that passed in for the corresponding endpointActivation call. This causes the resource adapter to stop delivering messages to the message endpoint.

Specified by:
endpointDeactivation in interface javax.resource.spi.ResourceAdapter
Parameters:
endpointFactory A message endpoint factory instance.
spec An activation spec instance.
getXAResources
public XAResource[] getXAResources(javax.resource.spi.ActivationSpec[] specs)
                                  throws javax.resource.ResourceException

This method is called by the application server during crash recovery. This method takes in an array of ActivationSpec JavaBeans and returns an array of XAResource objects each of which represents a unique resource manager. The resource adapter may return null if it does not implement the XAResource interface. Otherwise, it must return an array of XAResource objects, each of which represents a unique resource manager that was used by the endpoint applications. The application server uses the XAResource objects to query each resource manager for a list of in-doubt transactions. It then completes each pending transaction by sending the commit decision to the participating resource managers.

Specified by:
getXAResources in interface javax.resource.spi.ResourceAdapter
Parameters:
specs An array of ActivationSpec JavaBeans each of which corresponds to an deployed endpoint application that was active prior to the system crash.
Returns:
An array of XAResource objects each of which represents a unique resource manager.
Throws:
javax.resource.ResourceException
setServerHost
public void setServerHost (String serverHost)

Set the server host.

Parameters:
serverHost
getServerHost
public String getServerHost()

Get the server host.

Returns:
The server host.
setServerPort
public void setServerPort(String serverPort)

Set the server port.

Parameters:
serverPort
getServerPort
public String getServerPort()

Get the server port.

Returns:
The server port.
setTrace
public void setTrace(Boolean trace)

Set tracing.

Parameters:
trace
getTrace
public Boolean getTrace()

Check to ensure that tracing is enabled.

Returns:
true if it does; false otherwise
setSecureGUID
public void setSecureGUID(Boolean s)

Set secure GUID.

Parameters:
s
getSecureGUID
public Boolean getSecureGUID()

Check to ensure that secure GUID is enabled.

Returns:
true if it does; false otherwise
setReadTimeoutInSeconds
public void setReadTimeoutInSeconds(Integer readTimeoutInSeconds)

Set ReadTimeoutInSeconds.

Parameters:
readTimeoutInSeconds
getReadTimeoutInSeconds
public Integer getReadTimeoutInSeconds()

Get ReadTimeoutInSeconds

Returns:
readTimeoutInSeconds
setEnterpriseServerSocketCloseDueToInactivity
public void getEnterpriseServerSocketCloseDueToInactivity(Integer t)
getEnterpriseServerSocketCloseDueToInactivity
public Integer getEnterpriseServerSocketCloseDueToInactivity()
setSecureConnection
public void setSecureConnection(Boolean secureConnection)

Set the secure connection.

Parameters:
secureConnection
getSecureConnection
public Integer getSecureConnection()

Get the secure connection.

Returns:
The secureConnection.
Previous Topic Next topic Print topic