Be responsible for consuming messages from producer and writing data to another web service system.
mvn clean install -Dmaven.test.skip=true
http://${runtime-ip}:${runtime-port}/connectors/${rocketmq-http-sink-connector-name} ?config={"source-rocketmq":"${runtime-ip}:${runtime-port}","source-cluster":"${broker-cluster}","connector-class":"org.apache.rocketmq.connect.http.sink.HttpSinkConnector","connect-topicname" : "${connect-topicname}","url":"${url}"}
例子
http://localhost:8081/connectors/httpConnectorSink?config={"source-rocketmq":"localhost:9876","source-cluster":"DefaultCluster", "connector-class":"org.apache.rocketmq.connect.http.sink.HttpSinkConnector","connect-topicname" : "http-topic","url":"192.168.1.2"}
注:
rocketmq-http-connect
的启动依赖于rocketmq-connect-runtime
项目的启动,需将打好的所有jar
包放置到runtime
项目中pluginPaths
配置的路径后再执行上面的启动请求,该值配置在runtime
项目下的connect.conf
文件中
http://${runtime-ip}:${runtime-port}/connectors/${rocketmq-http-connector-name}/stop
KEY | TYPE | Must be filled | Description | Example |
---|---|---|---|---|
url | String | YES | sink端 域名地址 | http://127.0.0.1 |
connect-topicname | String | YES | sink需要处理数据消息topic | xxxx |