Skip to content

Unable to post message on HTTP REST URL #15

@aniruddha-github

Description

@aniruddha-github

Using Java code to put message on HTTP REST Kafka server. TCP Monitor captured request details
as below

POST /message HTTP/1.1
Content-Type: application/json
User-Agent: Java/1.7.0_55
Host: localhost:8080
Accept: text/html, image/gif, image/jpeg, ; q=.2, */; q=.2
Connection: keep-alive
Content-Length: 45

topic=topic1
message={"item":"pen", "Qty":3}

getting http response as

HTTP/1.1 400 Bad Request
Date: Sun, 14 Jun 2015 12:09:02 GMT
Content-Type: application/json
Transfer-Encoding: chunked

Any clue what is missing ?

Also how to assing port other than 8080 ?

Thanks in advance

Apparently no erros in Kafka server logs or zookeeper logs on console

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions