Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Test CaseProtocol 0-9/0-10
Content TypeOn screen previewContent Download
small text messagetext/plaincomplete string valueditto preview
large text messagetext/plaintruncated string valuecomplete string value
small map message (default)amqp/mapTable containing name/value pairs
Map entry with bytes array value is base64 encoded 
The map's contents encoded as a AMQP 0-10 map

 

large map message (default)amqp/mapTable containing name/value pairs
Map entry with bytes array value is array of ints
small map message (legacy)jms/map-message
Table containing name/value pairs
Map entry with bytes array value is base64 encoded 

Each written value is encoded by the TypedBytesContentWriter (2)

large map message (legacy)jms/map-message
Table containing name/value pairs
Map entry with bytes array value is array of ints
small stream messageamqp/listTable containing list values

The list's contents encoded as a AMQP 0-10 list

large stream messageamqp/listError popup 'unknown code 67'
No preview displayed.
Broker survives. Stack trace (1)
Table containing list values
small stream message (default - legacy)jms/stream-messageNo preview

Each written value is encoded by the TypedBytesContentWrite

large stream message (default - legacy)jms/stream-messageNo preview
small object messageapplication/java-object-streamNo previewSerialised object bytes
large object messageapplication/java-object-streamNo preview

large pdf file

application/octet-streamNo previewthe pdf file.

...

  1. The way limit applies to Json (truncating, but retaining a syntactically valid response if possible), seems surprising (at least to me). 

Suggested

...

Changes

  1. Server side
    1. Standardise on returning byte arrays as array of integers
    2. For operation getContent if JSON is requested,  it produces it only for Strings, Maps, Collections.  For any other object payload, the operation must fail (say 422)
    3. For AMQP 0-8-0-10
      1. the above changes will mean that jms/stream-message messages will have a preview
    4. For AMQP 1.0
      1. for messages with payloads that are representable as JSON, the above changes will be sufficient give us the preview.
      2. for byte messages, with payloads that hold things like PDFs, there is currently no good place to adapt the content and extract the message payload.  The underlying problem here is the store API.  I suggest we don't fix this at the moment.
  2. UI
    1. UI always requests content JSON content with limit.  If the request fails with 422, add message "preview no available" to the UI.
    2. UI no longer considers mime type

...