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

orion statistics issues : measuring_interval_in_secs not reset & /version requests considered as "invalidRequests" #4233

Closed
agaldemas-eridanis opened this issue Nov 11, 2022 · 5 comments
Labels
Milestone

Comments

@agaldemas-eridanis
Copy link

agaldemas-eridanis commented Nov 11, 2022

Bug description

A. if you 'DELETE' statistics, and you call again GET /statistics, measuring_interval_in_secs, remains at the same value as uptime_in_secs, instead of being reset to 0, the others sections are well reset.

B. if you perform a GET /version to orion, it is counted as an invalidRequests, and not as versionRequests, in statistics, nevertheless versionRequests appears in the response, but remains to 0.

  • Orion version: 3.6.0, used in NGSI-V2 !
  • MongoDB version 4.4.6
  • deployed on Kubernetes, image: fiware/orion:3.6.0

How to reproduce it
A. measuring_interval_in_secs not reset:

  1. delete statistics, and consult it
curl -iX DELETE 'http://localhost:1026/statistics'
curl -i 'http://localhost:1026/statistics'
  1. See in the request response, measuring_interval_in_secs value is the same as uptime_in_secs

B. /version request counted as invalidRequests, instead of versionRequests

  1. perform a GET /version request to orion
  2. perform a GET /statistics request to orion
  3. see in the results of statistics request:
{
    "counters": {
        ...
        "invalidRequests": 1,
        "versionRequests": 0
    }
...
}

Expected behavior
A. : measuring_interval_in_secs set to 0, when DELETE statistics (as specified in doc about statistics
B. : version request not counted as invalid requests in statistics.

@agaldemas-eridanis
Copy link
Author

agaldemas-eridanis commented Nov 11, 2022

just checked : the same issues exist in 3.7.0 !

important to take in count for next release, because without that it's hard to perform good detailed statistics about performances

@fgalan fgalan added this to the 3.8.0 milestone Dec 16, 2022
@fgalan
Copy link
Member

fgalan commented Dec 16, 2022

Fixed by PR #4248

@fgalan
Copy link
Member

fgalan commented Dec 16, 2022

@agaldemas-eridanis thanks for the report!

PR #4248 should fix the issue. It has been merged to master, so you could test telefonicaiot/fiware-orion:latest

Could you test and tell us if it is working now for you, please? Thanks!

@fgalan
Copy link
Member

fgalan commented Dec 21, 2022

@agaldemas-eridanis note also that after the merging of PR #4254 the request counter statistics system has been improved. The version counter is no longer using an specific versionRequests counter and has been aligned with the other requests. Now you would get the same information this way:

{
    "counters": {
        ...        
        "requests": {
            ...
            "/version": {
                "GET": 1
            }
            ...
        },

@fgalan
Copy link
Member

fgalan commented Jan 12, 2023

Orion 3.8.0 is has been released today, so we close this issue.

Of course, it could be re-opened if needed.

@fgalan fgalan closed this as completed Jan 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants