Class AgentConnector

All Implemented Interfaces:
Iterable<ComponentType>, Channel, ComponentType, Eligible, Manager
Direct Known Subclasses:
GuestAgentClient, VmopAgentClient

public abstract class AgentConnector extends QemuConnector
A component that handles the communication with an agent running in the VM.

If the log level for this class is set to fine, the messages exchanged on the socket are logged.

  • Field Details

  • Constructor Details

    • AgentConnector

      public AgentConnector(Channel componentChannel) throws IOException
      Instantiates a new agent connector.
      Parameters:
      componentChannel - the component channel
      Throws:
      IOException - Signals that an I/O exception has occurred.
  • Method Details

    • configure

      void configure(String channelId, Path socketPath)
      As the initial configuration of this component depends on the configuration of the Runner, it doesn’t have a handler for the ConfigurationUpdate event.

      The values are forwarded from the Runner instead.

      Parameters:
      channelId - the channel id
      socketPath - the socket path
    • onVserportChanged

      When the virtual serial port with the configured channel id has been opened call agentConnected().
      Parameters:
      event - the event
    • agentConnected

      protected void agentConnected()
      Called when the agent in the VM opens the connection.

      The default implementation does nothing.