Skip to content

Comments

Disable rate limit in tnresources unit tests#3579

Merged
denik merged 2 commits intomainfrom
denik/disable-ratelimit
Sep 9, 2025
Merged

Disable rate limit in tnresources unit tests#3579
denik merged 2 commits intomainfrom
denik/disable-ratelimit

Conversation

@denik
Copy link
Contributor

@denik denik commented Sep 9, 2025

Why

This is running against local testserver.

Before:

--- PASS: TestAll (3.74s)
    --- PASS: TestAll/pipelines (0.34s)
    --- PASS: TestAll/schemas (0.40s)
    --- PASS: TestAll/volumes (0.40s)
    --- PASS: TestAll/apps (0.47s)
    --- PASS: TestAll/sql_warehouses (0.40s)
    --- PASS: TestAll/database_instances (0.47s)
    --- PASS: TestAll/database_catalogs (0.47s)
    --- PASS: TestAll/synced_database_tables (0.40s)
    --- PASS: TestAll/jobs (0.40s)

After:

--- PASS: TestAll (0.01s)
    --- PASS: TestAll/schemas (0.00s)
    --- PASS: TestAll/database_instances (0.00s)
    --- PASS: TestAll/synced_database_tables (0.00s)
    --- PASS: TestAll/jobs (0.00s)
    --- PASS: TestAll/pipelines (0.00s)
    --- PASS: TestAll/volumes (0.00s)
    --- PASS: TestAll/apps (0.00s)
    --- PASS: TestAll/sql_warehouses (0.00s)
    --- PASS: TestAll/database_catalogs (0.00s)

@denik denik temporarily deployed to test-trigger-is September 9, 2025 14:19 — with GitHub Actions Inactive
@denik denik enabled auto-merge September 9, 2025 14:21
@eng-dev-ecosystem-bot
Copy link
Collaborator

eng-dev-ecosystem-bot commented Sep 9, 2025

Run: 17585687084

Env ✅​pass 🔄​flaky 🙈​skip
✅​ aws linux 311 524
✅​ aws windows 312 523
✅​ aws-ucws linux 423 422
✅​ aws-ucws windows 424 421
✅​ azure linux 311 523
🔄​ azure windows 311 1 522
✅​ azure-ucws linux 423 421
✅​ azure-ucws windows 424 420
✅​ gcp linux 310 525
✅​ gcp windows 311 524
Test Name azure windows
TestFetchRepositoryInfoAPI_FromRepo 🔄​flaky

@denik denik added this pull request to the merge queue Sep 9, 2025
Merged via the queue into main with commit d976ed3 Sep 9, 2025
13 checks passed
@denik denik deleted the denik/disable-ratelimit branch September 9, 2025 14:57
github-merge-queue bot pushed a commit that referenced this pull request Sep 10, 2025
)

## Changes

Respect DATABRICKS_RATE_LIMIT variable and pass it to tests if set.

If not set, set to higher defaults depending on local/cloud.

Related: #3579

## Tests

New acc test with parallel resources that is good to demo the
difference. Manually try different rate limits:

Set a very low limit:

```
~/work/cli-main/acceptance/bundle/resources/independent % DATABRICKS_RATE_LIMIT=1 testme -v -count=1
+ go test ../../.. -run ^TestAccept$/^bundle$/^resources$/^independent$ -v -count=1
…
        --- PASS: TestAccept/bundle/resources/independent/DATABRICKS_CLI_DEPLOYMENT=direct-exp (16.47s)
        --- PASS: TestAccept/bundle/resources/independent/DATABRICKS_CLI_DEPLOYMENT=terraform (22.34s)
```

Restore SDK default:

```
~/work/cli-main/acceptance/bundle/resources/independent % DATABRICKS_RATE_LIMIT=15 testme -v -count=1
+ go test ../../.. -run ^TestAccept$/^bundle$/^resources$/^independent$ -v -count=1
        --- PASS: TestAccept/bundle/resources/independent/DATABRICKS_CLI_DEPLOYMENT=direct-exp (1.52s)
        --- PASS: TestAccept/bundle/resources/independent/DATABRICKS_CLI_DEPLOYMENT=terraform (5.02s)
```


New default:

```
~/work/cli-main/acceptance/bundle/resources/independent % testme -v -count=1
+ go test ../../.. -run ^TestAccept$/^bundle$/^resources$/^independent$ -v -count=1
        --- PASS: TestAccept/bundle/resources/independent/DATABRICKS_CLI_DEPLOYMENT=direct-exp (0.46s)
        --- PASS: TestAccept/bundle/resources/independent/DATABRICKS_CLI_DEPLOYMENT=terraform (2.36s)
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants