Environment details
- Programming language: Java
- OS: Linux/Windows
- Language runtime version: 11
- Package version: 1.46.0
Steps to reproduce
- Create a live API Session
- Start the conversation
- During the conversation, the connection unexpectedly disconnected
- The console printed an exception for the disconnection, but was unable to receive a message similar to GoAway
In the following class:com.google.genai.AsyncLive.GenAiWebSocketClient
@Override
public void onClose(int code, String reason, boolean remote) {
logger.log(
Level.INFO,
"Live session closed with code: {0} and reason: {1}",
new Object[]{code, reason});
if (!sessionFuture.isDone()) {
sessionFuture.completeExceptionally(
new GenAiIOException("WebSocket closed unexpectedly: " + reason));
}
}
This sessionFuture is already in the "Done" state after the connection is successful. If the communication is unexpectedly terminated during the process, the client will not be able to receive the callback again.
Environment details
Steps to reproduce
In the following class:com.google.genai.AsyncLive.GenAiWebSocketClient
This sessionFuture is already in the "Done" state after the connection is successful. If the communication is unexpectedly terminated during the process, the client will not be able to receive the callback again.