diff --git a/examples/jvm/java/README.md b/examples/jvm/java/README.md index d099ac8f..52105df1 100644 --- a/examples/jvm/java/README.md +++ b/examples/jvm/java/README.md @@ -1,6 +1,6 @@ # Hello World in JVM/Java on Fission -The `io.fission.HelloWorld.java` class is a a very simple fission function that implements `io.fission.Function` and says "Hello, World!" . +The `io.fission.HelloWorld.java` class is a very simple fission function that implements `io.fission.Function` and says "Hello, World!" . ## Building and deploying using Fission @@ -57,5 +57,4 @@ $ fission fn create --name hello --deploy target/hello-world-1.0-SNAPSHOT-jar-wi $ fission route create --function hello --url /hellop --method GET $ fission fn test --name hello Hello World! - -``` \ No newline at end of file +``` diff --git a/examples/jvm/java/specs/env-java.yaml b/examples/jvm/java/specs/env-java.yaml new file mode 100644 index 00000000..f3bbb582 --- /dev/null +++ b/examples/jvm/java/specs/env-java.yaml @@ -0,0 +1,17 @@ +apiVersion: fission.io/v1 +kind: Environment +metadata: + creationTimestamp: null + name: java + namespace: default +spec: + builder: + command: build + image: fission/jvm-builder:1.7.1 + imagepullsecret: "" + keeparchive: true + poolsize: 3 + resources: {} + runtime: + image: fission/jvm-env:1.7.1 + version: 2 diff --git a/examples/jvm/java/specs/fission-deployment-config.yaml b/examples/jvm/java/specs/fission-deployment-config.yaml index 73c47424..753e349d 100644 --- a/examples/jvm/java/specs/fission-deployment-config.yaml +++ b/examples/jvm/java/specs/fission-deployment-config.yaml @@ -4,4 +4,4 @@ apiVersion: fission.io/v1 kind: DeploymentConfig name: java -uid: 3305cef5-21e6-4a55-b977-5c76ee62b0a6 +uid: 908a303a-bf23-4bae-a22c-b1db9a1f71a9 diff --git a/examples/jvm/java/specs/function-hello-java.yaml b/examples/jvm/java/specs/function-hello-java.yaml deleted file mode 100644 index 2b1268cd..00000000 --- a/examples/jvm/java/specs/function-hello-java.yaml +++ /dev/null @@ -1,52 +0,0 @@ -include: -- src/ -- pom.xml -kind: ArchiveUploadSpec -name: helloworld-java - ---- -apiVersion: fission.io/v1 -kind: Package -metadata: - creationTimestamp: null - name: helloworld-java-127w - namespace: default -spec: - deployment: - checksum: {} - environment: - name: java - namespace: default - source: - checksum: {} - type: url - url: archive://helloworld-java -status: - buildstatus: pending - ---- -apiVersion: fission.io/v1 -kind: Function -metadata: - creationTimestamp: null - name: hello-java - namespace: default -spec: - InvokeStrategy: - ExecutionStrategy: - ExecutorType: poolmgr - MaxScale: 1 - MinScale: 0 - TargetCPUPercent: 80 - StrategyType: execution - configmaps: null - environment: - name: java - namespace: default - package: - functionName: io.fission.HelloWorld - packageref: - name: helloworld-java-127w - namespace: default - resources: {} - secrets: null diff --git a/examples/jvm/java/specs/function-hello.yaml b/examples/jvm/java/specs/function-hello.yaml new file mode 100644 index 00000000..8188e5db --- /dev/null +++ b/examples/jvm/java/specs/function-hello.yaml @@ -0,0 +1,27 @@ +apiVersion: fission.io/v1 +kind: Function +metadata: + creationTimestamp: null + name: hello + namespace: default +spec: + InvokeStrategy: + ExecutionStrategy: + ExecutorType: poolmgr + MaxScale: 0 + MinScale: 0 + SpecializationTimeout: 120 + TargetCPUPercent: 0 + StrategyType: execution + configmaps: null + environment: + name: java + namespace: default + functionTimeout: 60 + package: + functionName: io.fission.HelloWorld + packageref: + name: hellojava + namespace: default + resources: {} + secrets: null diff --git a/examples/jvm/java/specs/package-hellojava.yaml b/examples/jvm/java/specs/package-hellojava.yaml new file mode 100644 index 00000000..0da0366c --- /dev/null +++ b/examples/jvm/java/specs/package-hellojava.yaml @@ -0,0 +1,26 @@ +include: +- src +- pom.xml +kind: ArchiveUploadSpec +name: src-URlE + +--- +apiVersion: fission.io/v1 +kind: Package +metadata: + creationTimestamp: null + name: hellojava + namespace: default +spec: + deployment: + checksum: {} + environment: + name: java + namespace: default + source: + checksum: {} + type: url + url: archive://src-URlE +status: + buildstatus: pending + lastUpdateTimestamp: "2020-01-29T09:43:56Z"