Hey <@ULVA73B9P>, With prefect 1 community deploym...
# ask-marvin
m
Hey @Marvin, With prefect 1 community deployment. Is there a way to see how many API calls are being made? We want to figure out if 2000 a minute is enough for a prefect 3 migration
m
To track the number of API calls being made in Prefect 1.x, you can utilize logging and monitoring tools external to Prefect, as native monitoring of API call metrics is not inherently provided. However, for Prefect 2.x and 3.x, the newer versions are mostly designed to work seamlessly with various cloud-native tools that might assist in monitoring and logging activities, including API interactions. From what I found in my search: 1. Prometheus Integration: For Prefect 2.x and beyond, there is interest and ongoing development to expose a
/metrics
endpoint, following Prometheus' data model. This would make it easier to monitor metrics, including API calls, using tools like Grafana. One related issue on GitHub suggests that such endpoints could provide insights into job metrics, although it's not confirmed for API call counts specifically. GitHub Issue 2. Audit Logs: In the Prefect Cloud, especially for Pro and Custom plans, audit logs are available, which provide records of activities, possibly including API calls. However, this would be more about user actions rather than direct API call counts. 3. Client Communication: Both Prefect 2.x and 3.x allow the Prefect client to communicate with the server via an API. This indicates that tracking the API versions in use is feasible, but doesn't inherently track the volume. Prefect 2.x Documentation mentions using the REST API for various client-server interactions. Given your setup in Prefect 1.x, you might need to consider leveraging third-party application performance monitoring (APM) tools that can monitor network traffic to track API calls separately from Prefect. For future-proofing and migration considerations, looking into these potential integrations and documentations in Prefect 2.x and 3.x might be beneficial. If you plan to migrate and expect a high volume of API calls, ensuring your infrastructure can handle at least 2000 API calls per minute alongside robust monitoring can be an important aspect of your migration strategy.