Skip to content

Commit

Permalink
Add http connector to quickstart setup (#509)
Browse files Browse the repository at this point in the history
* add file http_pipeline.yml to integrate http connector
---------

Co-authored-by: ekneg54 <[email protected]>
  • Loading branch information
djkhl and ekneg54 authored Feb 6, 2024
1 parent d1717d6 commit a948f3a
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -394,11 +394,11 @@ Opensearch Dashboards. Following services are available after start up:
The example rules that are used in the docker instance of Logprep can be found
in `quickstart/exampledata/rules`.
Example events that trigger for the example rules can be found in
`quickstart/exampledata/input_logdata/test_input.jsonl`.
`quickstart/exampledata/input_logdata/logclass/test_input.jsonl`.
These events can be added to Kafka with the following command:
```bash
(docker exec -i kafka kafka-console-producer.sh --bootstrap-server 127.0.0.1:9092 --topic consumer) < exampledata/input_logdata/test_input.jsonl
(docker exec -i kafka kafka-console-producer.sh --bootstrap-server 127.0.0.1:9092 --topic consumer) < exampledata/input_logdata/logclass/test_input.jsonl
```

Once the events have been processed for the first time, the new indices *processed*, *sre*
Expand Down
25 changes: 25 additions & 0 deletions quickstart/exampledata/config/http_pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
version: 1

metrics:
enabled: true
port: 8000

input:
httpinput:
type: http_input
uvicorn_config:
host: 0.0.0.0
port: 9000
endpoints:
/lab/123/ABC/auditlog: jsonl
output:
kafka:
type: confluentkafka_output
topic: consumer
error_topic: errors
flush_timeout: 300
send_timeout: 0
kafka_config:
bootstrap.servers: 127.0.0.1:9092
compression.type: gzip
statistics.interval.ms: "60000"
7 changes: 7 additions & 0 deletions quickstart/exampledata/input_logdata/logclass/config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
target_path: /lab/123/ABC/auditlog
timestamps:
- key: TIMESTAMP_FIELD_1
format: "%Y%m%d"
- key: TIMESTAMP_FIELD_1
format: "%H%M%S"
time_shift: "+0200"

0 comments on commit a948f3a

Please sign in to comment.