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

Fix for MikroTik devices experiencing endless loop with transfer #350

Closed
wants to merge 1 commit into from
Closed

Conversation

mjducharme
Copy link
Contributor

MikroTik devices do not close the session cleanly after the TransferCompleteResponse - they reboot without properly terminating the session. This patch works around the behavior of the device and should not change the behavior for non-MikroTik devices.

MikroTik devices do not close the session cleanly after the TransferCompleteResponse - they reboot without properly terminating the session. This patch works around the behavior of the device and should not change the behavior for non-MikroTik devices.
@zaidka
Copy link
Member

zaidka commented Jul 18, 2019

I had a discussion with the folks from MiroTik about this exact issue a while back. After much back and forth I realized that the spec says that TransferComplete message should be considered as delivered even if the session was not eventually closed properly. So this is actually a bug in Genie that needs to be fixed. Problem is that fixing this might take a toll on performance so I need to find a way to keep the performance impact to the minimum.

I would consider this to be an issue in the client as well. The client shouldn't be designed to exploit measures meant for abnormal cases (e.g. network or power outage) during its normal operation. But that's beside the point.

@seimnseimn
Copy link

Even though this is not related to TransferComplete. Many devices do not properly close the session on actions which are followed by a device-restart (e.g. reset, factory-rese, fw-upgrade, ...).
Haven't spent much on this but if you implement a solution it might make sense to look at this at a wider angle.

@zaidka
Copy link
Member

zaidka commented Jul 18, 2019

@seimnseimn yeah it should probably be made to commit all data model changes regardless of whether the session was closed or not. This is not going to be an easy one :)

@mjducharme
Copy link
Contributor Author

@zaidka I was just wondering if this is somehow fixed by default in 1.2.0? Currently we are relying on my fix in this PR in the older version. I'm not sure I want to upgrade right away if it will break this feature again.

@zaidka
Copy link
Member

zaidka commented Jan 3, 2021

This has been addressed in the upcoming 1.2.4 release.

@zaidka zaidka closed this Jan 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants