azure-cosmos-db-emulator-docker
azure-cosmos-db-emulator-docker copied to clipboard
Docker Image (Linux) Disable Rate Limiting
The Windows emulator allows you to disable rate limiting via the system tray. How can this be disabled when running the emulator docker image? The start.sh appears to allow additional start up arguments from the environment variable AZURE_COSMOS_EMULATOR_ARGS but this does not appear to be respected as I quickly start to get 429 responses when trying to insert a lot of data.
docker-compose yaml snippet:
cosmosdb: container_name: cosmosdb hostname: cosmosdb image: mcr.microsoft.com/cosmosdb/linux/azure-cosmos-emulator platform: linux tty: true restart: always mem_reservation: 8gb cpu_percent: 50 environment: - AZURE_COSMOS_EMULATOR_DEFAULT_PARTITION_COUNT=30 - AZURE_COSMOS_EMULATOR_PARTITION_COUNT=30 - AZURE_COSMOS_EMULATOR_ENABLE_DATA_PERSISTENCE=true - AZURE_COSMOS_EMULATOR_IP_ADDRESS_OVERRIDE=127.0.0.1 - AZURE_COSMOS_EMULATOR_ARGS=/DisableRateLimiting ports: - "8081:8081" - "10250-10255:10250-10255" volumes: - cosmos:/tmp/cosmos/appdata
I would expect there to be no rate limiting
OS: Windows 11
**Docker Images Used: **
- Linux
In my case it's the other way around - rate limit doesn't work on Linux. Sometimes I get the error "Error: socket hang up", and sometimes during bulk operation in which the sum of requestCharge from each operation is clearly greater than 400 (the default throughput value), each operation ends with success! I checked how the same script works on the emulator installed on Windows, and here it works correctly - I get 429 error
Not working for me as well. Having emulator installed on VM with Windows (accessing it from Linux) I am having 10 times higher rps than when having it on docker. When on docker, there is no CPU load. Like it is unused.