public class JmsManagedConnectionFactory extends Object implements ManagedConnectionFactory
Constructor and Description |
---|
JmsManagedConnectionFactory() |
Modifier and Type | Method and Description |
---|---|
Object |
createConnectionFactory()
Create a "non managed" connection factory.
|
Object |
createConnectionFactory(ConnectionManager cxManager)
Create a ConnectionFactory with appserver hook
|
ManagedConnection |
createManagedConnection(Subject subject,
ConnectionRequestInfo info)
Create a new connection to manage in pool
|
boolean |
equals(Object obj)
Checks for equality ower the configured properties.
|
String |
getClientID()
Get client id, may be null.
|
String |
getConnectionFactory() |
String |
getJndiParameters() |
PrintWriter |
getLogWriter()
Get the log writer for this ManagedConnectionFactory instance.
|
ConnectionMetaData |
getMetaData() |
String |
getPassword()
Get password, may be null.
|
protected JmsMCFProperties |
getProperties() |
String |
getSessionDefaultType() |
String |
getUserName()
Get userName, may be null.
|
Integer |
getUseTryLock()
Get the useTryLock.
|
int |
hashCode()
Returns the hash code for the ManagedConnectionFactory
|
Boolean |
isDeleteTemporaryDestinations() |
Boolean |
isStrict() |
ManagedConnection |
matchManagedConnections(Set connectionSet,
Subject subject,
ConnectionRequestInfo info)
Match a set of connections from the pool
|
void |
setClientID(String clientID)
Set client id, null by default.
|
void |
setConnectionFactory(String connectionFactory) |
void |
setDeleteTemporaryDestinations(Boolean deleteTemporaryDestinations) |
void |
setJndiParameters(String jndiParameters) |
void |
setLogWriter(PrintWriter out)
Set the log writer for this ManagedConnectionFactory instance.
|
void |
setPassword(String password)
Set password, null by default.
|
void |
setSessionDefaultType(String type)
Set the default session typ
|
void |
setStrict(Boolean strict) |
void |
setUserName(String userName)
Set userName, null by default.
|
void |
setUseTryLock(Integer useTryLock)
Set the useTryLock.
|
public Object createConnectionFactory() throws ResourceException
createConnectionFactory
in interface ManagedConnectionFactory
ResourceException
- Generic exceptionResourceAdapterInternalException
- Resource adapter related error conditionpublic Object createConnectionFactory(ConnectionManager cxManager) throws ResourceException
createConnectionFactory
in interface ManagedConnectionFactory
cxManager
- ConnectionManager to be associated with
created EIS connection factory instanceResourceException
- Generic exceptionResourceAdapterInternalException
- Resource adapter related error conditionpublic ManagedConnection createManagedConnection(Subject subject, ConnectionRequestInfo info) throws ResourceException
createManagedConnection
in interface ManagedConnectionFactory
subject
- Caller's security informationinfo
- Additional resource adapter specific connection
request informationResourceException
- generic exceptionSecurityException
- security related errorResourceAllocationException
- failed to allocate system resources for
connection requestResourceAdapterInternalException
- resource adapter related error conditionEISSystemException
- internal error condition in EIS instancepublic ManagedConnection matchManagedConnections(Set connectionSet, Subject subject, ConnectionRequestInfo info) throws ResourceException
matchManagedConnections
in interface ManagedConnectionFactory
connectionSet
- candidate connection setsubject
- caller's security informationinfo
- additional resource adapter specific
connection request informationResourceException
- generic exceptionSecurityException
- security related errorResourceAdapterInternalException
- resource adapter related error conditionNotSupportedException
- if operation is not supportedpublic void setLogWriter(PrintWriter out) throws ResourceException
ManagedConnectionFactory
The log writer is a character output stream to which all logging and tracing messages for this ManagedConnectionfactory instance will be printed.
ApplicationServer manages the association of output stream with the ManagedConnectionFactory. When a ManagedConnectionFactory object is created the log writer is initially null, in other words, logging is disabled. Once a log writer is associated with a ManagedConnectionFactory, logging and tracing for ManagedConnectionFactory instance is enabled.
The ManagedConnection instances created by ManagedConnectionFactory "inherits" the log writer, which can be overridden by ApplicationServer using ManagedConnection.setLogWriter to set ManagedConnection specific logging and tracing.
setLogWriter
in interface ManagedConnectionFactory
out
- PrintWriter - an out stream for
error logging and tracingResourceException
- generic exceptionResourceAdapterInternalException
- resource adapter related error conditionpublic PrintWriter getLogWriter() throws ResourceException
ManagedConnectionFactory
The log writer is a character output stream to which all logging and tracing messages for this ManagedConnectionFactory instance will be printed
ApplicationServer manages the association of output stream with the ManagedConnectionFactory. When a ManagedConnectionFactory object is created the log writer is initially null, in other words, logging is disabled.
getLogWriter
in interface ManagedConnectionFactory
ResourceException
- generic exceptionpublic boolean equals(Object obj)
equals
in interface ManagedConnectionFactory
equals
in class Object
obj
- The other objectpublic int hashCode()
ManagedConnectionFactory
hashCode
in interface ManagedConnectionFactory
hashCode
in class Object
public void setJndiParameters(String jndiParameters)
public String getJndiParameters()
public void setConnectionFactory(String connectionFactory)
public String getConnectionFactory()
public void setUserName(String userName)
public String getUserName()
public void setPassword(String password)
public String getPassword()
public String getClientID()
public void setClientID(String clientID)
public Boolean isStrict()
public void setStrict(Boolean strict)
public void setSessionDefaultType(String type) throws ResourceException
type
- either javax.jms.Topic or javax.jms.QueueResourceException
- if type was not a valid type.public String getSessionDefaultType()
public Integer getUseTryLock()
public void setUseTryLock(Integer useTryLock)
useTryLock
- the useTryLock.public void setDeleteTemporaryDestinations(Boolean deleteTemporaryDestinations)
public Boolean isDeleteTemporaryDestinations()
public ConnectionMetaData getMetaData()
protected JmsMCFProperties getProperties()
Copyright © 2018 JBoss by Red Hat. All rights reserved.