Package org.apache.activemq.command
Class BrokerInfo
java.lang.Object
org.apache.activemq.command.BaseCommand
org.apache.activemq.command.BrokerInfo
- All Implemented Interfaces:
Command
,DataStructure
When a client connects to a broker, the broker send the client a BrokerInfo
so that the client knows which broker node he's talking to and also any peers
that the node has in his cluster. This is the broker helping the client out
in discovering other nodes in the cluster.
-
Field Summary
FieldsFields inherited from class org.apache.activemq.command.BaseCommand
commandId, responseRequired
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()
int
The URL to use when uploading BLOBs to the broker or some other external file/http serverlong
The broker assigns a each connection it accepts a connection id.byte
int
void
boolean
boolean
boolean
boolean
boolean
boolean
boolean
void
setBrokerId
(BrokerId brokerId) void
setBrokerName
(String brokerName) void
setBrokerUploadUrl
(String brokerUploadUrl) void
setBrokerURL
(String brokerURL) void
setConnectionId
(long connectionId) void
setDuplexConnection
(boolean duplexConnection) void
setFaultTolerantConfiguration
(boolean faultTolerantConfiguration) void
setMasterBroker
(boolean masterBroker) void
setNetworkConnection
(boolean networkConnection) void
setNetworkProperties
(String networkProperties) void
setPassiveSlave
(boolean value) void
setPeerBrokerInfos
(BrokerInfo[] peerBrokerInfos) void
setSlaveBroker
(boolean slaveBroker) visit
(CommandVisitor visitor) Methods inherited from class org.apache.activemq.command.BaseCommand
copy, getCommandId, getFrom, getTo, isConnectionControl, isConsumerControl, isMarshallAware, isMessage, isMessageAck, isMessageDispatch, isMessageDispatchNotification, isResponse, isResponseRequired, isShutdownInfo, isWireFormatInfo, setCommandId, setFrom, setResponseRequired, setTo, toString, toString
-
Field Details
-
DATA_STRUCTURE_TYPE
public static final byte DATA_STRUCTURE_TYPE- See Also:
-
-
Constructor Details
-
BrokerInfo
public BrokerInfo()
-
-
Method Details
-
copy
-
isBrokerInfo
public boolean isBrokerInfo()- Specified by:
isBrokerInfo
in interfaceCommand
- Overrides:
isBrokerInfo
in classBaseCommand
-
getDataStructureType
public byte getDataStructureType()- Returns:
- The type of the data structure
-
getBrokerId
-
setBrokerId
-
getBrokerURL
-
setBrokerURL
-
getPeerBrokerInfos
-
setPeerBrokerInfos
-
getBrokerName
-
setBrokerName
-
visit
- Throws:
Exception
-
isSlaveBroker
public boolean isSlaveBroker() -
setSlaveBroker
public void setSlaveBroker(boolean slaveBroker) -
isMasterBroker
public boolean isMasterBroker() -
setMasterBroker
public void setMasterBroker(boolean masterBroker) - Parameters:
masterBroker
- The masterBroker to set.
-
isFaultTolerantConfiguration
public boolean isFaultTolerantConfiguration()- Returns:
- Returns the faultTolerantConfiguration.
-
setFaultTolerantConfiguration
public void setFaultTolerantConfiguration(boolean faultTolerantConfiguration) - Parameters:
faultTolerantConfiguration
- The faultTolerantConfiguration to set.
-
isDuplexConnection
public boolean isDuplexConnection()- Returns:
- the duplexConnection
-
setDuplexConnection
public void setDuplexConnection(boolean duplexConnection) - Parameters:
duplexConnection
- the duplexConnection to set
-
isNetworkConnection
public boolean isNetworkConnection()- Returns:
- the networkConnection
-
setNetworkConnection
public void setNetworkConnection(boolean networkConnection) - Parameters:
networkConnection
- the networkConnection to set
-
getConnectionId
public long getConnectionId()The broker assigns a each connection it accepts a connection id. -
setConnectionId
public void setConnectionId(long connectionId) -
getBrokerUploadUrl
The URL to use when uploading BLOBs to the broker or some other external file/http server -
setBrokerUploadUrl
-
getNetworkProperties
- Returns:
- the networkProperties
-
setNetworkProperties
- Parameters:
networkProperties
- the networkProperties to set
-
isPassiveSlave
public boolean isPassiveSlave() -
setPassiveSlave
public void setPassiveSlave(boolean value) -
getProperties
-
getRefCount
public int getRefCount() -
incrementRefCount
public void incrementRefCount() -
decrementRefCount
public int decrementRefCount()
-