autohit.server.service
Class HttpCommandService

java.lang.Object
  extended byautohit.vm.VM
      extended byautohit.server.service.Service
          extended byautohit.server.service.HttpCommandService

public class HttpCommandService
extends Service

This is a socket relay service. It's a dumb relay for sockets. Don't ask why I did this. It will accept connections on port AutohitProperties.value_SOCKETRELAY_SERVER_PORT. It'll relay them to the current property settings for AutohitProperties.SERVICE_SOCKETRELAY_DESTINATION_ADDR and AutohitProperties.SERVICE_SOCKETRELAY_DESTINATION_PORT for address and port, respectively. If either is not set, a default will be used, though there is little utility in the default.

The relay will stay active until either side drops the connection. There is absolutely no filtering or logging.

Version:
1.0 Version HistoryEPG - Initial - 12SEP03
Author:
Erich P. Gatejen

Field Summary
static java.lang.String INJECTOR_NAME
           
 
Fields inherited from class autohit.server.service.Service
sc
 
Fields inherited from class autohit.vm.VM
buf, core, errors, faults, ip, left, loader, myLog, process, right, rinjector, rootProgram, sname, state, STATE_ACTIVE_THRESHOLD, STATE_BUILDING, STATE_DONE, STATE_INVALID, STATE_NEW, STATE_NO_VM, STATE_PAUSED, STATE_RUNNING, TIME_GRAN
 
Constructor Summary
HttpCommandService()
          Default constructor
 
Method Summary
 void construct()
          Complete construction.
 void destruct()
          Complete destroy.
 void execute()
          Fast loop.
 
Methods inherited from class autohit.server.service.Service
loadcontext
 
Methods inherited from class autohit.vm.VM
attach, die, finalize, getState, init, pause, prepare, resume, setParentCore, start, ticks
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INJECTOR_NAME

public static final java.lang.String INJECTOR_NAME
See Also:
Constant Field Values
Constructor Detail

HttpCommandService

public HttpCommandService()
Default constructor

Method Detail

construct

public void construct()
               throws ServiceException
Complete construction. This will be called when the VM is initialized.

Specified by:
construct in class VM
Throws:
ServiceException

execute

public void execute()
             throws ServiceException
Fast loop. We spend most of our time waiting for connections. Cycle back to VM only after an accept or a timeout.

Specified by:
execute in class VM
Throws:
ServiceException
See Also:
VMException

destruct

public void destruct()
              throws ServiceException
Complete destroy. This will be called when the VM is finalizing.

Specified by:
destruct in class VM
Throws:
ServiceException


Test.