Closed fwpascual closed 4 years ago
I found that if I alter the generated build.gradle
file to better match what is shown here, that I can get the expected response.
Specifically, changing the runFunction
task from
args(
'--target', 'io.micronaut.gcp.function.http.HttpFunction',
'--classpath', (configurations.runtimeClasspath + sourceSets.main.output).asPath,
'--port', 8080
)
to
args(
'--target', 'io.micronaut.gcp.function.http.HttpFunction',
'--port', 8080
)
doFirst {
args('--classpath', files(configurations.runtimeClasspath, sourceSets.main.output).asPath)
}
Thanks for reporting an issue, please review the task list below before submitting the issue. Your issue report will be closed if the issue is incomplete and the below tasks not completed.
NOTE: If you are unsure about something and the issue is more of a question a better place to ask questions is on Stack Overflow (https://stackoverflow.com/tags/micronaut) or Gitter (https://gitter.im/micronautfw/). DO NOT use the issue tracker to ask questions.
Task List
Steps to Reproduce
mn create-app my-app --features google-cloud-function --lang kotlin
./gradlew runFunction
Expected Behaviour
Should see a message of "Example Response"
Actual Behaviour
Receive
{"message":"Not Found","_links":{"self":{"href":"/hello","templated":false}}}
Environment Information
Example Application
N/A: Reproducible using unmodified CLI project