Skip to content

Commit

Permalink
name changes
Browse files Browse the repository at this point in the history
  • Loading branch information
mikarinneoracle committed Feb 12, 2025
1 parent a7ed3da commit 5da910d
Show file tree
Hide file tree
Showing 10 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ RUN ["mvn", "package"]
FROM fnproject/fn-java-fdk:jre17-1.0.187
WORKDIR /function
COPY --from=build-stage /function/target/*.jar /function/app/
CMD ["com.example.HelloAIFunction::handleRequest"]
CMD ["com.example.fn.HelloFunction::handleRequest"]
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ RUN chmod 777 /config
RUN chmod 777 /oci_api_key.pem
RUN sed -i '/^key_file/d' /config
RUN echo "key_file = /oci_api_key.pem" >> /config
CMD ["com.example.HelloAIFunction::handleRequest"]
CMD ["com.example.fn.HelloFunction::handleRequest"]
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ RUN native-image \
-H:ReflectionConfigurationFiles=/app/reflection.json \
-Ob \
-H:Name=Hello \
-cp "/app/Helloaifunc-1.0-SNAPSHOT.jar:/app/lib/*" \
-cp "/app/Hellofunc-1.0-SNAPSHOT.jar:/app/lib/*" \
com.fnproject.fn.runtime.EntryPoint

FROM fnproject/fn-java-fdk:jre17-1.0.198 as fdk
Expand All @@ -17,4 +17,4 @@ FROM container-registry.oracle.com/os/oraclelinux:8-slim
COPY --from=native /app/Hello .
COPY --from=fdk /function/runtime/* ./
ENTRYPOINT [ "./Hello" ]
CMD [ "com.example.HelloAIFunction::handleRequest", "-Djava.library.path=/lib"]
CMD [ "com.example.fn.HelloFunction::handleRequest", "-Djava.library.path=/lib"]
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ version: 0.0.1
runtime: java
build_image: fnproject/fn-java-fdk-build:jdk17-1.0.187
run_image: fnproject/fn-java-fdk:jre17-1.0.187
cmd: com.example.HelloAIFunction::handleRequest
cmd: com.example.fn.HelloFunction::handleRequest
timeout: 120
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<modelVersion>4.0.0</modelVersion>

<groupId>org.example</groupId>
<artifactId>Helloaifunc</artifactId>
<artifactId>Hellofunc</artifactId>
<version>1.0-SNAPSHOT</version>

<build>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[
{
"name": "com.example.HelloAIFunction",
"name": "com.example.fn.HelloFunction",
"allDeclaredMethods": true,
"methods": [
{ "name": "<init>", "parameterTypes": [] }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Software and the Larger Work(s), and to sublicense the foregoing rights on
SOFTWARE.
*/

package com.example;
package com.example.fn;

import com.oracle.bmc.ClientConfiguration;
import com.oracle.bmc.ConfigFileReader;
Expand Down Expand Up @@ -69,7 +69,7 @@ Software and the Larger Work(s), and to sublicense the foregoing rights on
import java.util.*;
import java.text.*;

public class HelloAIFunction {
public class HelloFunction {

// FILL IN PROPER VALUES FOR OCI GENAI SERVICE
private static final String ENDPOINT = "https://inference.generativeai.eu-frankfurt-1.oci.oraclecloud.com";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ RUN ["mvn", "package"]
FROM fnproject/fn-java-fdk:jre17-1.0.187
WORKDIR /function
COPY --from=build-stage /function/target/*.jar /function/app/
CMD ["com.example.HelloFunction::handleRequest"]
CMD ["com.example.fn.HelloFunction::handleRequest"]
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ version: 0.0.1
runtime: java
build_image: fnproject/fn-java-fdk-build:jdk17-1.0.187
run_image: fnproject/fn-java-fdk:jre17-1.0.187
cmd: com.example.HelloFunction::handleRequest
cmd: com.example.fn.HelloFunction::handleRequest
timeout: 120
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Software and the Larger Work(s), and to sublicense the foregoing rights on
SOFTWARE.
*/

package com.example;
package com.example.fn;

public class HelloFunction {

Expand Down

0 comments on commit 5da910d

Please sign in to comment.