-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[lgwebos] Avoid thing updates when the thing handler is already disposed #7299
Conversation
Travis tests were successfulHey @lolodomo, |
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.
LGTM
...ding.lgwebos/src/main/java/org/openhab/binding/lgwebos/internal/handler/LGWebOSTVSocket.java
Outdated
Show resolved
Hide resolved
...ding.lgwebos/src/main/java/org/openhab/binding/lgwebos/internal/handler/LGWebOSTVSocket.java
Outdated
Show resolved
Hide resolved
01f4990
to
ad918d4
Compare
Ok, I just updated the PR, the problem is now handled by the thing handler. |
Travis tests were successfulHey @lolodomo, |
still trying to understand the issue. OH initializes the handler I agree that we could optimize both storeProperties and storeKey to only actually update if values changed. It may already solve the problem, as these values are only set once at the beginning. storeKey today is already designed not to go through re-initialization. Is storeProperties the problem? Or is the problem, that the the connection sequence continues running, while the binding disposes, calls disconnect and LGWebOSTVSocket is in state DISCONNECTED. If so, what we could do is to stop the sequence by putting entry conditions into the connection sequence of LGWebOSTVSocket::onMessage // add additional state CONNECTING
|
Yes, you got it. Your option looks good to me, it is more or less the same as my previous test "listener == null" but with a really cleaner solution. |
ad918d4
to
88105f9
Compare
Signed-off-by: Laurent Garnier <lg.hc@free.fr>
88105f9
to
935ad8a
Compare
@sprehn : please review this new version. |
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.
LGTM
@sprehn : just one question/detail: we stop reconnection job and start keep alive job when the state is changed to REGISTERING. Should we rather do it now when the state is changed to CONNECTING ? |
@cpmeister : can you start a new review please ? The PR was largely changed since your first approval. |
Good point. It is better to stopReconnectJob() in CONNECTING. |
… the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
Change with jobs done |
Travis tests were successfulHey @lolodomo, |
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.
LGTM
Manually approved sign-off |
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr> Signed-off-by: Hans-Reiner Hoffmann <hans-reiner.hoffmann@gmx.de>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr> Signed-off-by: Eugen Freiter <freiter@gmx.de>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr> Signed-off-by: CSchlipp <christian@schlipp.de>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr> Signed-off-by: Daan Meijer <daan@studioseptember.nl>
…sed (openhab#7299) * [lgwebos] Avoid thing updates when the thing handler is already disposed * Change of state trigger for stopping the reconection job and starting the keep alive job Signed-off-by: Laurent Garnier <lg.hc@free.fr>
Signed-off-by: Laurent Garnier lg.hc@free.fr