Enum Class DeliveryOutcome
- All Implemented Interfaces:
Serializable, Comparable<DeliveryOutcome>, Constable
The push subsystem records an outcome for every matched subscription, including those it deliberately did not deliver to. There is no silent category: a subscription that was excluded, unauthorized, unroutable, or found dead is reported with the reason, so that the ServerAdmin operator sees the whole shape of a send — delivered, and not-delivered-and-why — and so that the aggregate forms an auditable record of exactly which regions a send touched.
Persistence note. Should an outcome be stored in a property container, it is stored by ordinal() (see the enum-storage idiom in IPushSettings). The order of these constants is therefore part of the persisted contract: new constants MUST be appended at the end, never inserted or reordered, or an existing stored value will silently change meaning.
- Author:
- IIZI
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E>Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionDelivered to the device endpoint by a push transport (VAPID or FCM).Delivered in-session, by a write down the recipient's live WebSocket.The push endpoint reported the subscription as gone (an HTTP 410, or the transport's equivalent).Matched the send's filter but excluded because its region was not in the send's target region set.The notification's time-to-live elapsed before it could be delivered, in the spool or in transit.The target user's AppSessionGyro existed and had this notification (and possibly others) retained pending delivery — because no ClientSessionGyro was connected to receive it — and then the app session timed out before any device reconnected to drain the pending notifications.The in-session path was attempted but no app session for the target user could be located at all — the user has no live AppSessionGyro on this server.The in-session path was attempted but the target user is not signed in to the app session that would receive the notification.The subscription's region is known and authorized, but that region's server was unreachable.Held in the write-ahead spool for later replay, because no recipient was reachable or the target region's server was down.The subscription's transport is not configured on this server: the application has no key pair or Firebase credentials, or the transport is held (APNS).The push service rejected the message permanently and a retry would not help: a malformed request, a refused VAPID or FCM credential, or a payload over the service's size limit.Matched the filter and has a known region, but the operator issuing the send is not authorized for that region.The subscription's region could not be resolved, and the effectiveResidencyPolicywasResidencyPolicy.MUST, so it was not sent.Method Summary
Modifier and TypeMethodDescriptionstatic DeliveryOutcomeReturns the enum constant of this class with the specified name.static DeliveryOutcome[]values()Returns an array containing the constants of this enum class, in the order they are declared.
Enum Constant Details
DELIVERED_IN_SESSION
Delivered in-session, by a write down the recipient's live WebSocket. The fastest tier; touched no push endpoint.DELIVERED
Delivered to the device endpoint by a push transport (VAPID or FCM).SPOOLED
Held in the write-ahead spool for later replay, because no recipient was reachable or the target region's server was down. Will be retried on restart or when the region returns, unless its TTL elapses first.EXCLUDED_BY_REGION
Matched the send's filter but excluded because its region was not in the send's target region set. Not an error — the operator asked for certain regions and this subscription fell outside them — but reported so the operator can see what the region selection dropped.UNAUTHORIZED_REGION
Matched the filter and has a known region, but the operator issuing the send is not authorized for that region. Rejected at plan-build time, before any dispatch, so no data boundary is crossed. This is the outcome for, e.g., an India-resident subscription under an operator authorized only for Europe and the USA.UNRESOLVABLE_RESIDENCY
The subscription's region could not be resolved, and the effectiveResidencyPolicywasResidencyPolicy.MUST, so it was not sent. Failing closed on unknown residency rather than sending from an unverified location.REGION_UNREACHABLE
The subscription's region is known and authorized, but that region's server was unreachable. The notification is spooled for the region where the policy allows; the distinction fromSPOOLEDis that here the failure is a whole region being down, not an individual endpoint.ENDPOINT_STALE
The push endpoint reported the subscription as gone (an HTTP 410, or the transport's equivalent). The subscription is dead and should be pruned.IN_APP_SESSION_USER_NOT_SIGNED_IN
The in-session path was attempted but the target user is not signed in to the app session that would receive the notification. There is a session context, but no authenticated user in it to deliver to.IN_APP_SESSION_USER_NOT_FOUND
The in-session path was attempted but no app session for the target user could be located at all — the user has no live AppSessionGyro on this server.IN_APP_SESSION_USER_CLOSED_ALL_SESSIONS
The target user's AppSessionGyro existed and had this notification (and possibly others) retained pending delivery — because no ClientSessionGyro was connected to receive it — and then the app session timed out before any device reconnected to drain the pending notifications. The app session closed with undelivered notifications still held.This is distinct from
IN_APP_SESSION_USER_NOT_FOUND(there never was a session) andIN_APP_SESSION_USER_NOT_SIGNED_IN(there is a session but no authenticated user): here the session existed, held the notification, and expired.Fallback behaviour. When an app session times out holding pending notifications, each pending notification falls back to a device push (VAPID/FCM) from this same server. No re-routing is needed: the user was, by definition, just connected to this server, so this server is already residency-legal for them and the fallback is a local Tier 2 send, not a routed one. The outcome then becomes the fallback's —
DELIVERED,SPOOLED, orENDPOINT_STALE.This code is therefore reported only as the terminal case where no fallback can be attempted: the user has no device subscription to fall back to, or the notification's
DeliveryModeforbids the device tier. It means the in-session path ended and no device channel caught it.TRANSPORT_REJECTED
The push service rejected the message permanently and a retry would not help: a malformed request, a refused VAPID or FCM credential, or a payload over the service's size limit. Not spooled; reported with the reason so the configuration fault is visible.TRANSPORT_NOT_CONFIGURED
The subscription's transport is not configured on this server: the application has no key pair or Firebase credentials, or the transport is held (APNS). Not spooled, because nothing on this server can ever deliver it until the configuration changes.EXPIRED
The notification's time-to-live elapsed before it could be delivered, in the spool or in transit. Dropped, never replayed.
Method Details
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null