Closed
Description
The following code which sets up an IPC publication at a non-zero position returns in v1.21.0. While the publication cannot connect in v1.22.0 and the program never terminates. Has there been a change in channel configuration?
#include <Aeron.h>
int main()
{
aeron::Context ctx;
aeron::Aeron proxy{ctx};
const auto pub_reg_id = proxy.addExclusivePublication(
"aeron:ipc?init-term-id=0|term-length=67108864|term-offset=67098624|term-id=2147483647", 0);
const auto sub_reg_id = proxy.addSubscription("aeron:ipc", 0);
auto pub = proxy.findExclusivePublication(pub_reg_id);
while (!pub)
pub = proxy.findExclusivePublication(pub_reg_id);
auto sub = proxy.findSubscription(sub_reg_id);
while (!sub)
sub = proxy.findSubscription(sub_reg_id);
while (!pub->isConnected())
continue;
std::cerr << "Reached here\n";
return EXIT_FAILURE;
}
Update: Changed to ExclusivePublication
to actually observe the position after offer.
In both v1.21.0 and v1.22.0, non-exclusive publication's initial offer position does not get modified with the channel configuration. If possible, I want to confirm if that is expected behaviour as well.