Class DefaultRemoteDrain

java.lang.Object
de.hybris.platform.mediaconversion.os.process.impl.DefaultRemoteDrain
All Implemented Interfaces:
RemoteDrain, Remote

public class DefaultRemoteDrain extends Object implements RemoteDrain
Default implementation of the RemoteDrain. This spring bean registers itself to the RMI Registry to accept all incoming 'drain requests'. It then adapts and delegates the callback to the underlying ProcessContextRegistry and the ProcessContext associated with the given pid.
  • Constructor Details

    • DefaultRemoteDrain

      public DefaultRemoteDrain()
  • Method Details

    • drain

      public void drain(int pid, DrainType type, String message) throws RemoteException
      Adapts and delegates the given message to a registered ProcessContext identified by the given pid.

      Callback method to handle a line of std err/out output of an process.

      Specified by:
      drain in interface RemoteDrain
      Parameters:
      pid - the unique id of a process.
      type - the type of output we are talking about.
      message - the actual payload: one line of output.
      Throws:
      RemoteException - on any technical communication error.
      See Also:
    • init

      public void init()
      Registers this service to the wired rmi Registry.
    • destroy

      public void destroy()
      Unregisters this service from the rmi registry.
    • getRmiRegistryService

      public RMIRegistryService getRmiRegistryService()
    • setRmiRegistryService

      public void setRmiRegistryService(RMIRegistryService rmiRegistryService)
    • getProcessContextRegistry

      public ProcessContextRegistry getProcessContextRegistry()
    • setProcessContextRegistry

      public void setProcessContextRegistry(ProcessContextRegistry processContextRegistry)