-
Notifications
You must be signed in to change notification settings - Fork 400
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
Panic runtime error: invalid memory address or nil pointer dereference #558
Comments
👋 @matteotumiati can you share your ChartMuseum configuration (redacted if necessary)? Do you have Redis setup? |
These are all the environment variables set:
I don't have Redis unfortunately, but I tried attaching it during the weekend. I wasn't lucky enough to make it work though 😢 I tried other things in the meanwhile, like applying these settings:
But I have to be honest I don't know what these values mean. However with these settings and scaling the App Service Plan in Azure to a P3v2 instance, then it started working again. Is it possible that when you have 10k or more charts, then you need to scale resources? Is it because everything is loaded in memory therefore I may need more RAM? |
Interesting, so the error you posted above only can occur when an external cache is configured (Redis), Is that error happening without Redis configured or is there another error you came across before configuring Redis? Just based on the error before the panic, it looks like your ChartMuseum container was unable to connect to Redis for some reason:
|
I don't know if I have the logs before trying to configure Redis, unfortunately. |
There should definitely be data stored in Redis if it’s configured. You mentioned in the issue:
but it looks like the logs you provided are related to using Redis, did your configuration change to cause that error? |
That's correct. Everything was working fine initially, but at some point something broke without any explanation because no-one touched that environment and our team was not able to access CM anymore. We then tried to recover customizing some parameters and then by including Redis, all unsuccessful. In the end I was able to set some other parameters (the ones I added above) and scaled to a bigger instance (with more memory/CPU) to make it work again. I have this feeling though that the configuration I applied or scaling is just a temporary workaround and not something solid I should consider for production. |
Ah thanks for the additional context! You can read about CACHE_INTERVAL in the docs. Setting that option can definitely help with performance when you have a large number of charts. DEPTH=0 is the default for that configuration so that won’t really have much affect in terms of performance. By disabling statefiles, you might get some performance gains but lose any index caching unless you are using Redis. But without logs/debug logs it will be hard to pinpoint exactly what’s going on. As for the issues with Redis, I was able to sucessfully use redis locally. Did you have any networking contraints between chartmuseum and Redis? (policies, firewalls, security groups, etc) |
I do not, everything is deployed quite simply from Azure and I'm only using PaaS services. Do you mind if I keep this issue open while I try a bit more with Redis and see if it replicates again? |
@matteotumiati were you able to reproduce this issue? |
@matteotumiati any updates here? |
I have a chartmuseum instance deployed into Azure App Service using Docker container (image v0.14.0).
The App Service is referencing a Blob Storage where all the charts are saved, however recently we started facing this error:
It means that up until few days ago everything was fine, I was able to publish/download charts, then something started to break unexpectedly and now I cannot even read whatever is there.
If I look at the index-cache.yaml file, it is empty. The site cannot load and I only see an error message coming from the server:
The text was updated successfully, but these errors were encountered: