Skip to content

Commit

Permalink
[loadgenerator] fix browser traffic enabled flag (#1359)
Browse files Browse the repository at this point in the history
* fix browser traffic enabled flag

Signed-off-by: Pierre Tessier <pierre@pierretessier.com>

* fix browser traffic enabled flag

Signed-off-by: Pierre Tessier <pierre@pierretessier.com>

---------

Signed-off-by: Pierre Tessier <pierre@pierretessier.com>
Co-authored-by: Juliano Costa <julianocosta89@outlook.com>
  • Loading branch information
puckpuck and julianocosta89 authored Feb 7, 2024
1 parent 23094bf commit d1575de
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
1 change: 0 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ LOCUST_HOST=http://${FRONTEND_PROXY_ADDR}
LOCUST_WEB_HOST=loadgenerator
LOCUST_AUTOSTART=true
LOCUST_HEADLESS=false
LOCUST_BROWSER_TRAFFIC_ENABLED=false

# Payment Service
PAYMENT_SERVICE_PORT=50051
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ the release.
([#1357](https://github.com/open-telemetry/opentelemetry-demo/pull/1357))
* Update Python SDKs
([#1358](https://github.com/open-telemetry/opentelemetry-demo/pull/1358))
* [loadgenerator] fix browser traffic enabled flag
([#1359](https://github.com/open-telemetry/opentelemetry-demo/pull/1359))

## 1.7.2

Expand Down
3 changes: 2 additions & 1 deletion docker-compose.minimal.yml
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,7 @@ services:
- LOCUST_HOST
- LOCUST_HEADLESS
- LOCUST_AUTOSTART
- LOCUST_BROWSER_TRAFFIC_ENABLED=false
- OTEL_EXPORTER_OTLP_ENDPOINT
- OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE
- OTEL_RESOURCE_ATTRIBUTES
Expand Down Expand Up @@ -467,7 +468,7 @@ services:
image: ${JAEGERTRACING_IMAGE}
container_name: jaeger
command:
- "--memory.max-traces=8000"
- "--memory.max-traces=5000"
- "--query.base-path=/jaeger/ui"
- "--prometheus.server-url=http://${PROMETHEUS_ADDR}"
- "--prometheus.query.normalize-calls=true"
Expand Down
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ services:
- LOCUST_HOST
- LOCUST_HEADLESS
- LOCUST_AUTOSTART
- LOCUST_BROWSER_TRAFFIC_ENABLED
- LOCUST_BROWSER_TRAFFIC_ENABLED=true
- OTEL_EXPORTER_OTLP_ENDPOINT
- OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE
- OTEL_RESOURCE_ATTRIBUTES
Expand Down Expand Up @@ -620,7 +620,7 @@ services:
image: ${JAEGERTRACING_IMAGE}
container_name: jaeger
command:
- "--memory.max-traces=8000"
- "--memory.max-traces=5000"
- "--query.base-path=/jaeger/ui"
- "--prometheus.server-url=http://${PROMETHEUS_ADDR}"
- "--prometheus.query.normalize-calls=true"
Expand Down
2 changes: 1 addition & 1 deletion src/loadgenerator/locustfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def on_start(self):
self.index()


browser_traffic_enabled = os.environ.get('LOCUST_BROWSER_TRAFFIC_ENABLED', False)
browser_traffic_enabled = os.environ.get("LOCUST_BROWSER_TRAFFIC_ENABLED", "").lower() in ("true", "yes", "on")

if browser_traffic_enabled:
class WebsiteBrowserUser(PlaywrightUser):
Expand Down

0 comments on commit d1575de

Please sign in to comment.