Java Doc for JMSContainerInvoker.java in  » EJB-Server-JBoss-4.2.1 » server » org » jboss » ejb » plugins » jms » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » EJB Server JBoss 4.2.1 » server » org.jboss.ejb.plugins.jms 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.jboss.ejb.plugins.jms.JMSContainerInvoker

JMSContainerInvoker
public class JMSContainerInvoker extends ServiceMBeanSupport implements EJBProxyFactory,JMSContainerInvokerMBean(Code)
EJBProxyFactory for JMS MessageDrivenBeans
author:
   Peter Antman .
author:
   Rickard Oberg
author:
   Sebastien Alborini
author:
   Marc Fleury
author:
   Jason Dillon
author:
   Adrian Brock
version:
   $Revision: 57506 $

Inner Class :class MessageListenerImpl implements MessageListener
Inner Class :class ExceptionListenerImpl implements ExceptionListener
Inner Class :interface TCLAction

Field Summary
final protected static  StringDEFAULT_DESTINATION_TYPE
     Default destination type.
protected static  MethodON_MESSAGE
    MessageListener.onMessage reference.
protected  intacknowledgeMode
     JMS acknowledge mode, used when session is not XA.
protected  Connectionconnection
     The JMS connection.
protected  ConnectionConsumerconnectionConsumer
     The JMS connection consumer.
protected  Containercontainer
     The container.
protected  booleancreateJBossMQDestination
    
protected  booleandeliveryActive
    
protected  ElementdlqConfig
     DLQConfig element from MDBConfig element from jboss.xml.
protected  DLQHandlerdlqHandler
     Dead letter queue handler.
protected  ExceptionListenerImplexListener
    
protected  StringinvokerBinding
    
protected  InvokerProxyBindingMetaDatainvokerMetaData
    
protected  booleanisContainerManagedTx
    
protected  booleanisNotSupportedTx
    
protected  longkeepAlive
     Keep alive server sessions.
protected  intmaxMessagesNr
     Maximum number provider is allowed to stuff into a session.
protected  intmaxPoolSize
     Maximun pool size of server sessions.
protected  intminPoolSize
     Minimun pool size of server sessions.
protected  booleanoptimize
    
protected  ServerSessionPoolpool
    
protected  StringproviderAdapterJNDI
     JNDI name of the provider adapter.
protected  longreconnectInterval
     Time to wait before retrying to reconnect a lost connection.
protected  StringserverSessionPoolFactoryJNDI
     JNDI name of the server session factory.
protected  TransactionManagertm
    
protected  booleanuseDLQ
     If Dead letter queue should be used or not.


Method Summary
protected  DestinationcreateDestination(Class type, Context ctx, String jndiName, String jndiSuffix)
     Create and or lookup a JMS destination.
Parameters:
  type - Either javax.jms.Queue or javax.jms.Topic.
Parameters:
  ctx - The naming context to lookup destinations from.
Parameters:
  jndiName - The name to use when looking up destinations.
Parameters:
  jndiSuffix - The name to use when creating destinations.
protected  voidcreateService()
     Initialize the container invoker.
protected  ServerSessionPoolcreateSessionPool(Destination destination, Connection connection, int minSession, int maxSession, long keepAlive, boolean isTransacted, int ack, MessageListener listener)
     Create a server session pool for the given connection.
Parameters:
  destination - the destination
Parameters:
  connection - The connection to use.
Parameters:
  minSession - The minumum number of sessions
Parameters:
  maxSession - The maximum number of sessions.
Parameters:
  keepAlive - The time to keep sessions alive
Parameters:
  isTransacted - True if the sessions are transacted.
Parameters:
  ack - The session acknowledgement mode.
Parameters:
  listener - The message listener.
protected  StringgetActivationConfigProperty(String property)
    
public  booleangetCreateJBossMQDestination()
    
public  booleangetDeliveryActive()
    
protected  StringgetDestinationType(Context ctx, String destinationJNDI)
     Try to get a destination type by looking up the destination JNDI, or provide a default if there is not destinationJNDI or if it is not possible to lookup.
Parameters:
  ctx - The naming context to lookup destinations from.
Parameters:
  destinationJNDI - The name to use when looking up destinations.
public  ObjectgetEJBHome()
    
public  EJBMetaDatagetEJBMetaData()
    
public  CollectiongetEntityCollection(Collection ids)
    
public  ObjectgetEntityEJBObject(Object id)
    
protected  JMSProviderAdaptergetJMSProviderAdapter()
     Return the JMSProviderAdapter that should be used.
public  longgetKeepAliveMillis()
    
public  intgetMaxMessages()
    
public  intgetMaxPoolSize()
    
public  MessageDrivenMetaDatagetMetaData()
    
public  intgetMinPoolSize()
    
public  ObjectgetStatefulSessionEJBObject(Object id)
    
public  ObjectgetStatelessSessionEJBObject()
    
public  voidimportXml(Element element)
     XmlLoadable implementation.
protected  voidinnerStartDelivery()
     Initialize the container invoker.
protected  voidinnerStopDelivery()
     Stop done from inside, we should not stop the exceptionListener in inner stop.
public  Objectinvoke(Object id, Method m, Object[] args, Transaction tx, Principal identity, Object credential)
    
public  booleanisIdentical(Container container, Invocation mi)
    
public  booleanisOptimized()
    
protected  StringparseJndiSuffix(String jndiname, String defautSuffix)
     Parse the JNDI suffix from the given JNDI name.
protected  voidsendNotification(String event, Object userData)
     Notify of an event
Parameters:
  event - the event
Parameters:
  userData - any user data, e.g.
public  voidsetContainer(Container container)
     Set the container for which this is an invoker to.
public  voidsetInvokerBinding(String binding)
    
public  voidsetInvokerMetaData(InvokerProxyBindingMetaData imd)
    
public  voidsetKeepAliveMillis(long keepAlive)
    
public  voidsetMaxMessages(int maxMessages)
    
public  voidsetMaxPoolSize(int maxPoolSize)
    
public  voidsetMinPoolSize(int minPoolSize)
    
public  voidsetOptimized(boolean optimize)
    
public  voidstartDelivery()
    
protected  voidstartService()
    
public  voidstopDelivery()
    
protected  voidstopService()
    
public  StringtoString()
     Return a string representation of the current config state.

Field Detail
DEFAULT_DESTINATION_TYPE
final protected static String DEFAULT_DESTINATION_TYPE(Code)
Default destination type. Used when no message-driven-destination is given in ejb-jar, and a lookup of destinationJNDI from jboss.xml is not successfull. Default value: javax.jms.Topic.



ON_MESSAGE
protected static Method ON_MESSAGE(Code)
MessageListener.onMessage reference.



acknowledgeMode
protected int acknowledgeMode(Code)
JMS acknowledge mode, used when session is not XA.



connection
protected Connection connection(Code)
The JMS connection.



connectionConsumer
protected ConnectionConsumer connectionConsumer(Code)
The JMS connection consumer.



container
protected Container container(Code)
The container.



createJBossMQDestination
protected boolean createJBossMQDestination(Code)



deliveryActive
protected boolean deliveryActive(Code)



dlqConfig
protected Element dlqConfig(Code)
DLQConfig element from MDBConfig element from jboss.xml.



dlqHandler
protected DLQHandler dlqHandler(Code)
Dead letter queue handler.



exListener
protected ExceptionListenerImpl exListener(Code)



invokerBinding
protected String invokerBinding(Code)



invokerMetaData
protected InvokerProxyBindingMetaData invokerMetaData(Code)



isContainerManagedTx
protected boolean isContainerManagedTx(Code)



isNotSupportedTx
protected boolean isNotSupportedTx(Code)



keepAlive
protected long keepAlive(Code)
Keep alive server sessions.



maxMessagesNr
protected int maxMessagesNr(Code)
Maximum number provider is allowed to stuff into a session.



maxPoolSize
protected int maxPoolSize(Code)
Maximun pool size of server sessions.



minPoolSize
protected int minPoolSize(Code)
Minimun pool size of server sessions.



optimize
protected boolean optimize(Code)



pool
protected ServerSessionPool pool(Code)



providerAdapterJNDI
protected String providerAdapterJNDI(Code)
JNDI name of the provider adapter.
See Also:   org.jboss.jms.jndi.JMSProviderAdapter



reconnectInterval
protected long reconnectInterval(Code)
Time to wait before retrying to reconnect a lost connection.



serverSessionPoolFactoryJNDI
protected String serverSessionPoolFactoryJNDI(Code)
JNDI name of the server session factory.
See Also:   org.jboss.jms.asf.ServerSessionPoolFactory



tm
protected TransactionManager tm(Code)



useDLQ
protected boolean useDLQ(Code)
If Dead letter queue should be used or not.





Method Detail
createDestination
protected Destination createDestination(Class type, Context ctx, String jndiName, String jndiSuffix) throws Exception(Code)
Create and or lookup a JMS destination.
Parameters:
  type - Either javax.jms.Queue or javax.jms.Topic.
Parameters:
  ctx - The naming context to lookup destinations from.
Parameters:
  jndiName - The name to use when looking up destinations.
Parameters:
  jndiSuffix - The name to use when creating destinations. The destination.
throws:
  IllegalArgumentException - Type is not Queue or Topic.
throws:
  Exception - Description of Exception



createService
protected void createService() throws Exception(Code)
Initialize the container invoker. Sets up a connection, a server session pool and a connection consumer for the configured destination.

Any JMSExceptions produced while initializing will be assumed to be caused due to JMS Provider failure.
throws:
  Exception - Failed to initalize.




createSessionPool
protected ServerSessionPool createSessionPool(Destination destination, Connection connection, int minSession, int maxSession, long keepAlive, boolean isTransacted, int ack, MessageListener listener) throws NamingException, JMSException(Code)
Create a server session pool for the given connection.
Parameters:
  destination - the destination
Parameters:
  connection - The connection to use.
Parameters:
  minSession - The minumum number of sessions
Parameters:
  maxSession - The maximum number of sessions.
Parameters:
  keepAlive - The time to keep sessions alive
Parameters:
  isTransacted - True if the sessions are transacted.
Parameters:
  ack - The session acknowledgement mode.
Parameters:
  listener - The message listener. A server session pool.
throws:
  JMSException -
throws:
  NamingException - Description of Exception



getActivationConfigProperty
protected String getActivationConfigProperty(String property)(Code)



getCreateJBossMQDestination
public boolean getCreateJBossMQDestination()(Code)



getDeliveryActive
public boolean getDeliveryActive()(Code)



getDestinationType
protected String getDestinationType(Context ctx, String destinationJNDI)(Code)
Try to get a destination type by looking up the destination JNDI, or provide a default if there is not destinationJNDI or if it is not possible to lookup.
Parameters:
  ctx - The naming context to lookup destinations from.
Parameters:
  destinationJNDI - The name to use when looking up destinations. The destination type, either derived from destinationJDNI orDEFAULT_DESTINATION_TYPE



getEJBHome
public Object getEJBHome()(Code)



getEJBMetaData
public EJBMetaData getEJBMetaData()(Code)



getEntityCollection
public Collection getEntityCollection(Collection ids)(Code)



getEntityEJBObject
public Object getEntityEJBObject(Object id)(Code)



getJMSProviderAdapter
protected JMSProviderAdapter getJMSProviderAdapter() throws NamingException(Code)
Return the JMSProviderAdapter that should be used. The JMSProviderAdapter to use.



getKeepAliveMillis
public long getKeepAliveMillis()(Code)



getMaxMessages
public int getMaxMessages()(Code)



getMaxPoolSize
public int getMaxPoolSize()(Code)



getMetaData
public MessageDrivenMetaData getMetaData()(Code)



getMinPoolSize
public int getMinPoolSize()(Code)



getStatefulSessionEJBObject
public Object getStatefulSessionEJBObject(Object id)(Code)



getStatelessSessionEJBObject
public Object getStatelessSessionEJBObject()(Code)



importXml
public void importXml(Element element) throws Exception(Code)
XmlLoadable implementation.
Parameters:
  element - Description of Parameter
throws:
  DeploymentException - Description of Exception



innerStartDelivery
protected void innerStartDelivery() throws Exception(Code)
Initialize the container invoker. Sets up a connection, a server session pool and a connection consumer for the configured destination.
throws:
  Exception - Failed to initalize.



innerStopDelivery
protected void innerStopDelivery()(Code)
Stop done from inside, we should not stop the exceptionListener in inner stop.



invoke
public Object invoke(Object id, Method m, Object[] args, Transaction tx, Principal identity, Object credential) throws Exception(Code)



isIdentical
public boolean isIdentical(Container container, Invocation mi)(Code)



isOptimized
public boolean isOptimized()(Code)



parseJndiSuffix
protected String parseJndiSuffix(String jndiname, String defautSuffix)(Code)
Parse the JNDI suffix from the given JNDI name.
Parameters:
  jndiname - The JNDI name used to lookup the destination.
Parameters:
  defautSuffix - Description of Parameter The parsed suffix or the defaultSuffix



sendNotification
protected void sendNotification(String event, Object userData)(Code)
Notify of an event
Parameters:
  event - the event
Parameters:
  userData - any user data, e.g. the exception on a failure



setContainer
public void setContainer(Container container)(Code)
Set the container for which this is an invoker to.
Parameters:
  container - The container for which this is an invoker to.



setInvokerBinding
public void setInvokerBinding(String binding)(Code)
Set the invoker jndi binding



setInvokerMetaData
public void setInvokerMetaData(InvokerProxyBindingMetaData imd)(Code)
Set the invoker meta data so that the ProxyFactory can initialize properly



setKeepAliveMillis
public void setKeepAliveMillis(long keepAlive)(Code)



setMaxMessages
public void setMaxMessages(int maxMessages)(Code)



setMaxPoolSize
public void setMaxPoolSize(int maxPoolSize)(Code)



setMinPoolSize
public void setMinPoolSize(int minPoolSize)(Code)



setOptimized
public void setOptimized(boolean optimize)(Code)
Sets the Optimized attribute of the JMSContainerInvoker object
Parameters:
  optimize - The new Optimized value



startDelivery
public void startDelivery() throws Exception(Code)



startService
protected void startService() throws Exception(Code)



stopDelivery
public void stopDelivery() throws Exception(Code)



stopService
protected void stopService() throws Exception(Code)



toString
public String toString()(Code)
Return a string representation of the current config state.



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.