Skip to content

Commit b1627a3

Browse files
authored
[integrations][http_endpoint] - Converted HTTP Endpoint Integration to input type (elastic#9732)
* converted http_endpoint to input package type * updated changelog * updated original event in sample event
1 parent 3a9b508 commit b1627a3

File tree

12 files changed

+253
-235
lines changed

12 files changed

+253
-235
lines changed

‎packages/http_endpoint/_dev/build/docs/README.md‎

Lines changed: 0 additions & 18 deletions
This file was deleted.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
service: test-webhook-http
2+
service_notify_signal: SIGHUP
3+
input: http_endpoint
4+
vars:
5+
data_stream.dataset: http_endpoint.http_endpoint
6+
preserve_original_event: true
7+
listen_address: 0.0.0.0
8+
url: /json
9+
prefix: event
10+
listen_port: 9515
11+
basic_auth: true
12+
username: abc123
13+
password: abc123

packages/http_endpoint/data_stream/generic/agent/stream/http.yml.hbs renamed to packages/http_endpoint/agent/input/http.yml.hbs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ prefix: {{prefix}}
99
{{#if pipeline}}
1010
pipeline: {{pipeline}}
1111
{{/if}}
12-
{{#if preserve_original_event}}
13-
preserve_original_event: {{preserve_original_event}}
14-
{{/if}}
1512
{{#if basic_auth}}
1613
basic_auth: {{basic_auth}}
1714
{{/if}}
@@ -61,12 +58,13 @@ include_headers:
6158
ssl:
6259
{{ssl}}
6360
{{/if}}
64-
{{#if tags}}
6561
tags:
62+
{{#if preserve_original_event}}
63+
- preserve_original_event
64+
{{/if}}
6665
{{#each tags as |tag|}}
6766
- {{tag}}
6867
{{/each}}
69-
{{/if}}
7068
{{#contains "forwarded" tags}}
7169
publisher_pipeline.disable_host: true
7270
{{/contains}}

‎packages/http_endpoint/changelog.yml‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
- version: "2.0.0"
2+
changes:
3+
- description: Converted package to input type.
4+
type: enhancement
5+
link: https://github.com/elastic/integrations/pull/9732
16
- version: "1.16.0"
27
changes:
38
- description: Allow user selection of HTTP method.

‎packages/http_endpoint/data_stream/generic/_dev/test/system/test-http-config.yml‎

Lines changed: 0 additions & 12 deletions
This file was deleted.

‎packages/http_endpoint/data_stream/generic/manifest.yml‎

Lines changed: 0 additions & 182 deletions
This file was deleted.
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
- name: cloud
2+
title: Cloud
3+
group: 2
4+
description: Fields related to the cloud or infrastructure the events are coming from.
5+
footnote: 'Examples: If Metricbeat is running on an EC2 host and fetches data from its host, the cloud info contains the data about this machine. If Metricbeat runs on a remote machine outside the cloud and fetches data from a service running in the cloud, the field contains cloud data from the machine the service is running on.'
6+
type: group
7+
fields:
8+
- name: project.id
9+
type: keyword
10+
description: Name of the project in Google Cloud.
11+
- name: image.id
12+
type: keyword
13+
description: Image ID for the cloud instance.
14+
- name: host
15+
title: Host
16+
group: 2
17+
description: 'A host is defined as a general computing instance. ECS host.* fields should be populated with details about the host on which the event happened, or from which the measurement was taken. Host types include hardware, virtual machines, Docker containers, and Kubernetes nodes.'
18+
type: group
19+
fields:
20+
- name: containerized
21+
type: boolean
22+
description: >
23+
If the host is a container.
24+
25+
- name: os.build
26+
type: keyword
27+
example: "18D109"
28+
description: >
29+
OS build information.
30+
31+
- name: os.codename
32+
type: keyword
33+
example: "stretch"
34+
description: >-
35+
OS codename, if any.

packages/http_endpoint/data_stream/generic/fields/base-fields.yml renamed to packages/http_endpoint/fields/base-fields.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
- name: event.dataset
1515
type: constant_keyword
1616
description: Event dataset
17-
value: http_endpoint.generic
1817
- name: "@timestamp"
1918
type: date
2019
description: Event timestamp.
File renamed without changes.

packages/http_endpoint/data_stream/generic/fields/ecs.yml renamed to packages/http_endpoint/fields/ecs.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
- name: ecs.version
22
external: ecs
3+
- name: event.code
4+
external: ecs
5+
- name: event.created
6+
external: ecs
37
- name: log.level
48
external: ecs
59
- name: message

0 commit comments

Comments
 (0)