Projects tigase _server tigase-http-api Issues #17
NPE during REST API call (#17)
Closed
Artur Hefczyc opened 10 years ago
Due Date
2015-01-09

details on the forums: message#3983

Artur Hefczyc commented 10 years ago

Andrzej, please also take a look and provide some comments about the user's installation. Maybe there is some problem with config or something else which causes the NPE: message#3983

Andrzej Wójcik (Tigase) commented 10 years ago

I found out that cause of this issue was not sending Stats level as FINEST by API script, but it was missed as every time I execute this request it was working fine. Now I added it to request sent by API scrit. But my requests used for testing of this feature were always executed after other/manual request from XMPP client, which sent Stats level as @FINEST@, so questions is:

  1. Should this value be cached between requests by component?

  2. Should this be cached for everyone or for each user? (now is for every one which may lead to race condition in rare cases)

I would suggest to remove storing value of Stats level between requests (even not requests of same user, possible race condition) in field of component to remove possible race condition and to make each request for statistics using adhoc request statless, which would help testing this feature in future.

Artur Hefczyc commented 10 years ago

I think it does not have to be cached at all, as in theory each request (a correct request) should contain LEVEL value anyway. In fact I find the fact that it cashes LEVEL a bit problematic in some cases.

However, I think, that there should be a default level used in case the request does not contain LEVEL value. As far as I remember this may happen when you double click on the stats component from service discovery in Psi.

Artur Hefczyc commented 10 years ago

The default level should be INFO.

Andrzej Wójcik (Tigase) commented 10 years ago

I fixed overwritting default value of Stats Level which was of level INFO only during first execution of adhoc command.

issue 1 of 1
Type
Bug
Priority
Normal
Assignee
RedmineID
2594
Issue Votes (0)
Watchers (0)
Reference
tigase/_server/tigase-http-api#17
Please wait...
Page is in error, reload to recover