Skip to content
This repository was archived by the owner on Oct 20, 2022. It is now read-only.

Synchronously decode message from InputStream #10

@gbonnefille

Description

@gbonnefille

When a transport uses an InputStream (ie a Socket) we have to ensure a full decoding is done before trying to read a new/next message. If not, we can fall into a case were message is not yet fully decoded, parts of it are still in the InputStream while the transport check the InputStream for new bytes.

Currently, data availability is done by GENMessageReceiver<InputStream>.readEncodedMessage while decoding is done by GENIncomingMessageDecoder.decodeAndCreateMessage() run by GENIncomingMessageReceiver.run() executed by a dedicated ExecutorService.

What is the design to allow a more synchronous processing?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions