Skip to content
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion tests/appsec/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,8 @@ def iast_code_injection_vulnerability():

@app.route("/shutdown", methods=["GET"])
def shutdown_view():
tracer.shutdown(timeout=10)
# Below the caller's 10s timeout, so the flush gives up before the request does.
tracer.shutdown(timeout=5)
sys.exit(0)


Expand Down
3 changes: 2 additions & 1 deletion tests/appsec/integrations/django_tests/django_app/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@

def shutdown(request):
# Endpoint used to flush traces to the agent when doing snapshots.
tracer.shutdown()
# Bounded: the default waits forever, and under gevent the flush can block the writer's hub.
tracer.shutdown(timeout=5)
return HttpResponse(status=200)


Expand Down
4 changes: 4 additions & 0 deletions tests/appsec/suitespec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ suites:
paths:
- '@appsec_iast'
- tests/appsec/iast_packages/*
- tests/appsec/app.py
- tests/appsec/appsec_utils.py
timeout: 50m
iast_tdd_propagation:
Expand All @@ -85,6 +86,7 @@ suites:
- '@appsec_iast'
- '@remoteconfig'
- tests/appsec/iast_tdd_propagation/*
- tests/appsec/app.py
- tests/appsec/appsec_utils.py
retry: 2
snapshot: true
Expand Down Expand Up @@ -150,6 +152,7 @@ suites:
- '@appsec_iast'
- tests/appsec/integrations/flask_tests/test_iast_flask.py
- tests/appsec/integrations/flask_tests/test_appsec_flask_telemetry.py
- tests/appsec/app.py
- tests/appsec/appsec_utils.py
retry: 2
# test_appsec_flask_telemetry.py asserts on payloads received by the test agent.
Expand All @@ -165,6 +168,7 @@ suites:
- '@appsec_iast'
- '@remoteconfig'
- tests/appsec/integrations/flask_tests/*
- tests/appsec/app.py
- tests/appsec/appsec_utils.py
retry: 2
services:
Expand Down
Loading