pritidesai commented on issue #681: proper handling of 'default' package name
URL: 
https://github.com/apache/incubator-openwhisk-wskdeploy/issues/681#issuecomment-360298242
 
 
   As package `default` is a reserved package name, when we invoke `wskdeploy` 
with this kind of manifest:
   
   ```
   packages:
      default:
         actions:
           # helloworld action in NodeJS
           helloNodejs:
             function: actions/hello.js
   ...
   ```
   It fails with:
   
   ```
   ./wskdeploy -p tests/src/integration/helloworld/
   ...
   Error: Deployment did not complete sucessfully. Run `wskdeploy undeploy` to 
remove partially deployed assets.
   Error: servicedeployer.go [1499]: [ERROR_WHISK_CLIENT_ERROR]: Error code: 
144: Package name 'default' is reserved. (code 26402220): HTTP Response Status: 
400 Bad Request HTTP Response Body: {"error":"Package name 'default' is 
reserved.","code":26402220}
   ```
   
   We have to add support for this kind of manifest where package name is set 
to `default` and create all entities from the manifest file directly under 
namespace. To support this, add a check before creating package, if package 
name is set to `default`, skip package creation and reflect it in every entity 
creation requests. Instead of sending PUT request to 
`namespaces/guest/actions/default/helloNodejs?overwrite=true` send it to 
`namespaces/guest/actions/helloNodejs?overwrite=true`
   
   
   
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to