[ts-gen] request log format for shim

Bill Pippin pippin at owlriver.net
Fri Jun 20 19:54:19 EDT 2008


As some of you probably already know from the NEWS file, the shim now
logs requests using nearly the same format as that sent on the wire
upstream.  If you have scripts that can use such data, here are the
details:

    * request log format lines still have a head, the first part of
      which, the pid, datestamp pair, and source code of 2, do not go
      upstream to the IB~tws;

    * the req event index and version, e.g., 1|5 for market data, and 
      currently 3|15 for place order, are next --- though still part
      of the prefix, these numbers also go out on the wire;

    * the body, which varies from one request to the next --- the text
      here is identical to that of the wire format, except that nulls
      are replaced with vertical bars; and

    * the tail, for contract specific data and place order requests,
      a colon-terminated security-type, route, symbol name, and
      possibly also expiry, right, and strike price, tuple --- not
      sent upstream but serving to annotate the request log format, as
      is was already done for some messages, e.g. market data price
      and size.

      Note that the trailing annotation of type-route-name, etc. now
      uses a colon as terminator rather than a period, as was used
      previously; a number of the newly added symbol names include
      periods, so the old format became ambiguous.

The log text head, including index-version pair, is unchanged from
before; the wire format body replaces a previous sketchy summary
format that varied unpredictably from the wire form; and the trailing
annotation, although used before with some requests as part of that
summary, is now, as for messages where it appears, distinct from the
body, or payload, that represents the event as seen at the socket.

Example log format records follow my sig.

Thanks,

Bill

________ log excerpt ___________________________________________________

 8621|69710|  18019167|2| 1| 5|3|AIG|STK||0.00||1|SMART||USD||STK.SMART.AIG.
 8621|69713|  21019240|2| 1| 5|4|YM|FUT|20080918|0.00||1|ECBOT||USD||FUT.ECBOT.YM.20080918.
 8621|69712|  20029824|2| 2| 1|3|STK.SMART.AIG.
 8621|69715|  23031651|2| 2| 1|4|FUT.ECBOT.YM.20080918.
 8621|69705|  13987314|2| 6| 2|1||
 8621|69699|   7987709|2| 8| 1|1|
 8621|69708|  16032082|2| 9| 3|AIG|STK||0.00||1||USD||0|
 8621|69709|  17024023|2| 9| 3|YM|FUT||0.00||1||USD||1|
 8621|69728|  36031861|2|11| 1|6|FUT.ECBOT.YM.20080918.
 8621|69706|  14028176|2|12| 1|1|
 8621|69707|  15031115|2|13| 1|
 8621|69716|  24037614|2|20| 3|5|YM|FUT|20080918|0.00||1|ECBOT||USD|||8|2 w|1|TRADES|1|FUT.ECBOT.YM.20080918.
 8621|69726|  34028995|2|10| 3|6|YM|FUT|20080918|0.00||1|ECBOT|USD||5|FUT.ECBOT.YM.20080918.

 8913|69921|  11991782|2| 3|15|118|AIG|STK||0.00||1|SMART||USD||BUY|2|LMT|35.00|0.0|GTC||||0||0||0|0|0|2|0|0|||||||||STK.SMART.AIG.
 8913|69927|  17992353|2| 3|15|118|AIG|STK||0.00||1|SMART||USD||BUY|3|MKT|0.0|0.0|GTC||||0||0||0|0|0|2|0|0|||||||||STK.SMART.AIG.
 8913|69929|  19493904|2| 3|15|118|AIG|STK||0.00||1|SMART||USD||BUY|3|MKT|0.0|0.0|GTC||||0||1||0|0|0|2|0|0|||||||||STK.SMART.AIG.
 8913|69931|  21493791|2| 3|15|119|AIG|STK||0.00||1|SMART||USD||SELL|2|LMT|45.00|0.0|GTC||||0||0||0|0|0|2|0|0|||||||||STK.SMART.AIG.
 8913|69933|  23992370|2| 3|15|119|AIG|STK||0.00||1|SMART||USD||SELL|3|MKT|0.0|0.0|GTC||||0||0||0|0|0|2|0|0|||||||||STK.SMART.AIG.
 8913|69935|  25512596|2| 3|15|119|AIG|STK||0.00||1|SMART||USD||SELL|3|MKT|0.0|0.0|GTC||||0||1||0|0|0|2|0|0|||||||||STK.SMART.AIG.



More information about the ts-general mailing list