Open Farrrrland opened 1 year ago
I'm running on AWS EC2, will it be a problem?
You need to increase the nginx config and akka-http configuration. https://github.com/apache/openwhisk/blob/master/common/scala/src/main/resources/application.conf#L29 https://github.com/apache/openwhisk/pull/5279/files
You need to increase the nginx config and akka-http configuration. https://github.com/apache/openwhisk/blob/master/common/scala/src/main/resources/application.conf#L29 https://github.com/apache/openwhisk/pull/5279/files
@style95 Sorry about the late reply, but after changing those two files and set the limitition to ~100M, it still has the same output of request too large problem. I've recreated a KinD cluster and redeployed whisk but seems the problem still exists.
Shall I clean up anything else after changing the configurations?
Did you rebuild the images with those configurations?
@style95 Yes, I've restarted the whole process. But I was using helm install owdev ~/openwhisk-deploy-kube/helm/openwhisk -n openwhisk --create-namespace -f ~/openwhisk-deploy-kube/deploy/kind/mycluster.yaml
to install packages, which I believe modifiying configurations in openwhisk
folder does not changing the actual configuratins. In this case if I'm running with helm and with openwhisk-deploy-kube
, how can I change those configurations?
openwhisk has the hard 48mb attachment limit and i'm pretty sure that includes base64 encoding so the true limit is actually like a third lower
@bdoyle0182 Yes, actually this is the case I'm facing, I'm just wondering since deploying from source code can relax this limits by editing configurations, how can I do the same when deploying helm charts?
the 48mb limit is actually hard coded in code right now I'm pretty sure, how are you modifying it? it's the one thing that can't really be configured besides the 1mb payload limit
You can use the whisk.exec-size-limit
configuration to configure the max file size to be 0 to 48mb, but not larger.
From Exec.scala
:
val maxSize: ByteSize = 48.MB
val sizeLimit = loadConfigOrThrow[ByteSize](ConfigKeys.execSizeLimit)
require(
sizeLimit <= maxSize,
s"Executable code size limit $sizeLimit specified by '${ConfigKeys.execSizeLimit}' should not be more than max size of $maxSize")
@bdoyle0182 So I guess it is not actually a problem of nginx size limit but a size limit of packaged uploaded in openwhisk it self right? Let me see if decreasing the size settings in mycluster.yaml
will work.
Dom might be right here you are hitting a higher level limit first based on your error logs either with nginx configuration or an akka http configuration before actually entering the openwhisk create action route. Though once past that I think you may still hit the error I posted above for the package in question due to the base64 encoding putting it over 48mb, not 100% sure.
@style95 Things got weird here actually, I've tried to minimize nginx size limit in mycluster.yaml
and eventually found a package size of ~23M can still be successfully uploaded, I guess there might be some problems of the actual usage of mycluster.yaml
file following the instructions in customize-the-deployment?
This is how my configuration looks like:
whisk:
ingress:
type: NodePort
apiHostName: localhost
apiHostPort: 31001
useInternally: false
annotations:
nginx.ingress.kubernetes.io/proxy-body-size: "2m"
nginx:
httpsNodePort: 31001
# disable affinity
affinity:
enabled: false
toleration:
enabled: false
invoker:
options: "-Dwhisk.kubernetes.user-pod-node-affinity.enabled=false"
# must use KCF as kind uses containerd as its container runtime
containerFactory:
impl: "kubernetes"
@bdoyle0182 I guess there might be multiple limits here, however, I suspect there might be something wrong when customizing the deployment following the instructions, hopefully I did not miss any steps but I think mycluster.yaml
is not working in my case.
I think you should revised the openwhisk scala source code
@Farrrrland Did you try rebuilding the OpenWhisk source code after updating the Exec.scala
? If yes, then any issues faced while doing so?
Hi, I've found that OpenWhisk keep telling me the request size is too large when I try creating an action with zip file ~40MB large (base64 format will be ~52MB).
wsk action create gmm --kind python:3 --main media_meta get-media-meta.zip -i -v
The error looks like:
The file size is as follows:
I've changed
nginx.ingress.kubernetes.io/proxy-body-size: "100m"
when deploying but it seems not solving the problem. Smaller size zip files are working fine, but I'm not so sure how can I use a larger file to create my actions?