This is an automated email from the ASF dual-hosted git repository.
csantanapr pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk.git
The following commit(s) were added to refs/heads/master by this push:
new f35e23a Add nodejs:10 to default set of runtimes for ansible/vagrant
(#4124)
f35e23a is described below
commit f35e23ae19b87bf6c3d27f579ca42a4da8ebb2b0
Author: Carlos Santana <[email protected]>
AuthorDate: Mon Nov 19 23:29:29 2018 -0500
Add nodejs:10 to default set of runtimes for ansible/vagrant (#4124)
---
ansible/files/runtimes.json | 14 +++++++++++++
.../src/main/resources/apiv1swagger.json | 1 +
docs/{actions-node.md => actions-nodejs.md} | 23 ++++++++++++++--------
docs/actions.md | 2 +-
docs/concurrency.md | 2 +-
tests/dat/actions/unicode.tests/nodejs-10.txt | 8 ++++++++
6 files changed, 40 insertions(+), 10 deletions(-)
diff --git a/ansible/files/runtimes.json b/ansible/files/runtimes.json
index 4ba560a..9bc28df 100644
--- a/ansible/files/runtimes.json
+++ b/ansible/files/runtimes.json
@@ -47,6 +47,20 @@
"attachmentName": "codefile",
"attachmentType": "text/plain"
}
+ },
+ {
+ "kind": "nodejs:10",
+ "default": false,
+ "image": {
+ "prefix": "openwhisk",
+ "name": "action-nodejs-v10",
+ "tag": "latest"
+ },
+ "deprecated": false,
+ "attached": {
+ "attachmentName": "codefile",
+ "attachmentType": "text/plain"
+ }
}
],
"python": [
diff --git a/core/controller/src/main/resources/apiv1swagger.json
b/core/controller/src/main/resources/apiv1swagger.json
index a2e6070..cefdb99 100644
--- a/core/controller/src/main/resources/apiv1swagger.json
+++ b/core/controller/src/main/resources/apiv1swagger.json
@@ -1891,6 +1891,7 @@
"java:default",
"nodejs:6",
"nodejs:8",
+ "nodejs:10",
"nodejs:default",
"php:7.1",
"php:7.2",
diff --git a/docs/actions-node.md b/docs/actions-nodejs.md
similarity index 95%
rename from docs/actions-node.md
rename to docs/actions-nodejs.md
index 7dfefbe..9ce26ee 100644
--- a/docs/actions-node.md
+++ b/docs/actions-nodejs.md
@@ -43,7 +43,7 @@ and demonstrate how to bundle multiple JavaScript files and
third party dependen
The CLI automatically infers the type of the action by using the source file
extension.
For `.js` source files, the action runs by using a Node.js runtime. You may
specify
- the Node.js runtime to use by explicitly specifying the parameter `--kind
nodejs:6` or `--kind nodejs:8`.
+ the Node.js runtime to use by explicitly specifying the parameter `--kind
nodejs:10`, `--kind nodejs:8`, or `--kind nodejs:6`
## Creating asynchronous actions
@@ -220,7 +220,7 @@ To create an OpenWhisk action from this package:
wsk action create packageAction --kind nodejs:6 action.zip
```
- When creating an action from a `.zip` archive with the CLI tool, you must
explicitly provide a value for the `--kind` flag by using `nodejs:6` or
`nodejs:8`.
+ When creating an action from a `.zip` archive with the CLI tool, you must
explicitly provide a value for the `--kind` flag by using `nodejs:10`,
`nodejs:8` or `nodejs:6`.
4. You can invoke the action like any other:
@@ -330,9 +330,9 @@ JavaScript actions can be executed in Node.js version 6 or
Node.js version 8.
Currently actions are executed by default in a Node.js version 6 environment.
### Node.js version 6 environment
-The Node.js 6.14.2 environment will be used for an action if the `--kind` flag
is explicitly specified with a value of 'nodejs:6' when creating/updating the
action.
+The Node.js 6.14.4 environment will be used for an action if the `--kind` flag
is explicitly specified with a value of 'nodejs:6' when creating/updating the
action.
-The following packages are available to be used in the Node.js 6.14.2
environment:
+The following packages are available to be used in the Node.js 6 environment:
- [apn v2.1.2](https://www.npmjs.com/package/apn) - A Node.js module for
interfacing with the Apple Push Notification service.
- [async v2.1.4](https://www.npmjs.com/package/async) - Provides functions for
working with asynchronous functions.
@@ -358,7 +358,7 @@ The following packages are available to be used in the
Node.js 6.14.2 environmen
- [node-uuid v1.4.7](https://www.npmjs.com/package/node-uuid) - Deprecated
UUID packaged.
- [nodemailer v2.6.4](https://www.npmjs.com/package/nodemailer) - Send e-mails
from Node.js – easy as cake!
- [oauth2-server v2.4.1](https://www.npmjs.com/package/oauth2-server) -
Complete, compliant, and well tested module for implementing an OAuth2
Server/Provider with express in Node.js.
-- [openwhisk v3.16.0](https://www.npmjs.com/package/openwhisk) - JavaScript
client library for the OpenWhisk platform. Provides a wrapper around the
OpenWhisk APIs.
+- [openwhisk v3.18.0](https://www.npmjs.com/package/openwhisk) - JavaScript
client library for the OpenWhisk platform. Provides a wrapper around the
OpenWhisk APIs.
- [pkgcloud v1.4.0](https://www.npmjs.com/package/pkgcloud) - pkgcloud is a
standard library for Node.js that abstracts away differences among multiple
cloud providers.
- [process v0.11.9](https://www.npmjs.com/package/process) -
Require('process'); just like any other module.
- [pug v2.0.0-beta6](https://www.npmjs.com/package/pug) - Implements the Pug
templating language.
@@ -387,11 +387,18 @@ The following packages are available to be used in the
Node.js 6.14.2 environmen
- [yauzl v2.7.0](https://www.npmjs.com/package/yauzl) - Yet another unzip
library for node. For zipping.
### Node.js version 8 environment
-The Node.js version 8.11.2 environment is used if the `--kind` flag is
explicitly specified with a value of 'nodejs:8' when creating or updating an
Action.
+The Node.js version 8.12.0 environment is used if the `--kind` flag is
explicitly specified with a value of 'nodejs:8' when creating or updating an
Action.
-The following packages are pre-installed in the Node.js version 8.11.2
environment:
+The following packages are pre-installed in the Node.js version 8 environment:
-- [openwhisk v3.16.0](https://www.npmjs.com/package/openwhisk) - JavaScript
client library for the OpenWhisk platform. Provides a wrapper around the
OpenWhisk APIs.
+- [openwhisk v3.18.0](https://www.npmjs.com/package/openwhisk) - JavaScript
client library for the OpenWhisk platform. Provides a wrapper around the
OpenWhisk APIs.
+
+### Node.js version 10 environment
+The Node.js version 10.13.0 environment is used if the `--kind` flag is
explicitly specified with a value of 'nodejs:10' when creating or updating an
Action.
+
+The following packages are pre-installed in the Node.js version 10 environment:
+
+- [openwhisk v3.18.0](https://www.npmjs.com/package/openwhisk) - JavaScript
client library for the OpenWhisk platform. Provides a wrapper around the
OpenWhisk APIs.
### Packaging npm packages with your actions
For any `npm` packages that are not pre-installed in the Node.js environment,
you can bundle them as dependencies when you create or update your action.
diff --git a/docs/actions.md b/docs/actions.md
index c13e2bd..b181ad6 100644
--- a/docs/actions.md
+++ b/docs/actions.md
@@ -56,7 +56,7 @@ paths more suitable. Or, you can [create a new
runtime](actions-new.md).
* [Go](actions-go.md)
* [Java](actions-java.md)
-* [JavaScript](actions-node.md)
+* [JavaScript](actions-nodejs.md)
* [PHP](actions-php.md)
* [Python](actions-python.md)
* [Ruby](actions-ruby.md)
diff --git a/docs/concurrency.md b/docs/concurrency.md
index 2b9dcf3..2d701c0 100644
--- a/docs/concurrency.md
+++ b/docs/concurrency.md
@@ -29,7 +29,7 @@ Concurrent activation processing within the same action
container can be enabled
* enable the akka http client at invoker config
* e.g. CONFIG_whisk_containerPool_akkaClient=true
-* use a kind that supports concurrency (currently only nodejs:6 and nodejs:8)
+* use a kind that supports concurrency (currently only `nodejs:10`, `nodejs:8`
and `nodejs:6`)
* enable concurrency at runtime container env (nodejs container only allows
concurrency when started with an env var __OW_ALLOW_CONCURRENT=true)
* e.g.
CONFIG_whisk_containerFactory_containerArgs_extraArgs_env_0="__OW_ALLOW_CONCURRENT=true"
* disable log collection at invoker
diff --git a/tests/dat/actions/unicode.tests/nodejs-10.txt
b/tests/dat/actions/unicode.tests/nodejs-10.txt
new file mode 100644
index 0000000..4db30ea
--- /dev/null
+++ b/tests/dat/actions/unicode.tests/nodejs-10.txt
@@ -0,0 +1,8 @@
+// Licensed to the Apache Software Foundation (ASF) under one or more
contributor
+// license agreements; and to You under the Apache License, Version 2.0.
+
+function main(args) {
+ var str = args.delimiter + " ☃ " + args.delimiter;
+ console.log(str);
+ return { "winter": str };
+}