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

Allow to set values for MaximumNumberOfResults and MaximumNumberOfEvents #242

Open
danilvoe opened this issue Feb 2, 2022 · 6 comments
Open
Labels
area/storage Related to storage feature New feature or request

Comments

@danilvoe
Copy link

danilvoe commented Feb 2, 2022

Describe the feature request

There is a need to store more monitoring data. In particular the event.

Why do you personally want this feature to be implemented?

It is required to have data for a longer period of time, when checking every minute, data is stored for a small period of time.

How long have you been using this project?

No response

Additional information

I understand why such numbers are indicated in these constants (MaximumNumberOfResults and MaximumNumberOfEvents), so it’s easier to implement the optional setting of these values. By default, you can leave 100 and 50. :)

@TwiN TwiN added the feature New feature or request label Feb 3, 2022
@mani9223-oss
Copy link
Contributor

@danilvoe What is the response time for you for this API api/v1/endpoints/statuses?page=1. Is it because of MaximumNumberOfResults? For me, it's taking more than 25 secs and fails at the end. I am using PSQL as my DB.
@TwiN Any reason for this slowness?

@TwiN
Copy link
Owner

TwiN commented Mar 1, 2022

@mani9223-oss It definitely shouldn't take that long. How many endpoints do you have?

@mani9223-oss
Copy link
Contributor

@TwiN I have 292 endpoints. What are the recommended hardware requirements for PSQL DB? I have increased my DB resources to 2vCPU (from 1vCPU) and 4GB RAM (from 2GB) and reduced maximumNumberOfResults to 10. So now it's 15 secs. But I still feel 15 secs is long.

@TwiN
Copy link
Owner

TwiN commented Mar 2, 2022

@mani9223-oss I'll try to see if I can replicate it on my end when I have some time, but if it really is that slow, then yeah that'll have to be fixed. Might need to finally implement endpoint paging (currently, only result paging is implemented).

In the meantime, you can try using memory instead of postgres as storage type - it'll be much faster; at the cost of persistence.

@juanfont
Copy link

juanfont commented Jul 5, 2022

@TwiN would you accept a PR making this fields configurable from the config.yml?

@TwiN
Copy link
Owner

TwiN commented Jul 6, 2022

@juanfont Sure! It'll also require some changes on the front-end.

You'll also probably have to use this and this to pass the parameter from the backend to the frontend so that the frontend knows how many pages there are.

@TwiN TwiN added the area/storage Related to storage label Feb 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/storage Related to storage feature New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants