diff options
| author | Keith Wall <kwall@apache.org> | 2014-01-14 16:58:22 +0000 |
|---|---|---|
| committer | Keith Wall <kwall@apache.org> | 2014-01-14 16:58:22 +0000 |
| commit | cdff7cc90253430c2d8ccce1a6cf6d6822fc2cc1 (patch) | |
| tree | fdf77f8829d2fae40e77ef97cc65c87b11cffb53 | |
| parent | 840bf7469dc7b18d74eaa275bb23ed09dd0e168b (diff) | |
| download | qpid-python-cdff7cc90253430c2d8ccce1a6cf6d6822fc2cc1.tar.gz | |
QPID-5412: (Simply) stop UnsupportedOperationException (Attribute is not supported) when viewing a group with a remote nodes
git-svn-id: https://svn.apache.org/repos/asf/qpid/branches/java-broker-bdb-ha@1558109 13f79535-47bb-0310-9956-ffa450edef68
| -rw-r--r-- | qpid/java/bdbstore/src/main/java/org/apache/qpid/server/store/berkeleydb/replication/AbstractReplicationNode.java | 79 |
1 files changed, 77 insertions, 2 deletions
diff --git a/qpid/java/bdbstore/src/main/java/org/apache/qpid/server/store/berkeleydb/replication/AbstractReplicationNode.java b/qpid/java/bdbstore/src/main/java/org/apache/qpid/server/store/berkeleydb/replication/AbstractReplicationNode.java index fee57482e0..1e7099558f 100644 --- a/qpid/java/bdbstore/src/main/java/org/apache/qpid/server/store/berkeleydb/replication/AbstractReplicationNode.java +++ b/qpid/java/bdbstore/src/main/java/org/apache/qpid/server/store/berkeleydb/replication/AbstractReplicationNode.java @@ -34,6 +34,9 @@ import org.apache.qpid.server.model.State; import org.apache.qpid.server.model.Statistics; import org.apache.qpid.server.model.UUIDGenerator; import org.apache.qpid.server.model.VirtualHost; +import org.apache.qpid.server.model.adapter.NoStatistics; + +import com.sleepycat.je.Durability; public abstract class AbstractReplicationNode implements ReplicationNode { @@ -177,6 +180,18 @@ public abstract class AbstractReplicationNode implements ReplicationNode { return getLifetimePolicy(); } + else if (ReplicationNode.TIME_TO_LIVE.equals(name)) + { + return 0L; + } + else if (ReplicationNode.CREATED.equals(name)) + { + return 0L; + } + else if (ReplicationNode.UPDATED.equals(name)) + { + return 0L; + } else if (ReplicationNode.DURABLE.equals(name)) { return isDurable(); @@ -189,7 +204,67 @@ public abstract class AbstractReplicationNode implements ReplicationNode { return _groupName; } - throw new UnsupportedOperationException(); + else if (ReplicationNode.TYPE.equals(name)) + { + // TODO + return null; + } + else if (ReplicationNode.STATE.equals(name)) + { + // TODO + return State.UNAVAILABLE; + } + else if (ReplicationNode.ROLE.equals(name)) + { + // TODO + return null; + } + else if (ReplicationNode.LAST_KNOWN_REPLICATION_TRANSACTION_ID.equals(name)) + { + // TODO + return null; + } + else if (ReplicationNode.HELPER_HOST_PORT.equals(name)) + { + return null; + } + else if (ReplicationNode.DURABILITY.equals(name)) + { + return null; + } + else if (ReplicationNode.COALESCING_SYNC.equals(name)) + { + return null; + } + else if (ReplicationNode.DESIGNATED_PRIMARY.equals(name)) + { + return null; + } + else if (ReplicationNode.PRIORITY.equals(name)) + { + return null; + } + else if (ReplicationNode.QUORUM_OVERRIDE.equals(name)) + { + return null; + } + else if (ReplicationNode.JOIN_TIME.equals(name)) + { + return 0l; + } + else if (ReplicationNode.PARAMETERS.equals(name)) + { + return null; + } + else if (ReplicationNode.REPLICATION_PARAMETERS.equals(name)) + { + return null; + } + else if (ReplicationNode.STORE_PATH.equals(name)) + { + return null; + } + throw new UnsupportedOperationException("Attribute " + name + " is not supported"); } @Override @@ -209,7 +284,7 @@ public abstract class AbstractReplicationNode implements ReplicationNode @Override public Statistics getStatistics() { - throw new UnsupportedOperationException(); + return NoStatistics.getInstance(); } @Override |
