-
Notifications
You must be signed in to change notification settings - Fork 20
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
Add resource limits configuration capabilities for the chaincode pods #102
Comments
Defining resource limits definitely seems like a good idea. Configuration for the builder is done via environment variables since the chaincode package should be what is being deployed, not how it is deployed. Extra environment variables for everything you might want to configure in a pod doesn't seem like a good idea though. I'm wondering if using a ConfigMap might work, or if there is some other/better way to template pod configuration in kubernetes. |
@jt-nti one question: What is better, resource limits set by chaincode or all chaincodes runnning with the same resource limits? If all chaincodes will be using the same resouce limits, I prefer setting this in ENVIRONMENT VARIABLES. I know that we can use config maps, but, I prefer less K8S config points and we already have the environment variables. I think that a centralized configuration point is better for the builder adoption. If we want to have the resouce limits configured per chaincode, I think that the best location will be the image.json artifact file. Thoughts? |
Agreed, I think it does make sense to use environment variables. There are a few different options though:
Which do you think would make the most sense? I've opened #104 to explore how to handle different settings for different chaincode in the future. |
I think:
I think that It's easiear to handle and a more direct approach. A high level small/medium/large approach will have the need of a good documentation and explanation. Anyway, I prefer the first two approaches. BUT, any of the three options are good to go. |
how to control the Env variables value per the chaincode |
@davidfdr separate environment variables for cpu/memory requests/limits sound good to me
@labibfarag I've opened #104 to investigate this kind of requirement. At the moment you would need to install chaincode A and B on different peers to be able to configure a different namespace. |
The chaincode PODS don ´t have defined the resource limits.
Those limits can be configured in:
The text was updated successfully, but these errors were encountered: