Commit 6def0fce authored by Tom Evans's avatar Tom Evans Committed by tevans

[Nightly Build] Remove JDK 1.6 annotations

git-svn-id: http://svn.igniterealtime.org/svn/repos/openfire/trunk@13302 b35dd754-fafc-0310-a699-88a17e54d16e
parent d361954f
...@@ -503,29 +503,24 @@ public class PubSubModule extends BasicModule implements ServerItemsProvider, Di ...@@ -503,29 +503,24 @@ public class PubSubModule extends BasicModule implements ServerItemsProvider, Di
return serviceEnabled; return serviceEnabled;
} }
@Override
public void joinedCluster() { public void joinedCluster() {
// Disable the service until we know that we are the senior cluster member // Disable the service until we know that we are the senior cluster member
// enableService(false); // enableService(false);
} }
@Override
public void joinedCluster(byte[] nodeID) { public void joinedCluster(byte[] nodeID) {
// Do nothing // Do nothing
} }
@Override
public void leftCluster() { public void leftCluster() {
// Offer the service when not running in a cluster // Offer the service when not running in a cluster
// enableService(true); // enableService(true);
} }
@Override
public void leftCluster(byte[] nodeID) { public void leftCluster(byte[] nodeID) {
// Do nothing // Do nothing
} }
@Override
public void markedAsSeniorClusterMember() { public void markedAsSeniorClusterMember() {
// Offer the service since we are the senior cluster member // Offer the service since we are the senior cluster member
// enableService(true); // enableService(true);
......
...@@ -18,7 +18,6 @@ public class CancelSubscriptionTask extends SubscriptionTask ...@@ -18,7 +18,6 @@ public class CancelSubscriptionTask extends SubscriptionTask
super(subscription); super(subscription);
} }
@Override
public void run() public void run()
{ {
log.debug("[TASK] Cancel Subscription : {}", toString()); log.debug("[TASK] Cancel Subscription : {}", toString());
......
...@@ -14,24 +14,20 @@ public class FlushTask implements ClusterTask ...@@ -14,24 +14,20 @@ public class FlushTask implements ClusterTask
{ {
} }
@Override
public void run() public void run()
{ {
PubSubPersistenceManager.flushPendingItems(false); // just this member PubSubPersistenceManager.flushPendingItems(false); // just this member
} }
@Override
public Object getResult() public Object getResult()
{ {
return null; return null;
} }
@Override
public void writeExternal(ObjectOutput out) throws IOException public void writeExternal(ObjectOutput out) throws IOException
{ {
} }
@Override
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{ {
} }
......
...@@ -19,7 +19,6 @@ public class ModifySubscriptionTask extends SubscriptionTask ...@@ -19,7 +19,6 @@ public class ModifySubscriptionTask extends SubscriptionTask
super(subscription); super(subscription);
} }
@Override
public void run() public void run()
{ {
log.debug("[TASK] Modify subscription : {}", toString()); log.debug("[TASK] Modify subscription : {}", toString());
......
...@@ -21,7 +21,6 @@ public class NewSubscriptionTask extends SubscriptionTask ...@@ -21,7 +21,6 @@ public class NewSubscriptionTask extends SubscriptionTask
super(subscription); super(subscription);
} }
@Override
public void run() public void run()
{ {
log.debug("[TASK] New subscription : {}", toString()); log.debug("[TASK] New subscription : {}", toString());
......
...@@ -37,13 +37,11 @@ public abstract class NodeChangeTask implements ClusterTask ...@@ -37,13 +37,11 @@ public abstract class NodeChangeTask implements ClusterTask
nodeId = node.getNodeID(); nodeId = node.getNodeID();
} }
@Override
public void writeExternal(ObjectOutput out) throws IOException public void writeExternal(ObjectOutput out) throws IOException
{ {
ExternalizableUtil.getInstance().writeSafeUTF(out, nodeId); ExternalizableUtil.getInstance().writeSafeUTF(out, nodeId);
} }
@Override
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{ {
nodeId = ExternalizableUtil.getInstance().readSafeUTF(in); nodeId = ExternalizableUtil.getInstance().readSafeUTF(in);
......
...@@ -52,20 +52,17 @@ public abstract class NodeTask implements ClusterTask ...@@ -52,20 +52,17 @@ public abstract class NodeTask implements ClusterTask
} }
} }
@Override
public Object getResult() public Object getResult()
{ {
return null; return null;
} }
@Override
public void writeExternal(ObjectOutput out) throws IOException public void writeExternal(ObjectOutput out) throws IOException
{ {
ExternalizableUtil.getInstance().writeSafeUTF(out, nodeId); ExternalizableUtil.getInstance().writeSafeUTF(out, nodeId);
ExternalizableUtil.getInstance().writeSafeUTF(out, serviceId); ExternalizableUtil.getInstance().writeSafeUTF(out, serviceId);
} }
@Override
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{ {
nodeId = ExternalizableUtil.getInstance().readSafeUTF(in); nodeId = ExternalizableUtil.getInstance().readSafeUTF(in);
......
...@@ -26,7 +26,6 @@ public class RefreshNodeTask extends NodeTask ...@@ -26,7 +26,6 @@ public class RefreshNodeTask extends NodeTask
super(node); super(node);
} }
@Override
public void run() public void run()
{ {
log.debug("[TASK] Refreshing node - nodeID: {}", getNodeId()); log.debug("[TASK] Refreshing node - nodeID: {}", getNodeId());
......
...@@ -23,7 +23,6 @@ public class RemoveNodeTask extends NodeTask ...@@ -23,7 +23,6 @@ public class RemoveNodeTask extends NodeTask
super(node); super(node);
} }
@Override
public void run() public void run()
{ {
log.debug("[TASK] Removing node - nodeID: {}", getNodeId()); log.debug("[TASK] Removing node - nodeID: {}", getNodeId());
......
...@@ -105,7 +105,6 @@ public class DefaultLocalCacheStrategy implements CacheFactoryStrategy { ...@@ -105,7 +105,6 @@ public class DefaultLocalCacheStrategy implements CacheFactoryStrategy {
public void updateCacheStats(Map<String, Cache> caches) { public void updateCacheStats(Map<String, Cache> caches) {
} }
@Override
public String getPluginName() { public String getPluginName() {
return "local"; return "local";
} }
......
...@@ -46,22 +46,18 @@ class CacheListener implements EntryListener { ...@@ -46,22 +46,18 @@ class CacheListener implements EntryListener {
this.cacheName = cacheName; this.cacheName = cacheName;
} }
@Override
public void entryAdded(EntryEvent event) { public void entryAdded(EntryEvent event) {
handleMapEvent(event, false); handleMapEvent(event, false);
} }
@Override
public void entryUpdated(EntryEvent event) { public void entryUpdated(EntryEvent event) {
handleMapEvent(event, false); handleMapEvent(event, false);
} }
@Override
public void entryRemoved(EntryEvent event) { public void entryRemoved(EntryEvent event) {
handleMapEvent(event, true); handleMapEvent(event, true);
} }
@Override
public void entryEvicted(EntryEvent event) { public void entryEvicted(EntryEvent event) {
handleMapEvent(event, true); handleMapEvent(event, true);
} }
......
...@@ -412,7 +412,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -412,7 +412,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
*/ */
private class DirectedPresenceListener implements EntryListener { private class DirectedPresenceListener implements EntryListener {
@Override
public void entryAdded(EntryEvent event) { public void entryAdded(EntryEvent event) {
byte[] nodeID = event.getMember().getUuid().getBytes(); byte[] nodeID = event.getMember().getUuid().getBytes();
// Ignore events origintated from this JVM // Ignore events origintated from this JVM
...@@ -438,7 +437,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -438,7 +437,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
} }
} }
@Override
public void entryUpdated(EntryEvent event) { public void entryUpdated(EntryEvent event) {
byte[] nodeID = event.getMember().getUuid().getBytes(); byte[] nodeID = event.getMember().getUuid().getBytes();
// Ignore events originated from this JVM // Ignore events originated from this JVM
...@@ -468,7 +466,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -468,7 +466,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
} }
} }
@Override
public void entryRemoved(EntryEvent event) { public void entryRemoved(EntryEvent event) {
if (event.getValue() == null && ((Collection)event.getOldValue()).isEmpty()) { if (event.getValue() == null && ((Collection)event.getOldValue()).isEmpty()) {
// Nothing to remove // Nothing to remove
...@@ -500,7 +497,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -500,7 +497,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
return Collections.emptySet(); return Collections.emptySet();
} }
@Override
public void entryEvicted(EntryEvent event) { public void entryEvicted(EntryEvent event) {
entryRemoved(event); entryRemoved(event);
} }
...@@ -511,7 +507,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -511,7 +507,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
*/ */
private class ComponentCacheListener implements EntryListener { private class ComponentCacheListener implements EntryListener {
@Override
public void entryAdded(EntryEvent event) { public void entryAdded(EntryEvent event) {
Object newValue = event.getValue(); Object newValue = event.getValue();
if (newValue != null) { if (newValue != null) {
...@@ -525,7 +520,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -525,7 +520,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
} }
} }
@Override
public void entryUpdated(EntryEvent event) { public void entryUpdated(EntryEvent event) {
// Remove any trace to the component that was added/deleted to some node // Remove any trace to the component that was added/deleted to some node
String domain = event.getKey().toString(); String domain = event.getKey().toString();
...@@ -538,7 +532,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -538,7 +532,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
entryAdded(event); entryAdded(event);
} }
@Override
public void entryRemoved(EntryEvent event) { public void entryRemoved(EntryEvent event) {
Object newValue = event.getValue(); Object newValue = event.getValue();
if (newValue != null) { if (newValue != null) {
...@@ -552,7 +545,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -552,7 +545,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
} }
} }
@Override
public void entryEvicted(EntryEvent event) { public void entryEvicted(EntryEvent event) {
entryRemoved(event); entryRemoved(event);
} }
...@@ -615,7 +607,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -615,7 +607,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
done = true; done = true;
} }
@Override
public void memberAdded(MembershipEvent event) { public void memberAdded(MembershipEvent event) {
// local member only // local member only
if (event.getMember().localMember()) { // We left and re-joined the cluster if (event.getMember().localMember()) { // We left and re-joined the cluster
...@@ -630,7 +621,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -630,7 +621,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
new HazelcastClusterNodeInfo(event.getMember(), cluster.getClusterTime())); new HazelcastClusterNodeInfo(event.getMember(), cluster.getClusterTime()));
} }
@Override
public void memberRemoved(MembershipEvent event) { public void memberRemoved(MembershipEvent event) {
byte[] nodeID = event.getMember().getUuid().getBytes(); byte[] nodeID = event.getMember().getUuid().getBytes();
...@@ -667,7 +657,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener { ...@@ -667,7 +657,6 @@ public class ClusterListener implements MembershipListener, LifecycleListener {
return new ArrayList<ClusterNodeInfo>(clusterNodesInfo.values()); return new ArrayList<ClusterNodeInfo>(clusterNodesInfo.values());
} }
@Override
public void stateChanged(LifecycleEvent event) { public void stateChanged(LifecycleEvent event) {
if (event.getState().equals(LifecycleState.SHUTDOWN)) { if (event.getState().equals(LifecycleState.SHUTDOWN)) {
leaveCluster(); leaveCluster();
......
...@@ -219,7 +219,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy { ...@@ -219,7 +219,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy {
* Note that this method does not provide the result set for the given * Note that this method does not provide the result set for the given
* task, as the task is run asynchronously across the cluster. * task, as the task is run asynchronously across the cluster.
*/ */
@Override
public void doClusterTask(final ClusterTask task) { public void doClusterTask(final ClusterTask task) {
Set<Member> members = new TreeSet<Member>(); Set<Member> members = new TreeSet<Member>();
Member current = cluster.getLocalMember(); Member current = cluster.getLocalMember();
...@@ -243,7 +242,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy { ...@@ -243,7 +242,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy {
* Note that this method does not provide the result set for the given * Note that this method does not provide the result set for the given
* task, as the task is run asynchronously across the cluster. * task, as the task is run asynchronously across the cluster.
*/ */
@Override
public boolean doClusterTask(final ClusterTask task, byte[] nodeID) { public boolean doClusterTask(final ClusterTask task, byte[] nodeID) {
Member target = null; Member target = null;
for(Member member: cluster.getMembers()) { for(Member member: cluster.getMembers()) {
...@@ -268,7 +266,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy { ...@@ -268,7 +266,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy {
* Note that this method blocks for up to MAX_CLUSTER_EXECUTION_TIME * Note that this method blocks for up to MAX_CLUSTER_EXECUTION_TIME
* (seconds) until the task is run on all members. * (seconds) until the task is run on all members.
*/ */
@Override
public Collection<Object> doSynchronousClusterTask(ClusterTask task, boolean includeLocalMember) { public Collection<Object> doSynchronousClusterTask(ClusterTask task, boolean includeLocalMember) {
Set<Member> members = new HashSet<Member>(); Set<Member> members = new HashSet<Member>();
Member current = cluster.getLocalMember(); Member current = cluster.getLocalMember();
...@@ -303,7 +300,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy { ...@@ -303,7 +300,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy {
* Note that this method blocks for up to MAX_CLUSTER_EXECUTION_TIME * Note that this method blocks for up to MAX_CLUSTER_EXECUTION_TIME
* (seconds) until the task is run on the given member. * (seconds) until the task is run on the given member.
*/ */
@Override
public Object doSynchronousClusterTask(ClusterTask task, byte[] nodeID) { public Object doSynchronousClusterTask(ClusterTask task, byte[] nodeID) {
Member target = null; Member target = null;
for(Member member: cluster.getMembers()) { for(Member member: cluster.getMembers()) {
...@@ -360,7 +356,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy { ...@@ -360,7 +356,6 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy {
} }
} }
@Override
public String getPluginName() { public String getPluginName() {
return "hazelcast"; return "hazelcast";
} }
...@@ -413,8 +408,7 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy { ...@@ -413,8 +408,7 @@ public class ClusteredCacheFactory implements CacheFactoryStrategy {
public CallableTask(ClusterTask task) { public CallableTask(ClusterTask task) {
this.task = task; this.task = task;
} }
@Override
public Object call() { public Object call() {
task.run(); task.run();
logger.debug("CallableTask[" + task.getClass().getName() + "] result: " + task.getResult()); logger.debug("CallableTask[" + task.getClass().getName() + "] result: " + task.getResult());
......
...@@ -75,7 +75,7 @@ public class NodeRuntimeStats { ...@@ -75,7 +75,7 @@ public class NodeRuntimeStats {
*/ */
public static class NodeInfoTask implements ClusterTask { public static class NodeInfoTask implements ClusterTask {
private Object result = null; private Object result = null;
@Override
public void run() { public void run() {
// Get runtime stats - mem and time: // Get runtime stats - mem and time:
Runtime runtime = Runtime.getRuntime(); Runtime runtime = Runtime.getRuntime();
...@@ -87,17 +87,14 @@ public class NodeRuntimeStats { ...@@ -87,17 +87,14 @@ public class NodeRuntimeStats {
result = new NodeInfo(CacheFactory.getClusterMemberID(), free, total, max, time); result = new NodeInfo(CacheFactory.getClusterMemberID(), free, total, max, time);
} }
@Override
public void writeExternal(ObjectOutput out) throws IOException { public void writeExternal(ObjectOutput out) throws IOException {
ExternalizableUtil.getInstance().writeSerializable(out, (NodeInfo) result); ExternalizableUtil.getInstance().writeSerializable(out, (NodeInfo) result);
} }
@Override
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException { public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
result = ExternalizableUtil.getInstance().readSerializable(in); result = ExternalizableUtil.getInstance().readSerializable(in);
} }
@Override
public Object getResult() { return result; } public Object getResult() { return result; }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment