The ENS2 uses the Exchange Web Services (EWS) subscription to notify the Boxer application of any changes in an end-users mailbox, including the email notifications. The Boxer application initiates these subscriptions with the ENS and the ENS subscribes a user's account with the EWS.
The EWS is responsible for informing the ENS when there is a change in a user's mailbox. The subscriptions have limited lifetime due to the movement of mailbox, throttling, and so on. The Exchange can drop the EWS push subscriptions which are triggered by the Exchange and the ENS does not have control over the subscription lifetime. The EWS sends notification updates to the Boxer until the EWS subscription is active and alive.
To keep these subscriptions alive, the Boxer application has a check-in mechanism which validates if an EWS subscription is alive. In addition, the ENS2 is listening for status updates from the EWS. If the ENS2 does not receive a status update from the EWS, the ENS2 can send the Boxer a silent push notification to check in with the EWS.
The following figure describes the ENS resubscription process flow.
- The EWS sends a heartbeat signal to the ENS every 15 minutes.
- The ENS sends an acknowledgement to the EWS that the heartbeat signal is received.
- The ENS checks that the heartbeat signal is received every 30 minutes from the EWS.
- If the ENS does not receive a heartbeat signal, the ENS2 sends a silent notification to the Boxer application to initiate the resubscription process.
- The Boxer application initiates a resubscription process on receiving a silent notification.
- The Boxer application proactively checks the EWS subscription status with the ENS server to ensure the continuous delivery of notifications.
The ENS2 requests the Exchange to send heartbeat that a subscription is alive. When the ENS2 detects that heartbeat is not sent, which indicates a drop in subscription. When the ENS2 detects a drop in subscription from the EWS, the ENS2 sends the Boxer a silent notification to initiate the resubscription process. On top of this, when the Boxer application can run in background, the application proactively checks the EWS subscription status with the ENS server to ensure the continuous delivery of notifications.
Therefore, the check-in mechanism used by ENS2 requires intervention from Boxer to renew the EWS subscriptions because the users credentials are required to open the subscription. These credentials are not stored in ENS. The functionality of ENS2 also depends on the Apple Push Notification Service (APNS) to deliver silent notifications to the device.
The following list describes the dependencies of the ENS2 on the EWS and APNS.
- If the Boxer application is active and receives a silent notification, the Boxer application attempts to resubscribe. When the Boxer application receives a silent notification, the Boxer sends a resubscription request to the EWS using the employee credentials.
- The iOS can stop the Boxer process without any warning due to various reasons. In such scenarios, the end users might see Boxer in the App Scroll of an iOS device, however, the Boxer process is stopped. The Boxer application has no control over this process and this state is called a killed state. If the Boxer application is in a killed state when it receives a silent notification, the Boxer application cannot resubscribe due to which the user can experience loss of notifications until the user opens the Boxer application. Opening the Boxer application triggers the ENS subscription again, and the user starts receiving notifications.
- The end user might experience an inaccurate badge count when the time subscription is lost and before the Boxer application resubscribes.
The following list describes the badge count accuracy limitations on the Boxer application:
- Sync window - The ENS checks the Inbox folder without the sync period and the Boxer unread messages are within the sync period. So, the users might have unread messages outside the sync window in the Inbox folder. The ENS reports these messages as unread while the user might not see these unread email messages in the Inbox.
- Boxer application dependency on resubscription - When the ENS is going through resubscription, the ENS does not receive any notification or badge count. During this period, the ENS does not have the updated badge count.
- Unmanaged accounts - When the user has both managed and unmanaged accounts like the Exchange account and Gmail account, the badge counts are not handled correctly.
- Comparison with Outlook on MAC devices - The Outlook on MAC devices shows certain emails as read whereas the same emails show unread when opened using Boxer or Outlook for Web Access (OWA). So, the badge count is incorrect when compared with Outlook on MAC devices.