This is an automated email from the ASF dual-hosted git repository.
urfree pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/pulsar-site.git
The following commit(s) were added to refs/heads/main by this push:
new f8a35e7a966 Docs sync done from apache/pulsar (#fc655c8)
f8a35e7a966 is described below
commit f8a35e7a96606bd1b4a23f61381b87bb71b0b44b
Author: github-actions[bot]
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Mon Dec 5 15:09:10 2022 +0000
Docs sync done from apache/pulsar (#fc655c8)
---
site2/website-next/docs/io-connectors.md | 6 ++++
site2/website-next/docs/io-http-sink.md | 56 ++++++++++++++++++++++++++++++++
2 files changed, 62 insertions(+)
diff --git a/site2/website-next/docs/io-connectors.md
b/site2/website-next/docs/io-connectors.md
index c23aca27b63..362c150e752 100644
--- a/site2/website-next/docs/io-connectors.md
+++ b/site2/website-next/docs/io-connectors.md
@@ -178,6 +178,12 @@ Pulsar has various sink connectors, which are sorted
alphabetically as below.
* [Java
class](https://github.com/apache/pulsar/blob/master/pulsar-io/hdfs3/src/main/java/org/apache/pulsar/io/hdfs3/AbstractHdfsConnector.java)
+### HTTP
+
+* [Configuration](io-http-sink.md#configuration)
+
+* [Java
class](https://github.com/apache/pulsar/blob/master/pulsar-io/http/src/main/java/org/apache/pulsar/io/http/HttpSink.java)
+
### InfluxDB
* [Configuration](io-influxdb-sink.md#configuration)
diff --git a/site2/website-next/docs/io-http-sink.md
b/site2/website-next/docs/io-http-sink.md
new file mode 100644
index 00000000000..7139a9a256d
--- /dev/null
+++ b/site2/website-next/docs/io-http-sink.md
@@ -0,0 +1,56 @@
+---
+id: io-http-sink
+title: HTTTP sink connector
+sidebar_label: "HTTP sink connector"
+---
+
+The HTTP sink connector pulls the records from Pulsar topics and makes a POST
request to a configurable HTTP URL (webhook).
+
+The body of the HTTP request is the JSON representation of the record value.
The header `Content-Type: application/json` is added to the HTTP request.
+
+Some other HTTP headers are added to the HTTP request:
+
+* `PulsarTopic`: the topic of the record
+* `PulsarKey`: the key of the record
+* `PulsarEventTime`: the event time of the record
+* `PulsarPublishTime`: the publish time of the record
+* `PulsarMessageId`: the ID of the message contained in the record
+* `PulsarProperties-*`: each record property is passed with the property name
prefixed by `PulsarProperties-`
+
+## Configuration
+
+The configuration of the HTTP sink connector has the following properties.
+
+### Property
+
+| Name | Type | Required | Default | Description
|
+|-----------|--------|----------|------------------|---------------------------------------------------|
+| `url` | String | false | http://localhost | The URL of the HTTP
server |
+| `headers` | Map | false | empty map | The list of default
headers added to each request |
+
+### Example
+
+Before using the HTTP sink connector, you need to create a configuration file
through one of the following methods.
+
+* JSON
+
+ ```json
+ {
+ "configs": {
+ "url": "http://my-endpoint.acme.com/api/ingest",
+ "headers": {
+ "Authentication": "xxxxx"
+ }
+ }
+ }
+ ```
+
+* YAML
+
+ ```yaml
+ configs:
+ url: "http://my-endpoint.acme.com/api/ingest"
+ headers:
+ Authentication: xxxxx
+ ```
+