Bump odlparent to 5.0.0
[openflowplugin.git] / openflowplugin-impl / src / main / java / org / opendaylight / openflowplugin / impl / services / RoleService.java
index 0bee9905e51e0eca5fe66938ae96cfb141c8f04a..ff642d73668bce060a3476cca708e96477e3c24a 100644 (file)
@@ -16,12 +16,10 @@ import java.math.BigInteger;
 import java.util.Collection;
 import java.util.concurrent.ExecutionException;
 import java.util.concurrent.Future;
-import javax.annotation.Nonnull;
 import org.opendaylight.openflowplugin.api.openflow.device.DeviceContext;
 import org.opendaylight.openflowplugin.api.openflow.device.RequestContextStack;
 import org.opendaylight.openflowplugin.api.openflow.device.Xid;
 import org.opendaylight.openflowplugin.impl.role.RoleChangeException;
-import org.opendaylight.openflowplugin.impl.services.util.ServiceException;
 import org.opendaylight.openflowplugin.impl.util.ErrorUtil;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.transaction.rev150304.TransactionId;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.ControllerRole;
@@ -50,7 +48,7 @@ public class RoleService extends AbstractSimpleService<RoleRequestInputBuilder,
     }
 
     @Override
-    protected OfHeader buildRequest(final Xid xid, final RoleRequestInputBuilder input) throws ServiceException {
+    protected OfHeader buildRequest(final Xid xid, final RoleRequestInputBuilder input) {
         input.setXid(xid.getValue());
         return input.build();
     }
@@ -69,7 +67,7 @@ public class RoleService extends AbstractSimpleService<RoleRequestInputBuilder,
                 handleServiceCall(roleRequestInputBuilder);
         Futures.addCallback(genIdListenableFuture, new FutureCallback<RpcResult<RoleRequestOutput>>() {
             @Override
-            public void onSuccess(@Nonnull final RpcResult<RoleRequestOutput> roleRequestOutputRpcResult) {
+            public void onSuccess(final RpcResult<RoleRequestOutput> roleRequestOutputRpcResult) {
                 if (roleRequestOutputRpcResult.isSuccessful()) {
                     final RoleRequestOutput roleRequestOutput = roleRequestOutputRpcResult.getResult();
                     if (roleRequestOutput != null) {
@@ -91,7 +89,7 @@ public class RoleService extends AbstractSimpleService<RoleRequestInputBuilder,
 
             @Override
             public void onFailure(final Throwable throwable) {
-                LOG.info("onFailure - getGenerationIdFromDevice RPC error {}", throwable);
+                LOG.info("onFailure - getGenerationIdFromDevice RPC error", throwable);
                 finalFuture.setException(new ExecutionException(throwable));
             }
         }, MoreExecutors.directExecutor());
@@ -115,7 +113,7 @@ public class RoleService extends AbstractSimpleService<RoleRequestInputBuilder,
         final SettableFuture<RpcResult<SetRoleOutput>> finalFuture = SettableFuture.create();
         Futures.addCallback(roleListenableFuture, new FutureCallback<RpcResult<RoleRequestOutput>>() {
             @Override
-            public void onSuccess(@Nonnull final RpcResult<RoleRequestOutput> roleRequestOutputRpcResult) {
+            public void onSuccess(final RpcResult<RoleRequestOutput> roleRequestOutputRpcResult) {
                 LOG.info("submitRoleChange onSuccess for device:{}, role:{}",
                         getDeviceInfo().getNodeId(), ofpRole);
                 final RoleRequestOutput roleRequestOutput = roleRequestOutputRpcResult.getResult();