import ballerina/http;
import ballerinax/choreo as _;
service / on new http:Listener(9090) {
resource function get greeting() returns string|error {
final http:Client clientEndpoint = check new ("https://run.mocky.io/v3/164eda0f-9980-4aa1-9e09-94d8ac6ca6e0");
json resp = check clientEndpoint->get("/");
return "Resp: " + resp.toBalString();
}
}
And we used ballerina-c2c plugin to build the docker image.
When we try to run the container we got segmentation failure as follows.
ballerina: initializing connection with observability backend periscope.choreo.dev:443
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00000000000207f6, pid=7, tid=28
#
# JRE version: OpenJDK Runtime Environment Temurin-11.0.15+10 (11.0.15+10) (build 11.0.15+10)
# Java VM: OpenJDK 64-Bit Server VM Temurin-11.0.15+10 (11.0.15+10, mixed mode, tiered, compressed oops, g1 gc, linux-amd64)
# Problematic frame:
# C 0x00000000000207f6
#
# Core dump will be written. Default location: Core dumps may be processed with "/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -- %E" (or dumping to /home/ballerina/core.7)
#
# An error report file with more information is saved as:
# /home/ballerina/hs_err_pid7.log
#
# If you would like to submit a bug report, please visit:
# https://github.com/adoptium/adoptium-support/issues
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#