Skip to content
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

Disable nodejs:10. #166

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,31 @@ jobs:

- name: Docker Images Cleanup
run: |
set -x
docker version
df -h
docker image ls
docker image rm $(docker image ls -q) -f
df -h

# We use the built in docker of the github action environment.
# Therefore the docker install step below is commented.
#
# With newer github action runners, the ./tools/travis/docker.sh does not
# work anymore. Switched to 'setup a pinned docker version' instead.
#- name: befor install -> docker.sh
# run: ./tools/travis/docker.sh
#- name: setup a pinned docker version
# run: |
# set -x
# cat /etc/docker/daemon.json || true
# curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
# sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
# sudo apt-get update
# apt list -a docker-ce
# sudo apt-get -y --allow-downgrades install docker-ce=5:20.10.14~3-0~ubuntu-jammy
# docker version
# cat /etc/docker/daemon.json || true

- name: befor install -> install python3-pip
run: sudo apt-get install -y python3-pip
Expand Down
6 changes: 3 additions & 3 deletions ansible/files/runtimes-nodeonly.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"This file describes the different languages (aka. managed action runtimes) supported by the system",
"as well as blackbox images that support the runtime specification.",
"Only actions with runtime families / kinds defined here can be created / read / updated / deleted / invoked.",
"Define a list of runtime families (example: 'nodejs') with at least one kind per family (example: 'nodejs:10').",
"Define a list of runtime families (example: 'nodejs') with at least one kind per family (example: 'nodejs:20').",
"Each runtime family needs a default kind (default: true).",
"When removing or renaming runtime families or runtime kinds from this file, preexisting actions",
"with the affected kinds can no longer be read / updated / deleted / invoked. In order to remove or rename",
Expand All @@ -16,11 +16,11 @@
"runtimes": {
"nodejs": [
{
"kind": "nodejs:10",
"kind": "nodejs:20",
"default": true,
"image": {
"prefix": "openwhisk",
"name": "action-nodejs-v10",
"name": "action-nodejs-v20",
"tag": "nightly"
},
"deprecated": false,
Expand Down
36 changes: 25 additions & 11 deletions ansible/files/runtimes.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"This file describes the different languages (aka. managed action runtimes) supported by the system",
"as well as blackbox images that support the runtime specification.",
"Only actions with runtime families / kinds defined here can be created / read / updated / deleted / invoked.",
"Define a list of runtime families (example: 'nodejs') with at least one kind per family (example: 'nodejs:10').",
"Define a list of runtime families (example: 'nodejs') with at least one kind per family (example: 'nodejs:20').",
"Each runtime family needs a default kind (default: true).",
"When removing or renaming runtime families or runtime kinds from this file, preexisting actions",
"with the affected kinds can no longer be read / updated / deleted / invoked. In order to remove or rename",
Expand Down Expand Up @@ -36,31 +36,25 @@
"name": "action-nodejs-v8",
"tag": "nightly"
},
"deprecated": false,
"deprecated": true,
"attached": {
"attachmentName": "codefile",
"attachmentType": "text/plain"
}
},
{
"kind": "nodejs:10",
"default": true,
"default": false,
"image": {
"prefix": "openwhisk",
"name": "action-nodejs-v10",
"tag": "nightly"
},
"deprecated": false,
"deprecated": true,
"attached": {
"attachmentName": "codefile",
"attachmentType": "text/plain"
},
"stemCells": [
{
"count": 2,
"memory": "256 MB"
}
]
}
},
{
"kind": "nodejs:12",
Expand All @@ -75,6 +69,26 @@
"attachmentName": "codefile",
"attachmentType": "text/plain"
}
},
{
"kind": "nodejs:20",
"default": true,
"image": {
"prefix": "openwhisk",
"name": "action-nodejs-v20",
"tag": "nightly"
},
"deprecated": false,
"attached": {
"attachmentName": "codefile",
"attachmentType": "text/plain"
},
"stemCells": [
{
"count": 2,
"memory": "256 MB"
}
]
}
],
"python": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class KamonRecorderTests extends KafkaSpecBase with BeforeAndAfterEach with Kamo
val namespaceGuest = "guest"
val actionWithCustomPackage = "apimgmt/createApi"
val actionWithDefaultPackage = "createApi"
val kind = "nodejs:10"
val kind = "nodejs:default"
val memory = 256

it should "push user events to kamon" in {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class PrometheusRecorderTests extends KafkaSpecBase with BeforeAndAfterEach with
val namespaceGuest = "guest"
val actionWithCustomPackage = "apimgmt/createApiOne"
val actionWithDefaultPackage = "createApi"
val kind = "nodejs:10"
val kind = "nodejs:default"
val memory = "256"

it should "push user events to kamon" in {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,11 +176,11 @@ object StandaloneOpenWhisk extends SLF4JLogging {
| "runtimes": {
| "nodejs": [
| {
| "kind": "nodejs:10",
| "kind": "nodejs:20",
| "default": true,
| "image": {
| "prefix": "openwhisk",
| "name": "action-nodejs-v10",
| "name": "action-nodejs-v20",
| "tag": "latest"
| },
| "deprecated": false,
Expand Down
2 changes: 1 addition & 1 deletion core/standalone/waitready
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ wsk property set --apihost "http://$(hostname):3233" --auth "$AUTH"
until wsk action list 2>/dev/null >/dev/null
do sleep 1 ; echo server still not ready - retrying
done
wsk action update testme <(echo 'function main(){return {"ready":true}}') --kind nodejs:10
wsk action update testme <(echo 'function main(){return {"ready":true}}') --kind nodejs:20
until wsk action invoke testme -r 2>/dev/null | grep 'ready'
do sleep 1 ; echo server initializing...
done
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class DockerContainerFactoryTests

it should "set the docker run args based on ContainerArgsConfig" in {

val image = ExecManifest.runtimesManifest.manifests("nodejs:10").image
val image = ExecManifest.runtimesManifest.manifests("nodejs:20").image

implicit val tid = TransactionId.testing
val dockerApiStub = mock[DockerApiWithFileAccess]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -279,22 +279,22 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
// String: binary: true, main: jsMain
val jsAction1 = WhiskAction(namespace, aname(), jsDefault("RHViZWU=", Some("jsMain")))
val jsAction1Content =
Map("exec" -> Map("kind" -> NODEJS10, "code" -> "RHViZWU=", "main" -> "jsMain")).toJson.asJsObject
Map("exec" -> Map("kind" -> NODEJS20, "code" -> "RHViZWU=", "main" -> "jsMain")).toJson.asJsObject
val jsAction1ExecMetaData = js10MetaData(Some("jsMain"), true)

// String: binary: false, main: jsMain
val jsAction2 = WhiskAction(namespace, aname(), jsDefault("", Some("jsMain")))
val jsAction2Content = Map("exec" -> Map("kind" -> NODEJS10, "code" -> "", "main" -> "jsMain")).toJson.asJsObject
val jsAction2Content = Map("exec" -> Map("kind" -> NODEJS20, "code" -> "", "main" -> "jsMain")).toJson.asJsObject
val jsAction2ExecMetaData = js10MetaData(Some("jsMain"), false)

// String: binary: true, no main
val jsAction3 = WhiskAction(namespace, aname(), jsDefault("RHViZWU="))
val jsAction3Content = Map("exec" -> Map("kind" -> NODEJS10, "code" -> "RHViZWU=")).toJson.asJsObject
val jsAction3Content = Map("exec" -> Map("kind" -> NODEJS20, "code" -> "RHViZWU=")).toJson.asJsObject
val jsAction3ExecMetaData = js10MetaData(None, true)

// String: binary: false, no main
val jsAction4 = WhiskAction(namespace, aname(), jsDefault(""))
val jsAction4Content = Map("exec" -> Map("kind" -> NODEJS10, "code" -> "")).toJson.asJsObject
val jsAction4Content = Map("exec" -> Map("kind" -> NODEJS20, "code" -> "")).toJson.asJsObject
val jsAction4ExecMetaData = js10MetaData(None, false)

// Sequence
Expand Down Expand Up @@ -578,7 +578,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
action.limits,
action.version,
action.publish,
action.annotations ++ systemAnnotations(NODEJS10)))
action.annotations ++ systemAnnotations(NODEJS20)))
}
}

Expand Down Expand Up @@ -695,7 +695,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
deleteAction(action.docid)
status should be(OK)
val response = responseAs[WhiskAction]
response.exec.kind should be(NODEJS10)
response.exec.kind should be(NODEJS20)
response.parameters shouldBe Parameters()
}
}
Expand All @@ -714,7 +714,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
deleteAction(action.docid)
status should be(OK)
val response = responseAs[WhiskAction]
response.exec.kind should be(NODEJS10)
response.exec.kind should be(NODEJS20)
response.parameters should be(Parameters("a", "A"))
}
}
Expand Down Expand Up @@ -744,7 +744,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
action.limits,
action.version,
action.publish,
action.annotations ++ systemAnnotations(NODEJS10)))
action.annotations ++ systemAnnotations(NODEJS20)))
}
}

Expand Down Expand Up @@ -785,7 +785,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
action.limits,
action.version,
action.publish,
action.annotations ++ systemAnnotations(NODEJS10)))
action.annotations ++ systemAnnotations(NODEJS20)))
}
}

Expand All @@ -794,7 +794,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
val javaAction =
WhiskAction(namespace, aname(), javaDefault("ZHViZWU=", Some("hello")), annotations = Parameters("exec", "java"))
val nodeAction = WhiskAction(namespace, aname(), jsDefault("??"), Parameters("x", "b"))
val actions = Seq((javaAction, JAVA_DEFAULT), (nodeAction, NODEJS10))
val actions = Seq((javaAction, JAVA_DEFAULT), (nodeAction, NODEJS20))

actions.foreach {
case (action, kind) =>
Expand Down Expand Up @@ -898,7 +898,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
annotations = Parameters("exec", "java"))
val nodeAction = WhiskAction(namespace, aname(), jsDefault(nonInlinedCode(entityStore)), Parameters("x", "b"))
val bbAction = WhiskAction(namespace, aname(), bb("bb", nonInlinedCode(entityStore), Some("bbMain")))
val actions = Seq((javaAction, JAVA_DEFAULT), (nodeAction, NODEJS10), (bbAction, BLACKBOX))
val actions = Seq((javaAction, JAVA_DEFAULT), (nodeAction, NODEJS20), (bbAction, BLACKBOX))

actions.foreach {
case (action, kind) =>
Expand Down Expand Up @@ -1074,7 +1074,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
implicit val tid = transid()
val nodeAction = WhiskAction(namespace, aname(), jsDefault(nonInlinedCode(entityStore)), Parameters("x", "b"))
val bbAction = WhiskAction(namespace, aname(), bb("bb", nonInlinedCode(entityStore), Some("bbMain")))
val actions = Seq((nodeAction, NODEJS10), (bbAction, BLACKBOX))
val actions = Seq((nodeAction, NODEJS20), (bbAction, BLACKBOX))

actions.foreach {
case (action, kind) =>
Expand Down Expand Up @@ -1124,7 +1124,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
it should "concurrently get an action with attachment that is not cached" in {
implicit val tid = transid()
val action = WhiskAction(namespace, aname(), jsDefault(nonInlinedCode(entityStore)), Parameters("x", "b"))
val kind = NODEJS10
val kind = NODEJS20

val content = WhiskActionPut(
Some(action.exec),
Expand Down Expand Up @@ -1180,7 +1180,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
implicit val tid = transid()
val nodeAction = WhiskAction(namespace, aname(), jsDefault(nonInlinedCode(entityStore)), Parameters("x", "b"))
val bbAction = WhiskAction(namespace, aname(), bb("bb", nonInlinedCode(entityStore), Some("bbMain")))
val actions = Seq((nodeAction, NODEJS10), (bbAction, BLACKBOX))
val actions = Seq((nodeAction, NODEJS20), (bbAction, BLACKBOX))

actions.foreach {
case (action, kind) =>
Expand Down Expand Up @@ -1287,7 +1287,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
actionOldSchema.limits,
actionOldSchema.version.upPatch,
actionOldSchema.publish,
actionOldSchema.annotations ++ systemAnnotations(NODEJS10, create = false)))
actionOldSchema.annotations ++ systemAnnotations(NODEJS20, create = false)))
}

stream.toString should include regex (expectedPutLog)
Expand All @@ -1312,7 +1312,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
actionOldSchema.limits,
actionOldSchema.version.upPatch,
actionOldSchema.publish,
actionOldSchema.annotations ++ systemAnnotations(NODEJS10, create = false)))
actionOldSchema.annotations ++ systemAnnotations(NODEJS20, create = false)))
}
}

Expand Down Expand Up @@ -1358,7 +1358,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
content.limits.get.logs.get,
content.limits.get.concurrency.get),
version = action.version.upPatch,
annotations = action.annotations ++ systemAnnotations(NODEJS10, create = false)))
annotations = action.annotations ++ systemAnnotations(NODEJS20, create = false)))
}
}

Expand All @@ -1379,7 +1379,7 @@ class ActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
action.exec,
content.parameters.get,
version = action.version.upPatch,
annotations = action.annotations ++ systemAnnotations(NODEJS10, false)))
annotations = action.annotations ++ systemAnnotations(NODEJS20, false)))
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ class PackageActionsApiTests extends ControllerTestCommon with WhiskActionsApi {
action.limits,
action.version,
action.publish,
action.annotations ++ systemAnnotations(NODEJS10),
action.annotations ++ systemAnnotations(NODEJS20),
updated = response.updated))
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ class SequenceActionApiMigrationTests
deleteAction(action.docid)
status should be(OK)
val response = responseAs[WhiskAction]
response.exec.kind should be(NODEJS10)
response.exec.kind should be(NODEJS20)
response.parameters should be(Parameters("a", "A"))
}
},
Expand Down Expand Up @@ -155,7 +155,7 @@ class SequenceActionApiMigrationTests
deleteAction(action.docid)
status should be(OK)
val response = responseAs[WhiskAction]
response.exec.kind should be(NODEJS10)
response.exec.kind should be(NODEJS20)
response.parameters shouldBe Parameters()
}
},
Expand Down
Loading
Loading