univapay / univapay-java-sdk

UnivaPay SDK library for Java
1 stars 1 forks source link

Flaky multiple GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges being made in short interval after subscription creation causing rate limit to kick in #442

Open csggrew opened 1 month ago

csggrew commented 1 month ago

Logs:

Time Method URI Response
2024-09-17 21:36:25.498 POST /subscriptions 201 with created subscription object
2024-09-17 21:36:26.257 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}?polling=true 200
2024-09-17 21:36:26.499 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 {"items":[],"has_more":false,"total_hits":0}
2024-09-17 21:36:26.633 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 {"items":[],"has_more":false,"total_hits":0}
2024-09-17 21:36:26.640 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 with created charge object
2024-09-17 21:36:26.683 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 {"items":[],"has_more":false,"total_hits":0}
2024-09-17 21:36:26.692 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 with created charge object
2024-09-17 21:36:26.709 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 with created charge object
2024-09-17 21:36:26.736 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 with created charge object
2024-09-17 21:36:26.749 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 with created charge object
2024-09-17 21:36:26.750 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 429
2024-09-17 21:36:26.766 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 200 with created charge object
2024-09-17 21:36:26.802 GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 429
From 21:36:26.802 onwards GET /stores/{{store_id}}/subscriptions/{{subscription_id}}/charges 429
andrezimmermann commented 1 month ago

Thanks, I will DM you later, I will need the response body of the requests to write an unit tests