Skip to content

Commit

Permalink
http_endpoint: test ack api (#9843)
Browse files Browse the repository at this point in the history
  • Loading branch information
efd6 authored May 17, 2024
1 parent 914fdfb commit d39c579
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 4 deletions.
24 changes: 20 additions & 4 deletions packages/http_endpoint/_dev/deploy/docker/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,29 @@
version: '2.3'
services:
test-webhook-http:
image: docker.elastic.co/observability/stream:v0.15.0
image: docker.elastic.co/observability/stream:v0.16.0
volumes:
- ./sample_logs:/sample_logs:ro
environment:
- STREAM_PROTOCOL=webhook
- STREAM_ADDR=http://elastic-agent:9515/json
- STREAM_WEBHOOK_HEADER=Content-Type=application/json
- STREAM_USERNAME=abc123
- STREAM_PASSWORD=abc123
command: log --start-signal=SIGHUP --webhook-username=abc123 --webhook-password=abc123 --delay=10s /sample_logs/test-webhook.log
- STREAM_WEBHOOK_USERNAME=abc123
- STREAM_WEBHOOK_PASSWORD=abc123
- STREAM_START_SIGNAL=SIGHUP
- STREAM_DELAY=10s
command: log /sample_logs/test-webhook.log
test-webhook-http-ack:
image: docker.elastic.co/observability/stream:v0.16.0
volumes:
- ./sample_logs:/sample_logs:ro
environment:
- STREAM_PROTOCOL=webhook
- STREAM_ADDR=http://elastic-agent:9516/json?wait_for_completion_timeout=1m
- STREAM_WEBHOOK_HEADER=Content-Type=application/json
- STREAM_WEBHOOK_USERNAME=abc123
- STREAM_WEBHOOK_PASSWORD=abc123
- STREAM_START_SIGNAL=SIGHUP
- STREAM_DELAY=10s
- STREAM_WEBHOOK_TIMEOUT=2m
command: log /sample_logs/test-webhook.log
13 changes: 13 additions & 0 deletions packages/http_endpoint/_dev/test/system/test-http-acked-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
service: test-webhook-http-ack
service_notify_signal: SIGHUP
input: http_endpoint
vars:
data_stream.dataset: http_endpoint.http_endpoint
preserve_original_event: true
listen_address: 0.0.0.0
url: /json
prefix: event
listen_port: 9516
basic_auth: true
username: abc123
password: abc123
5 changes: 5 additions & 0 deletions packages/http_endpoint/changelog.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
- version: "2.0.0-next" # Merge into next version and delete this and the following line.
changes:
- description: Added test for end-to-end ACK behaviour.
type: enhancement
link: https://github.com/elastic/integrations/pull/9843
- version: "2.0.0"
changes:
- description: Converted package to input type.
Expand Down

0 comments on commit d39c579

Please sign in to comment.