A description of the Fit Server component that is required for each FIT.

This is the protocol of communication between FIT and FitNesse.

Invocation:
Fit Server is invoked by a simple console command.
java fit.FitServer

Command Line Arguments:
Java usage: java fit.FitServer [-v] host port socketTicket

Execution:

Included page: FitProtocol (edit)

  • INTEGER : A integer value in the form of a 10 byte string
    • 0000000000 = 0
    • 0000000005 = 5
    • 0000000123 = 123
  • READ : Reading a value involves two step.
    1. read an INTEGER value, n
    2. read n bytes.
  • WRITE : Writing a value involves two steps
    1. count the bytes in value and write the size as an INTEGER
    2. write the value as bytes
  • WRITE COUNTS : Write the counts as 4 INTEGERs
    1. right
    2. wrong
    3. ignores
    4. exceptions
  • STATUS : Length of Error Message. If it is zero, the connection has been established. If not, it is followed by the Error Message.


Errors and Exceptions:
- Connection Error: If the STATUS recieved at connection is not zero, then somehitng has gone wrong. The value of STATUS is the length of the error message the FitNesse will send. Before exiting Fit Server should read the error message and print it to standard error.
- Transaction Error: If an exception is thrown during the processing of transactions then the exception should be wrapped in an HTML table and written back over the socket as though it were the test results. An exception thrown at any other point is considered fatal and may invoke abnormal termination.