Merged registry code into master
diff --git a/src/main/java/net/floodlightcontroller/core/internal/Controller.java b/src/main/java/net/floodlightcontroller/core/internal/Controller.java
index cbcd9a0..78b93ed 100644
--- a/src/main/java/net/floodlightcontroller/core/internal/Controller.java
+++ b/src/main/java/net/floodlightcontroller/core/internal/Controller.java
@@ -67,7 +67,6 @@
 import net.floodlightcontroller.core.web.CoreWebRoutable;
 import net.floodlightcontroller.counter.ICounterStoreService;
 import net.floodlightcontroller.flowcache.IFlowService;
-import net.floodlightcontroller.mastership.IMastershipService;
 import net.floodlightcontroller.packet.Ethernet;
 import net.floodlightcontroller.perfmon.IPktInProcessingTimeService;
 import net.floodlightcontroller.restserver.IRestApiService;
@@ -77,6 +76,7 @@
 import net.floodlightcontroller.storage.OperatorPredicate;
 import net.floodlightcontroller.storage.StorageException;
 import net.floodlightcontroller.threadpool.IThreadPoolService;
+import net.onrc.onos.registry.controller.IControllerRegistryService;
 
 import org.jboss.netty.bootstrap.ServerBootstrap;
 import org.jboss.netty.buffer.ChannelBuffer;
@@ -191,9 +191,9 @@
     protected IStorageSourceService storageSource;
     protected IPktInProcessingTimeService pktinProcTime;
     protected IThreadPoolService threadPool;
-    protected IMastershipService masterHelper;
     protected IFlowService flowService;
     protected ITopoRouteService topoRouteService;
+    protected IControllerRegistryService masterHelper;
     
     // Configuration options
     protected int openFlowPort = 6633;
@@ -396,10 +396,6 @@
         this.threadPool = tp;
     }
 
-    public void setMastershipService(IMastershipService serviceImpl) {
-	this.masterHelper = serviceImpl;		
-    }
-
     public void setFlowService(IFlowService serviceImpl) {
 	this.flowService = serviceImpl;		
     }
@@ -407,6 +403,10 @@
     public void setTopoRouteService(ITopoRouteService serviceImpl) {
 	this.topoRouteService = serviceImpl;		
     }
+
+	public void setMastershipService(IControllerRegistryService serviceImpl) {
+		this.masterHelper = serviceImpl;		
+	}
 	
     @Override
     public Role getRole() {