Class TdbGridHost

All Implemented Interfaces:
com.tietoenator.trip.jxp.internal.utils.DOMSink, Iterable<TdbGridHostPublication>

public class TdbGridHost extends TdbMessageProvider implements com.tietoenator.trip.jxp.internal.utils.DOMSink, Iterable<TdbGridHostPublication>
Container and manipulation logic for a host on the grid
  • Constructor Details

    • TdbGridHost

      public TdbGridHost(TdbSession session, String name) throws TdbException
      Constructor, creates an instance for the named host
      Parameters:
      session - Active session
      name - Name or IP address of the cluster host
      Throws:
      TdbException
    • TdbGridHost

      public TdbGridHost(TdbSession session) throws TdbException
      Constructor, creates a blank instance
      Parameters:
      session - Active session
      Throws:
      TdbException
  • Method Details

    • getName

      public String getName()
      Retrieve the name of the host
      Returns:
      Host name
    • setName

      public void setName(String name)
      Establish the name of the host
      Parameters:
      name - Host name
    • getIniFile

      public String getIniFile()
      Retrieve any host initialization file established for connections to this host
      Returns:
      Host initialization file, if any
    • setIniFile

      public void setIniFile(String inifile)
      Establish a host initialization file for connections to this host
      Parameters:
      inifile - Host initialization file
    • getPort

      public int getPort()
      Retrieve the port number the grid will use to connect to this host. All connections from the grid to host servers use the TRIPnet protocol.
      Returns:
      Port number
    • setPort

      public void setPort(int port)
      Establish the port number the grid will use to connect to this host. All connections from the grid to host servers use the TRIPnet protocol.
      Parameters:
      port - Port number
    • getTimeout

      public int getTimeout()
      Retrieve the connection timeout established for connections to this host.
      Returns:
      Connection timeout, in milliseconds.
    • setTimeout

      public void setTimeout(int timeout)
      Establist the connection timeout for connections to this host via TRIPnet.
      Parameters:
      timeout - Connection timeout, in milliseconds
    • iterator

      public Iterator<TdbGridHostPublication> iterator()
      Retrieve an iterator over the publications offered by this host.
      Specified by:
      iterator in interface Iterable<TdbGridHostPublication>
      Returns:
      Publication iterator
    • publications

      public List<TdbGridHostPublication> publications()
      Retrieve a collection of publications offered by this host.
      Returns:
      Publication collection
    • add

      public void add(TdbGridHostPublication publication)
      Add a new publication to this host's offerings
      Parameters:
      publication - New publication to add
    • get

      public void get() throws TdbException
      Retrieve the properties of the grid host.

      This method causes network I/O.

      Throws:
      TdbException
    • put

      public void put() throws TdbException
      Store a new/modified host definition.

      This method causes network I/O.

      Throws:
      TdbException
    • remove

      public void remove() throws TdbException
      Remove the host from the grid.

      This method causes network I/O.

      Throws:
      TdbException