Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bogus OA setup in DataStorm #3337

Closed
pepone opened this issue Jan 10, 2025 · 2 comments
Closed

Bogus OA setup in DataStorm #3337

pepone opened this issue Jan 10, 2025 · 2 comments
Assignees
Milestone

Comments

@pepone
Copy link
Member

pepone commented Jan 10, 2025

I think there is a chance here to receive a request before the connected callback is called and setups the OA.

lookup->createSessionAsync(
proxy,
[self = shared_from_this(), lookup](optional<NodePrx> node)
{
// createSession must return a non null proxy.
assert(node);
if (node)
{
self->connected(*node, lookup);
}
else
{
self->disconnected(lookup);
}
},

In Node implementation we use a different pattern with first calling getConnectionAsync and setup the OA before sending the request.

s->ice_getConnectionAsync(
[=, self = shared_from_this()](const auto& connection) mutable
{
if (session->checkSession())
{
return;
}
if (connection)
{
if (!connection->getAdapter())
{
connection->setAdapter(instance->getObjectAdapter());
}
subscriberSession = subscriberSession->ice_fixed(connection);
}
try
{
// Must be called before connected
s->confirmCreateSessionAsync(

Maybe we can simplify this by using the new setDefaultObjectAdapter.

@pepone pepone added this to the 3.8.0 milestone Jan 10, 2025
@pepone
Copy link
Member Author

pepone commented Jan 11, 2025

Maybe we can simplify this by using the new setDefaultObjectAdapter.

I think we cannot because DataStorm doesn't always owns the communicator, and this could interfere with applications that pass they own communicator to DataStorm and also want to setup its own default OA.

@pepone
Copy link
Member Author

pepone commented Jan 15, 2025

Fixed in #3355

@pepone pepone closed this as completed Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant