Question

I'm using the Notification XML API, and Google seems to be delivering notifications not in the order I expect. For example, an order-state-change notification will have a new-financial-order-state of CHARGING after one immediately preceding it had already set it to CHARGED.

It seems like the IPN serial-numbers are monotonically increasing, however, so perhaps I can use them to ignore notifications which arrive out of order? I don't see any documentation on whether that's something which will be future-proof.

Was it helpful?

Solution

The only Checkout notification guaranteed to arrive in order is the new order notification which will arrive first.

While typically notifications don't arrive out of order they occasionally can.

For order state notifications, your solution sounds fine to me, setting the state of the order to the order state notification with the highest serial number.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top