xmlBlaster 2.2.0 API

org.xmlBlaster.util.admin.extern
Class XmlBlasterConnector

java.lang.Object
  extended by org.xmlBlaster.util.admin.extern.XmlBlasterConnector
All Implemented Interfaces:
I_Callback, XmlBlasterConnectorMBean

public class XmlBlasterConnector
extends java.lang.Object
implements XmlBlasterConnectorMBean, I_Callback

XmlBlasterConnector is a tiny embedded xmlBlaster server instance. It is both publisher and subscriber to a topic. XmlBlasterConnector extracts MethodInvocation Object from the Message Unit and handles the invocation, stores the return value


Field Summary
private  EmbeddedXmlBlaster embeddedXmlBlaster
           
static int FINISHED
           
private  Global glob
           
 boolean jmxInterfaceAlive
           
private static java.util.logging.Logger log
           
private static int port
           
static int SENDING
           
private  SerializeHelper serHelp
           
private  javax.management.MBeanServer server
           
static int UNKNOWN
           
private  I_XmlBlasterAccess xmlBlasterAccess
           
 
Constructor Summary
XmlBlasterConnector()
           
 
Method Summary
private  void addNotification(MethodInvocation mi)
           
 boolean isConnectorAlive()
          Display internal status to Management
private  void removeNotification(MethodInvocation mi)
           
 void start(java.lang.String agentID)
          Starts the connector - starts an embedded xmlBlaster that listens on port 3424 Subscribes to topic where MethodInvocations are placed Starts another (new!) MBeanServer
 void startEmbeddedXmlBlasterServer()
          Start EmbeddedXmlBlaster
 void startInternal(javax.management.MBeanServer server)
          Starts the connector - starts an embedded xmlBlaster that listens on port 3424 Subscribes to topic where MethodInvocations are placed Uses MBeanServer from JMXWrapper
 void stop(java.lang.String agentId)
          Stop Service
 java.lang.String update(java.lang.String cbSessionId, UpdateKey updateKey, byte[] content, UpdateQos updateQos)
          update() is invoked, when a methodInvocation for the given key arrives MethodInvocation is deserialized, the method is invoked and the return value is stored (within the MethodInvocation Object)
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

xmlBlasterAccess

private I_XmlBlasterAccess xmlBlasterAccess

server

private javax.management.MBeanServer server

serHelp

private SerializeHelper serHelp

log

private static java.util.logging.Logger log

glob

private Global glob

embeddedXmlBlaster

private EmbeddedXmlBlaster embeddedXmlBlaster

port

private static int port

UNKNOWN

public static int UNKNOWN

SENDING

public static int SENDING

FINISHED

public static int FINISHED

jmxInterfaceAlive

public boolean jmxInterfaceAlive
Constructor Detail

XmlBlasterConnector

public XmlBlasterConnector()
Method Detail

start

public void start(java.lang.String agentID)
Starts the connector - starts an embedded xmlBlaster that listens on port 3424 Subscribes to topic where MethodInvocations are placed Starts another (new!) MBeanServer

Specified by:
start in interface XmlBlasterConnectorMBean

startInternal

public void startInternal(javax.management.MBeanServer server)
Starts the connector - starts an embedded xmlBlaster that listens on port 3424 Subscribes to topic where MethodInvocations are placed Uses MBeanServer from JMXWrapper

Specified by:
startInternal in interface XmlBlasterConnectorMBean

startEmbeddedXmlBlasterServer

public void startEmbeddedXmlBlasterServer()
Start EmbeddedXmlBlaster


update

public java.lang.String update(java.lang.String cbSessionId,
                               UpdateKey updateKey,
                               byte[] content,
                               UpdateQos updateQos)
update() is invoked, when a methodInvocation for the given key arrives MethodInvocation is deserialized, the method is invoked and the return value is stored (within the MethodInvocation Object)

Specified by:
update in interface I_Callback
Parameters:
cbSessionId - The session ID specified by the client which registered the callback. You can specify a cbSessionId during connection (with ConnectQos) and this is bounced back here so you can authenticate the message.
updateKey - The arrived key containing the topic name
content - The arrived message content. This is your payload.
See Also:
I_XmlBlasterAccess

removeNotification

private void removeNotification(MethodInvocation mi)

addNotification

private void addNotification(MethodInvocation mi)

isConnectorAlive

public boolean isConnectorAlive()
Display internal status to Management

Specified by:
isConnectorAlive in interface XmlBlasterConnectorMBean

stop

public void stop(java.lang.String agentId)
Stop Service

Specified by:
stop in interface XmlBlasterConnectorMBean

xmlBlaster 2.2.0 API

Copyright © 1999-2014 The xmlBlaster.org contributers.