on 2023 Apr 24 2:46 PM
I´ve followed the tutorial series Create a Full-Stack App with SAP HANA Cloud, CAP, and SAP Fiori Elements.
I´ve finished all steps up to Deploy Your Application with Access Control step 7 with my trial account.
The app is working fine when I run it in Business Application Studio:
But in the deployment step 7 an error is displayed. Screenshot of my last retry:
Part of the downloaded log:
#2.0#2023 04 24 06:52:17.064#Z#ERROR#com.sap.cloud.lm.sl.xs2.079390d5-e26c-11ed-94fc-eeee0a8c021d.OPERATION.startAppTask#
######org.cloudfoundry.multiapps.controller.persistence.services.ProcessLogger########flowable-async-job-executor-thread-3955###
Exception caught#
org.cloudfoundry.multiapps.common.SLException: A step of the process has failed. Retrying it may solve the issue.
at org.cloudfoundry.multiapps.controller.process.steps.SyncFlowableStep.executeInternal(SyncFlowableStep.java:77) ~[multiapps-controller-process-1.152.0.jar:?]
at org.cloudfoundry.multiapps.controller.process.steps.SyncFlowableStep.lambda$execute$0(SyncFlowableStep.java:65) ~[multiapps-controller-process-1.152.0.jar:?]
at org.cloudfoundry.multiapps.controller.core.util.LoggingUtil.logWithCorrelationId(LoggingUtil.java:14) ~[multiapps-controller-core-1.152.0.jar:?]
at org.cloudfoundry.multiapps.controller.process.steps.SyncFlowableStep.execute(SyncFlowableStep.java:65) ~[multiapps-controller-process-1.152.0.jar:?]
at org.flowable.engine.impl.delegate.invocation.JavaDelegateInvocation.invoke(JavaDelegateInvocation.java:35) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.delegate.invocation.DelegateInvocation.proceed(DelegateInvocation.java:32) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.delegate.invocation.DefaultDelegateInterceptor.handleInvocation(DefaultDelegateInterceptor.java:26) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.bpmn.behavior.ServiceTaskDelegateExpressionActivityBehavior.execute(ServiceTaskDelegateExpressionActivityBehavior.java:157) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.agenda.ContinueProcessOperation.executeActivityBehavior(ContinueProcessOperation.java:313) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.agenda.ContinueProcessOperation.executeSynchronous(ContinueProcessOperation.java:170) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.agenda.ContinueProcessOperation.continueThroughFlowNode(ContinueProcessOperation.java:125) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.agenda.ContinueProcessOperation.run(ContinueProcessOperation.java:88) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.common.engine.impl.AbstractEngineConfiguration.lambda$new$0(AbstractEngineConfiguration.java:173) ~[flowable-engine-common-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.interceptor.CommandInvoker.executeOperation(CommandInvoker.java:97) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.interceptor.CommandInvoker.executeOperations(CommandInvoker.java:81) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.interceptor.CommandInvoker.execute(CommandInvoker.java:64) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.engine.impl.interceptor.BpmnOverrideContextInterceptor.execute(BpmnOverrideContextInterceptor.java:26) ~[flowable-engine-6.6.0.jar:6.6.0]
at org.flowable.common.engine.impl.interceptor.TransactionContextInterceptor.execute(TransactionContextInterceptor.java:53) ~[flowable-engine-common-6.6.0.jar:6.6.0]
at org.flowable.common.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:83) ~[flowable-engine-common-6.6.0.jar:6.6.0]
at org.flowable.common.spring.SpringTransactionInterceptor.lambda$execute$0(SpringTransactionInterceptor.java:57) ~[flowable-spring-common-6.6.0.jar:6.6.0]
at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:140) [spring-tx-5.3.25.jar:5.3.25]
at org.flowable.common.spring.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:57) [flowable-spring-common-6.6.0.jar:6.6.0]
at org.flowable.common.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:30) [flowable-engine-common-6.6.0.jar:6.6.0]
at org.flowable.common.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:56) [flowable-engine-common-6.6.0.jar:6.6.0]
at org.flowable.common.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:51) [flowable-engine-common-6.6.0.jar:6.6.0]
at org.flowable.job.service.impl.asyncexecutor.ExecuteAsyncRunnable.executeJob(ExecuteAsyncRunnable.java:127) [flowable-job-service-6.6.0.jar:6.6.0]
at org.flowable.job.service.impl.asyncexecutor.ExecuteAsyncRunnable.run(ExecuteAsyncRunnable.java:115) [flowable-job-service-6.6.0.jar:6.6.0]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [?:?]
at java.lang.Thread.run(Unknown Source) [?:?]<br>
The app is displayed in my trial subaccount anyway:
But when I start it by clicking on "frontend", this error is displayed in a new tab:
Could someone please help me get the app running?
P.S.: My mta.yaml:
_schema-version: "3.1"
ID: MyHANAApp
description: A simple CAP project.
version: 1.0.0
modules:
- name: MyHANAApp-srv
type: nodejs
path: srv
requires:
- name: MyHANAApp-db
- name: uaa_MyHANAApp
provides:
- name: srv-api
properties:
srv-url: ${default-url}
parameters:
host: ${appname}
buildpack: nodejs_buildpack
build-parameters:
ignore: [".env", "./node_modules"]
builder: npm-ci
- name: MyHANAApp-db-deployer
type: hdb
path: db
requires:
- name: MyHANAApp-db
properties:
TARGET_CONTAINER: ~{hdi-container-name}
- name: cross-container-service-1
group: SERVICE_REPLACEMENTS
properties:
key: ServiceName_1
service: ~{the-service-name}
parameters:
ignore: [".env", "./node_modules"]
buildpack: nodejs_buildpack
- name: MyHANAApp-destination-content
type: com.sap.application.content
requires:
- name: MyHANAApp-destination-service
parameters:
content-target: true
- name: MyHANAApp_html_repo_host
parameters:
service-key:
name: MyHANAApp_html_repo_host-key
- name: uaa_MyHANAApp
parameters:
service-key:
name: uaa_MyHANAApp-key
parameters:
content:
instance:
destinations:
- Name: hana_app_MyHANAApp_html_repo_host
ServiceInstanceName: MyHANAApp-html5-app-host-service
ServiceKeyName: MyHANAApp_html_repo_host-key
sap.cloud.service: hana.app
- Authentication: OAuth2UserTokenExchange
Name: hana_app_uaa_MyHANAApp
ServiceInstanceName: MyHANAApp-xsuaa-service
ServiceKeyName: uaa_MyHANAApp-key
sap.cloud.service: hana.app
existing_destinations_policy: ignore
build-parameters:
no-source: true
- name: MyHANAApp-app-content
type: com.sap.application.content
path: .
requires:
- name: MyHANAApp_html_repo_host
parameters:
content-target: true
build-parameters:
build-result: resources
requires:
- artifacts:
- frontend.zip
name: frontend
target-path: resources/
- name: frontend
type: html5
path: app/frontend
build-parameters:
build-result: dist
builder: custom
commands:
- npm install
- npm run build:cf
supported-platforms: []
resources:
- name: MyHANAApp-db
type: com.sap.xs.hdi-container
parameters:
service: hana
service-plan: hdi-shared
properties:
hdi-container-name: ${service-name}
- name: cross-container-service-1
type: org.cloudfoundry.existing-service
parameters:
service-name: MyHANAApp-hdiMyHANAApp-db-deployer-ws-4dj97
properties:
the-service-name: ${service-name}
- name: MyHANAApp-destination-service
type: org.cloudfoundry.managed-service
parameters:
config:
HTML5Runtime_enabled: true
init_data:
instance:
destinations:
- Authentication: NoAuthentication
Name: ui5
ProxyType: Internet
Type: HTTP
URL: https://ui5.sap.com
- Name: hana-app-api
Authentication: NoAuthentication
ProxyType: Internet
HTML5.ForwardAuthToken: true
HTML5.DynamicDestination: true
Type: HTTP
URL: https://${appname}.${default-domain}
existing_destinations_policy: update
version: 1.0.0
service: destination
service-name: MyHANAApp-destination-service
service-plan: lite
- name: MyHANAApp_html_repo_host
type: org.cloudfoundry.managed-service
parameters:
service: html5-apps-repo
service-name: MyHANAApp-html5-app-host-service
service-plan: app-host
- name: uaa_MyHANAApp
type: org.cloudfoundry.managed-service
parameters:
path: ./xs-security.json
service: xsuaa
service-name: MyHANAApp-xsuaa-service
service-plan: application
parameters:
deploy_mode: html5-repo
enable-parallel-deployments: true
appname: unique-0b12e7ad
build-parameters:
before-all:
- builder: custom
commands:
- npx -p @sap/cds-dk cds build --production
Request clarification before answering.
Hey Matthias,
the only thing you have missed was https://developers.sap.com/tutorials/hana-cloud-cap-create-project.html - Step 5, where cds gets the configuration for the build process. (where the gen/ directory will end up and what needs to be built)
- the path in the mta.yaml was entirely right from the beginning:
modules:
- name: MyHANAApp-srv
type: nodejs
path: gen/srv
and the srv/package.json start command was also right:
"scripts": {
"start": "cds serve srv/csn.json"
}
let me know if it doesn't work for you, then I can further help troubleshooting. 🙂
meanwhile, I've created a Pull Request to your repo with the fixes (hope nothing went wrong along the way with formatting etc.) : https://github.com/huetterm/MyHANAApp/pull/1
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you very much. I must have missed Step 5, dispite the fact, that I have marked it as completed:-(
User | Count |
---|---|
93 | |
11 | |
9 | |
8 | |
7 | |
5 | |
4 | |
4 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.