public class MultipleSubscribersWithFragmentAssembly extends Object
Creates two subscriptions on a given channel subscribed to two different stream IDs.
The default STREAM_ID and CHANNEL are configured in SampleConfiguration. The default
channel and stream IDs can be changed by setting Java system properties at the command line, e.g.:
-Daeron.sample.channel=aeron:udp?endpoint=localhost:5555 -Daeron.sample.streamId=20
| Constructor and Description |
|---|
MultipleSubscribersWithFragmentAssembly() |
| Modifier and Type | Method and Description |
|---|---|
static void |
eventAvailableImage(Image image)
Print the information for an available image to stdout.
|
static void |
eventUnavailableImage(Image image)
This handler is called when image is unavailable.
|
static void |
main(String[] args)
Main method for launching the process.
|
static FragmentHandler |
reassembledMessage1(int streamId)
Return a reusable, parameterized
FragmentHandler that prints to stdout for the first stream(STREAM). |
static FragmentHandler |
reassembledMessage2(int streamId)
A reusable, parameterised
FragmentHandler that prints to stdout for the second stream (STREAM + 1). |
public MultipleSubscribersWithFragmentAssembly()
public static void main(String[] args)
args - passed to the process.public static void eventAvailableImage(Image image)
image - that has been created.public static void eventUnavailableImage(Image image)
image - that has gone inactive.public static FragmentHandler reassembledMessage1(int streamId)
FragmentHandler that prints to stdout for the first stream(STREAM).streamId - to show when printing.public static FragmentHandler reassembledMessage2(int streamId)
FragmentHandler that prints to stdout for the second stream (STREAM + 1).streamId - to show when printing.Copyright © 2014-2023 Real Logic Limited. All Rights Reserved.