You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ra...@apache.org on 2006/10/10 00:09:55 UTC
svn commit: r454532 - in /incubator/activemq/trunk/activemq-core/src:
main/java/org/apache/activemq/command/
main/java/org/apache/activemq/openwire/v2/
test/java/org/apache/activemq/openwire/v2/
Author: rajdavies
Date: Mon Oct 9 15:09:54 2006
New Revision: 454532
URL: http://svn.apache.org/viewvc?view=rev&rev=454532
Log:
added additional properties for network control etc
Modified:
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/BrokerInfo.java
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConnectionInfo.java
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConsumerControl.java
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/BrokerInfoMarshaller.java
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConnectionInfoMarshaller.java
incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConsumerControlMarshaller.java
incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/BrokerInfoTest.java
incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConnectionInfoTest.java
incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConsumerControlTest.java
Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/BrokerInfo.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/BrokerInfo.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/BrokerInfo.java (original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/BrokerInfo.java Mon Oct 9 15:09:54 2006
@@ -33,6 +33,8 @@
boolean slaveBroker;
boolean masterBroker;
boolean faultTolerantConfiguration;
+ boolean networkConnection;
+ boolean duplexConnection;
BrokerInfo peerBrokerInfos[];
String brokerName;
@@ -132,5 +134,39 @@
*/
public void setFaultTolerantConfiguration(boolean faultTolerantConfiguration){
this.faultTolerantConfiguration=faultTolerantConfiguration;
+ }
+
+
+ /**
+ * @openwire:property version=2
+ * @return the duplexConnection
+ */
+ public boolean isDuplexConnection(){
+ return this.duplexConnection;
+ }
+
+
+ /**
+ * @param duplexConnection the duplexConnection to set
+ */
+ public void setDuplexConnection(boolean duplexConnection){
+ this.duplexConnection=duplexConnection;
+ }
+
+
+ /**
+ * @openwire:property version=2
+ * @return the networkConnection
+ */
+ public boolean isNetworkConnection(){
+ return this.networkConnection;
+ }
+
+
+ /**
+ * @param networkConnection the networkConnection to set
+ */
+ public void setNetworkConnection(boolean networkConnection){
+ this.networkConnection=networkConnection;
}
}
Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConnectionInfo.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConnectionInfo.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConnectionInfo.java (original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConnectionInfo.java Mon Oct 9 15:09:54 2006
@@ -36,6 +36,7 @@
protected BrokerId[] brokerPath;
protected boolean brokerMasterConnector;
protected boolean manageable;
+ protected boolean clientMaster;
protected transient Object transportContext;
public ConnectionInfo() {
@@ -165,5 +166,20 @@
public void setTransportContext(Object transportContext) {
this.transportContext = transportContext;
}
+
+ /**
+ * @openwire:property version=2
+ * @return the clientMaster
+ */
+ public boolean isClientMaster(){
+ return this.clientMaster;
+ }
+
+ /**
+ * @param clientMaster the clientMaster to set
+ */
+ public void setClientMaster(boolean clientMaster){
+ this.clientMaster=clientMaster;
+ }
}
Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConsumerControl.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConsumerControl.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConsumerControl.java (original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/command/ConsumerControl.java Mon Oct 9 15:09:54 2006
@@ -32,6 +32,9 @@
protected ConsumerId consumerId;
protected boolean close;
+ protected boolean stop;
+ protected boolean start;
+ protected boolean flush;
protected int prefetch;
public byte getDataStructureType() {
return DATA_STRUCTURE_TYPE;
@@ -112,5 +115,80 @@
*/
public void setPrefetch(int prefetch){
this.prefetch=prefetch;
+ }
+
+
+
+
+
+
+ /**
+ * @openwire:property version=2
+ * @return the flush
+ */
+ public boolean isFlush(){
+ return this.flush;
+ }
+
+
+
+
+
+
+ /**
+ * @param flush the flush to set
+ */
+ public void setFlush(boolean flush){
+ this.flush=flush;
+ }
+
+
+
+
+
+
+ /**
+ * @openwire:property version=2
+ * @return the start
+ */
+ public boolean isStart(){
+ return this.start;
+ }
+
+
+
+
+
+
+ /**
+ * @param start the start to set
+ */
+ public void setStart(boolean start){
+ this.start=start;
+ }
+
+
+
+
+
+
+ /**
+ * @openwire:property version=2
+ * @return the stop
+ */
+ public boolean isStop(){
+ return this.stop;
+ }
+
+
+
+
+
+
+ /**
+ * @param stop the stop to set
+ */
+ public void setStop(boolean stop){
+ this.stop=stop;
}
}
Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/BrokerInfoMarshaller.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/BrokerInfoMarshaller.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/BrokerInfoMarshaller.java (original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/BrokerInfoMarshaller.java Mon Oct 9 15:09:54 2006
@@ -84,6 +84,8 @@
info.setSlaveBroker(bs.readBoolean());
info.setMasterBroker(bs.readBoolean());
info.setFaultTolerantConfiguration(bs.readBoolean());
+ info.setDuplexConnection(bs.readBoolean());
+ info.setNetworkConnection(bs.readBoolean());
}
@@ -103,6 +105,8 @@
bs.writeBoolean(info.isSlaveBroker());
bs.writeBoolean(info.isMasterBroker());
bs.writeBoolean(info.isFaultTolerantConfiguration());
+ bs.writeBoolean(info.isDuplexConnection());
+ bs.writeBoolean(info.isNetworkConnection());
return rc + 0;
}
@@ -125,6 +129,8 @@
bs.readBoolean();
bs.readBoolean();
bs.readBoolean();
+ bs.readBoolean();
+ bs.readBoolean();
}
@@ -157,6 +163,8 @@
info.setSlaveBroker(dataIn.readBoolean());
info.setMasterBroker(dataIn.readBoolean());
info.setFaultTolerantConfiguration(dataIn.readBoolean());
+ info.setDuplexConnection(dataIn.readBoolean());
+ info.setNetworkConnection(dataIn.readBoolean());
}
@@ -176,6 +184,8 @@
dataOut.writeBoolean(info.isSlaveBroker());
dataOut.writeBoolean(info.isMasterBroker());
dataOut.writeBoolean(info.isFaultTolerantConfiguration());
+ dataOut.writeBoolean(info.isDuplexConnection());
+ dataOut.writeBoolean(info.isNetworkConnection());
}
}
Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConnectionInfoMarshaller.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConnectionInfoMarshaller.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConnectionInfoMarshaller.java (original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConnectionInfoMarshaller.java Mon Oct 9 15:09:54 2006
@@ -84,6 +84,7 @@
}
info.setBrokerMasterConnector(bs.readBoolean());
info.setManageable(bs.readBoolean());
+ info.setClientMaster(bs.readBoolean());
}
@@ -103,6 +104,7 @@
rc += tightMarshalObjectArray1(wireFormat, info.getBrokerPath(), bs);
bs.writeBoolean(info.isBrokerMasterConnector());
bs.writeBoolean(info.isManageable());
+ bs.writeBoolean(info.isClientMaster());
return rc + 0;
}
@@ -125,6 +127,7 @@
tightMarshalObjectArray2(wireFormat, info.getBrokerPath(), dataOut, bs);
bs.readBoolean();
bs.readBoolean();
+ bs.readBoolean();
}
@@ -157,6 +160,7 @@
}
info.setBrokerMasterConnector(dataIn.readBoolean());
info.setManageable(dataIn.readBoolean());
+ info.setClientMaster(dataIn.readBoolean());
}
@@ -176,6 +180,7 @@
looseMarshalObjectArray(wireFormat, info.getBrokerPath(), dataOut);
dataOut.writeBoolean(info.isBrokerMasterConnector());
dataOut.writeBoolean(info.isManageable());
+ dataOut.writeBoolean(info.isClientMaster());
}
}
Modified: incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConsumerControlMarshaller.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConsumerControlMarshaller.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConsumerControlMarshaller.java (original)
+++ incubator/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/openwire/v2/ConsumerControlMarshaller.java Mon Oct 9 15:09:54 2006
@@ -69,6 +69,9 @@
info.setClose(bs.readBoolean());
info.setConsumerId((org.apache.activemq.command.ConsumerId) tightUnmarsalNestedObject(wireFormat, dataIn, bs));
info.setPrefetch(dataIn.readInt());
+ info.setFlush(bs.readBoolean());
+ info.setStart(bs.readBoolean());
+ info.setStop(bs.readBoolean());
}
@@ -83,6 +86,9 @@
int rc = super.tightMarshal1(wireFormat, o, bs);
bs.writeBoolean(info.isClose());
rc += tightMarshalNestedObject1(wireFormat, (DataStructure)info.getConsumerId(), bs);
+ bs.writeBoolean(info.isFlush());
+ bs.writeBoolean(info.isStart());
+ bs.writeBoolean(info.isStop());
return rc + 4;
}
@@ -101,6 +107,9 @@
bs.readBoolean();
tightMarshalNestedObject2(wireFormat, (DataStructure)info.getConsumerId(), dataOut, bs);
dataOut.writeInt(info.getPrefetch());
+ bs.readBoolean();
+ bs.readBoolean();
+ bs.readBoolean();
}
@@ -118,6 +127,9 @@
info.setClose(dataIn.readBoolean());
info.setConsumerId((org.apache.activemq.command.ConsumerId) looseUnmarsalNestedObject(wireFormat, dataIn));
info.setPrefetch(dataIn.readInt());
+ info.setFlush(dataIn.readBoolean());
+ info.setStart(dataIn.readBoolean());
+ info.setStop(dataIn.readBoolean());
}
@@ -133,6 +145,9 @@
dataOut.writeBoolean(info.isClose());
looseMarshalNestedObject(wireFormat, (DataStructure)info.getConsumerId(), dataOut);
dataOut.writeInt(info.getPrefetch());
+ dataOut.writeBoolean(info.isFlush());
+ dataOut.writeBoolean(info.isStart());
+ dataOut.writeBoolean(info.isStop());
}
}
Modified: incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/BrokerInfoTest.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/BrokerInfoTest.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/BrokerInfoTest.java (original)
+++ incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/BrokerInfoTest.java Mon Oct 9 15:09:54 2006
@@ -64,5 +64,7 @@
info.setSlaveBroker(true);
info.setMasterBroker(false);
info.setFaultTolerantConfiguration(true);
+ info.setDuplexConnection(false);
+ info.setNetworkConnection(true);
}
}
Modified: incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConnectionInfoTest.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConnectionInfoTest.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConnectionInfoTest.java (original)
+++ incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConnectionInfoTest.java Mon Oct 9 15:09:54 2006
@@ -64,5 +64,6 @@
}
info.setBrokerMasterConnector(true);
info.setManageable(false);
+ info.setClientMaster(true);
}
}
Modified: incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConsumerControlTest.java
URL: http://svn.apache.org/viewvc/incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConsumerControlTest.java?view=diff&rev=454532&r1=454531&r2=454532
==============================================================================
--- incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConsumerControlTest.java (original)
+++ incubator/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/openwire/v2/ConsumerControlTest.java Mon Oct 9 15:09:54 2006
@@ -54,5 +54,8 @@
info.setClose(true);
info.setConsumerId(createConsumerId("ConsumerId:1"));
info.setPrefetch(1);
+ info.setFlush(false);
+ info.setStart(true);
+ info.setStop(false);
}
}