[Performance API] pastAlerts timing out

48 views
Skip to first unread message

Austin Paul

unread,
Nov 29, 2021, 2:33:35 PM11/29/21
to massdotd...@googlegroups.com
Hello,

It seems that the pastAlerts endpoint of the performance API can no longer respond to queries of the form https://performanceapi.mbta.com/developer/api/v2.1/pastalerts?format=json&from_datetime=1637051401&to_datetime=1637137800

For most of the last month, any request for 24 hours of alerts will return HTTP code 500 after 60 seconds with the body:
{ "error": { "message": "Failed to get past alerts data" }}
I would love to still be able to pull all alerts for a 24 hours period at once. Is this something that can be fixed? Is there a convenient workaround?

Thank you,
Austin

Developer at MBTA

unread,
Dec 6, 2021, 4:05:25 PM12/6/21
to MBTA Developers
Hi Austin,

Thanks for bringing this to our attention. We investigated the issue and found an optimization that should resolve it. Please let us know if you're still getting these 60-second timeouts after today.

—Developer@MBTA

Austin Paul

unread,
Dec 13, 2021, 4:11:50 PM12/13/21
to massdotd...@googlegroups.com
Hi,

Thank you for addressing this! I am seeing far fewer of these timeouts, but still more than would be ideal.
It's intermittent enough that a 3x retry on my end is not enough to guarantee a successful response.

Best,
Austin


--
You received this message because you are subscribed to the Google Groups "MBTA Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to massdotdevelop...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/massdotdevelopers/b4cd2592-ddd3-4d19-b714-befabfb742bbn%40googlegroups.com.

Developer at MBTA

unread,
Dec 21, 2021, 4:24:42 PM12/21/21
to MBTA Developers
Hi Austin,

Thanks for the heads-up. We've made some additional optimizations, and are no longer seeing any timeouts in our testing. Please let us know if you continue to see them after today, and if there is a specific request with a high incidence of timeouts we can use to reproduce the issue.

—Developer@MBTA

Austin Paul

unread,
Jan 7, 2022, 11:38:11 PM1/7/22
to massdotd...@googlegroups.com
Thanks for continuing to work on this!
The responses were quite speedy (<10s response times) for the remainder of December, but they seem to be creeping upwards, and I'm starting to see timeouts again (though not as consistently).
The following query takes ~45 seconds when successful, but tends to error out when I send two requests at the same time.


I am able to increase the number of retries on my end as a work-around if it turns out this is as good as it will get.

Thank you,
Austin

Reply all
Reply to author
Forward
0 new messages