#1127 mod_csi_battery_saver: set CSI-active on resume, not on hibernation
Reporter
Ge0rG
Owner
Nobody
Created
Updated
Stars
★ (1)
Tags
Component-Community
Status-Fixed
Type-Defect
Priority-Medium
Ge0rG
on
mod_csi_battery_saver will set CSI state to "active" and flush the queue when a smacks-enabled session is hibernated. This interacts very badly with mod_cloud_notify, which will see new stanzas in the smacks queue and trigger a push notification to wake up the device.
Please change the behavior to keep smacks-hibernated sessions as CSI-inactive (or maybe even explicitly make them "inactive" on hibernation), and to only reset to active when the session is resumed (but prior to processing any stanzas from the resumed session, as those might contain another CSI-inactive setting). This also has the benefit of flushing the queue at a moment when we know the client is most probably there and listening.
Zash
on
Changes
tags Component-Community
Zash
on
Thanks for the report. This has been fixed according to tmolitor
mod_csi_battery_saver will set CSI state to "active" and flush the queue when a smacks-enabled session is hibernated. This interacts very badly with mod_cloud_notify, which will see new stanzas in the smacks queue and trigger a push notification to wake up the device. Please change the behavior to keep smacks-hibernated sessions as CSI-inactive (or maybe even explicitly make them "inactive" on hibernation), and to only reset to active when the session is resumed (but prior to processing any stanzas from the resumed session, as those might contain another CSI-inactive setting). This also has the benefit of flushing the queue at a moment when we know the client is most probably there and listening.
Thanks for the report. This has been fixed according to tmolitor
Changesfixed in https://hg.prosody.im/prosody-modules/rev/75930e4c2478