Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #3379 - added check for no fields in point #3405

Merged
merged 1 commit into from
Jul 21, 2015

Conversation

jhorwit2
Copy link
Contributor

#3379

Before, which caused panic

curl -i -XPOST 'http://localhost:8086/write?db=mydb' --data-binary 'cpu_load_short,host=server01,region=us-west'
curl: (52) Empty reply from server

after:

curl -i -XPOST 'http://localhost:8086/write?db=mydb' --data-binary 'cpu_load_short,host=server01,region=us-west'
HTTP/1.1 400 Bad Request
Request-Id: aecd185d-2f44-11e5-8001-000000000000
X-Influxdb-Version: 0.9
Date: Tue, 21 Jul 2015 01:06:14 GMT
Content-Length: 78
Content-Type: text/plain; charset=utf-8

unable to parse 'cpu_load_short,host=server01,region=us-west': missing fields

@otoolep
Copy link
Contributor

otoolep commented Jul 21, 2015

@jwilder

@jhorwit2
Copy link
Contributor Author

Another possible spot for this error is in the first if conditional in the for loop at the top of the function. That might be cleaner as there is already an if check on buf size.

@jhorwit2
Copy link
Contributor Author

Actually it's probably best where it's at just in case someone adds a premature break to that loop in the future.

@jwilder
Copy link
Contributor

jwilder commented Jul 21, 2015

👍 Thanks @jhorwit2

jwilder added a commit that referenced this pull request Jul 21, 2015
Fixes #3379 - added check for no fields in point
@jwilder jwilder merged commit 7ee7dfd into influxdata:master Jul 21, 2015
@jhorwit2 jhorwit2 deleted the jah/3379 branch July 21, 2015 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants