Skip to content
This repository has been archived by the owner on Jan 7, 2020. It is now read-only.

Can't create stashes longer than a few days #301

Closed
dblessing opened this issue Apr 2, 2015 · 1 comment · Fixed by #317
Closed

Can't create stashes longer than a few days #301

dblessing opened this issue Apr 2, 2015 · 1 comment · Fixed by #317
Labels
Milestone

Comments

@dblessing
Copy link

To be honest, I'm not sure if this is a Sensu or Uchiwa issue. Now that Uchiwa supports custom stash expiration time I've noticed I can't create a stash longer than a few days. I grabbed some sensu api logs and noticed a weird exponent for expires value when a stash of a week or longer is created.

{"timestamp":"2015-04-02T17:36:15.670313-0500","level":"info","message":"POST /stashes","remote_address":"127.0.0.1","user_agent":"Go 1.1 package http","request_method":"POST","request_uri":"/stashes","request_body":"{\"content\":{\"reason\":\"\",\"source\":\"uchiwa\",\"timestamp\":1.428014174e+09},\"expire\":2.592e+06,\"path\":\"silence/client.example.com\"}\n\n"}

Notice 2.592e+06 in expires. When a stash is successfully created the expires value is something like 259200.

Uchiwa logs simply say

{"Date":"2015-04-02T17:41:29.823510151-05:00","Level":"warning","Src":{"Func":"github.com/sensu/uchiwa/uchiwa.CreateStash","Line":16},"Output":"API call to \"http://localhost:4567/stashes\" returned: 400 Bad Request"}

There were no other helpful logs when this error occured.

@palourde
Copy link
Contributor

palourde commented Apr 7, 2015

Thanks @dblessing for reporting this issue, I was able to reproduce it easily.

I'll try to have a bug fix released as soon as possible.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants