Forum Stats

  • 3,769,928 Users
  • 2,253,031 Discussions
  • 7,875,242 Comments

Discussions

Unable to invoke oracle cloud function

I am able to deploy my Spring boot application but unable to invoke it.

Error :- Error invoking function. status: 502 message: error receiving function response

Log message : - "Class ' com.xxx.applicationservice.MainApplication' not found in function jar. It's likely that the 'cmd' entry in func.yaml is incorrect.",

Yaml File :- schema_version: 20180708

name: function

version: 0.0.20

runtime: java

build_image: fnproject/fn-java-fdk-build:jdk11-1.0.116

run_image: fnproject/fn-java-fdk:jre11-1.0.116

cmd: com.xxx.applicationservice.MainApplication::main

Application Hierarchy : - com -> xxx -> applicationserivce->MainApplication

Main Class :-

package com.xxx.applicationservice;

import org.springframework.boot.SpringApplication;

import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication

public class MainApplication {

public static void main(String[] args) { SpringApplication.run(MainApplication.class, args);

}

}