Performance Report
The following test setup and observations were made during the implementation of the retry logic for Azure Postgres PaaS.
Test environment parameters (local machine):
Processor: Intel(R) Core(TM) i7-7820HQ CPU 2.90 GHz
RAM: 32 GB
OS: Windows 10
Database: PostgreSQL
Implementation
A persistent and logged property was updated after every 5 seconds while the database was shut down for 5 minutes.
Following were the values of configurable parameters:
acquireRetryAttempts: 350
acquireRetryDelay: 1000
DatabaseWriteRetryAttempts: 10
Performance Metrics
Before database shutdown:
1. Platform Subsystem
2. Value Stream Processing Subsystem
When database was shut for 4 minutes:
1. Platform Subsystem
2. Value Stream Processing Subsystem
After database becomes available again:
1. Platform Subsystem
2. Value Stream Processing Subsystem
Conclusion
During database unavailability, data ingested is accumulated in the valuestream queue. This can be observed from the above metrics, as:
1. Number of entries currently queued increases
2. Number of stream entries that have been queued > Number of stream entries that have been performed
After the database becomes available again, the queue gets drained and the entries in the queue are processed or persisted. This can be confirmed from the performance metrics as:
1. Number of entries currently queued becomes 0.
2. Number of stream entries that have been performed increases
* 
These observations are specific to only this exact test setup and customers would observe different behavior or outcomes for their specific load etc.
Was this helpful?