Class ServiceBusImpl

java.lang.Object
org.kuali.rice.core.api.lifecycle.BaseLifecycle
org.kuali.rice.ksb.impl.bus.ServiceBusImpl
All Implemented Interfaces:
org.kuali.rice.core.api.lifecycle.Lifecycle, org.kuali.rice.ksb.api.bus.ServiceBus, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean

public class ServiceBusImpl extends org.kuali.rice.core.api.lifecycle.BaseLifecycle implements org.kuali.rice.ksb.api.bus.ServiceBus, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean
  • Constructor Details

    • ServiceBusImpl

      public ServiceBusImpl()
  • Method Details

    • afterPropertiesSet

      public void afterPropertiesSet() throws Exception
      Specified by:
      afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
      Throws:
      Exception
    • start

      public void start() throws Exception
      Specified by:
      start in interface org.kuali.rice.core.api.lifecycle.Lifecycle
      Overrides:
      start in class org.kuali.rice.core.api.lifecycle.BaseLifecycle
      Throws:
      Exception
    • isDevMode

      protected boolean isDevMode()
    • startSynchronizationThread

      protected void startSynchronizationThread()
    • destroy

      public void destroy() throws Exception
      Specified by:
      destroy in interface org.springframework.beans.factory.DisposableBean
      Throws:
      Exception
    • stopSynchronizationThread

      protected void stopSynchronizationThread()
    • getInstanceId

      public String getInstanceId()
      Specified by:
      getInstanceId in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • setInstanceId

      public void setInstanceId(String instanceId)
    • getEndpoints

      public List<org.kuali.rice.ksb.api.bus.Endpoint> getEndpoints(QName serviceName)
      Specified by:
      getEndpoints in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getEndpoints

      public List<org.kuali.rice.ksb.api.bus.Endpoint> getEndpoints(QName serviceName, String applicationId)
      Specified by:
      getEndpoints in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getRemoteEndpoints

      public List<org.kuali.rice.ksb.api.bus.Endpoint> getRemoteEndpoints(QName serviceName)
      Specified by:
      getRemoteEndpoints in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getLocalEndpoint

      public org.kuali.rice.ksb.api.bus.Endpoint getLocalEndpoint(QName serviceName)
      Specified by:
      getLocalEndpoint in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getLocalEndpoints

      public Map<QName,org.kuali.rice.ksb.api.bus.Endpoint> getLocalEndpoints()
      Specified by:
      getLocalEndpoints in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getAllEndpoints

      public List<org.kuali.rice.ksb.api.bus.Endpoint> getAllEndpoints()
      Specified by:
      getAllEndpoints in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getEndpoint

      public org.kuali.rice.ksb.api.bus.Endpoint getEndpoint(QName serviceName)
      Specified by:
      getEndpoint in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getEndpoint

      public org.kuali.rice.ksb.api.bus.Endpoint getEndpoint(QName serviceName, String applicationId)
      Specified by:
      getEndpoint in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • filterByApplicationId

      protected Set<RemoteService> filterByApplicationId(String applicationId, Set<RemoteService> remoteServices)
    • getConfiguredEndpoint

      public org.kuali.rice.ksb.api.bus.Endpoint getConfiguredEndpoint(org.kuali.rice.ksb.api.bus.ServiceConfiguration serviceConfiguration)
      Specified by:
      getConfiguredEndpoint in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getService

      public Object getService(QName serviceName)
      Specified by:
      getService in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • getService

      public Object getService(QName serviceName, String applicationId)
      Specified by:
      getService in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • publishService

      public org.kuali.rice.ksb.api.bus.ServiceConfiguration publishService(org.kuali.rice.ksb.api.bus.ServiceDefinition serviceDefinition, boolean synchronize)
      Specified by:
      publishService in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • publishServices

      public List<org.kuali.rice.ksb.api.bus.ServiceConfiguration> publishServices(List<org.kuali.rice.ksb.api.bus.ServiceDefinition> serviceDefinitions, boolean synchronize)
      Specified by:
      publishServices in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • removeService

      public boolean removeService(QName serviceName, boolean synchronize)
      Specified by:
      removeService in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • removeServices

      public List<Boolean> removeServices(List<QName> serviceNames, boolean synchronize)
      Specified by:
      removeServices in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • synchronizeAndProcess

      protected void synchronizeAndProcess(org.kuali.rice.ksb.impl.bus.ServiceBusImpl.SyncProcessor processor)
    • synchronize

      public void synchronize()
      Specified by:
      synchronize in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • synchronizeRemoteServices

      public void synchronizeRemoteServices()
      Specified by:
      synchronizeRemoteServices in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • synchronizeLocalServices

      public void synchronizeLocalServices()
      Specified by:
      synchronizeLocalServices in interface org.kuali.rice.ksb.api.bus.ServiceBus
    • logCompleteServiceDiff

      protected void logCompleteServiceDiff(CompleteServiceDiff serviceDiff)
    • processRemoteServiceDiff

      protected void processRemoteServiceDiff(RemoteServicesDiff remoteServicesDiff)
    • processLocalServiceDiff

      protected void processLocalServiceDiff(LocalServicesDiff localServicesDiff)
    • rebuildServiceEndpointForUpdate

      protected org.kuali.rice.ksb.api.registry.ServiceEndpoint rebuildServiceEndpointForUpdate(org.kuali.rice.ksb.api.registry.ServiceEndpoint originalEndpoint, org.kuali.rice.ksb.api.registry.ServiceInfo registryServiceInfo)
    • rebuildLocalServiceEndpointAfterPublishing

      protected void rebuildLocalServiceEndpointAfterPublishing(org.kuali.rice.ksb.api.registry.ServiceEndpoint publishedService)
    • setServiceRegistry

      public void setServiceRegistry(org.kuali.rice.ksb.api.registry.ServiceRegistry serviceRegistry)
    • setDiffCalculator

      public void setDiffCalculator(ServiceRegistryDiffCalculator diffCalculator)
    • setServiceExportManager

      public void setServiceExportManager(ServiceExportManager serviceExportManager)
    • setScheduledPool

      public void setScheduledPool(KSBScheduledPool scheduledPool)