-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Don't automatically close exchanges if the underlying connection closes. #7114
Don't automatically close exchanges if the underlying connection closes. #7114
Conversation
dac51ef
to
dbef181
Compare
Size increase report for "esp32-example-build" from 06d606f
Full report output
|
Size increase report for "gn_qpg6100-example-build" from 06d606f
Full report output
|
Size increase report for "nrfconnect-example-build" from 06d606f
Full report output
|
// connection state) value, because it's still referencing the now-expired | ||
// connection. This will mean that no more messages can be sent via this | ||
// exchange, which seems fine given the semantics of connection expiration. | ||
mSecureSession = SecureSessionHandle(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After we reset the SessionHandle, this exchange can not be used to send any message.
Let's go back the the original issue.
After we send AddRootCert command and receive the response to AddRootCert, the connection is closed.
Now we don't close the exchange, but reset the SessionHandle of the exchange.
On which exchange we send AddNetwork Command? My understand is we should continue to use the same exchange to send this command and close the exchange when we reach the end of conversation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On which exchange we send AddNetwork Command?
A different one. Each new Invoke is a new exchange in the spec.
Someone might still have a reference to those exchanges, and we will end up with an unbalanced release. Instead just notify our consumer in the specific case when we are waiting for a response so it knows the response will never come (and presumably closes the exchange as needed).
dbef181
to
ad3dfa8
Compare
…es. (project-chip#7114) Someone might still have a reference to those exchanges, and we will end up with an unbalanced release. Instead just notify our consumer in the specific case when we are waiting for a response so it knows the response will never come (and presumably closes the exchange as needed).
Someone might still have a reference to those exchanges, and we will
end up with an unbalanced release. Instead just notify our consumer
in the specific case when we are waiting for a response so it knows
the response will never come (and presumably closes the exchange as
needed).
Problem
Fixes #7012
Change overview
Instead of hard-closing exchanges on connection close, just notify the ones that are waiting for a response that it won't be coming.
Testing