on 2020 Jul 16 6:39 AM
Hi All,
I have a trial account. I have created a MTA Project in WEB IDE and consume Northwind data through Destination. This has been working fine in NEO. But after deploying this app to SAP Cloud Foundry, it shows the destination error (404 Not Found).
Please check the details below:
Creation of Project:
Then select "SAPUI5 Application".
manifest.json:
Destination:
Also created the same Destination with the same name at Cloud Foundry.
xs-security.json:
{
"xsappname": "mta_myDemo",
"tenant-mode": "dedicated",
"description": "Security profile of called application",
"role-templates": [
{
"name": "Token_Exchange",
"description": "UAA",
"scope-references": [
"uaa.user"
]
}
]
}
xs-app.json:
{
"welcomeFile": "/index.html",
"authenticationMethod": "route",
"logout": {
"logoutEndpoint": "/do/logout"
},
"routes": [
{
"source": "^(.*)$",
"target": "$1",
"service": "html5-apps-repo-rt",
"authenticationType": "xsuaa"
}
]
}
package.json:
{
"name": "myDemo",
"version": "0.0.1",
"description": "",
"devDependencies": {
"@ui5/cli": "1.13.0",
"@sap/ui5-builder-webide-extension": "1.0.x"
},
"scripts": {
"build": "ui5 build --clean-dest --include-task=generateManifestBundle generateCachebusterInfo"
},
"ui5": {
"dependencies": [
"@sap/ui5-builder-webide-extension"
]
}
}
mta.yaml:
ID: mta_myDemo
_schema-version: '2.1'
parameters:
deploy_mode: html5-repo
version: 0.0.1
modules:
- name: mta-mydemo-approuter
type: approuter.nodejs
path: mta-mydemo-approuter
parameters:
disk-quota: 256M
memory: 256M
requires:
- name: mta_myDemo_html5_repo_runtime
- name: uaa_mta_myDemo
- name: mta_myDemo_ui_deployer
type: com.sap.html5.application-content
path: mta_myDemo_ui_deployer
requires:
- name: mta_myDemo_html5_repo_host
build-parameters:
requires:
- name: myDemo
artifacts:
- './*'
target-path: resources/myDemo
- name: myDemo
type: html5
path: myDemo
build-parameters:
builder: custom
commands:
- npm install
- npm run build
supported-platforms: []
build-result: dist
resources:
- name: mta_myDemo_html5_repo_runtime
parameters:
service-plan: app-runtime
service: html5-apps-repo
type: org.cloudfoundry.managed-service
- name: mta_myDemo_html5_repo_host
parameters:
service-plan: app-host
service: html5-apps-repo
type: org.cloudfoundry.managed-service
- name: uaa_mta_myDemo
parameters:
path: ./xs-security.json
service-plan: application
service: xsuaa
type: org.cloudfoundry.managed-service
- name: dest_mta_myDemo
parameters:
service-plan: lite
service: destination
type: org.cloudfoundry.managed-service
NEO-success:
Cloud Foundry error:
Need help on this issue.
Thanks,
Prasun
I think you’re missing the route tinhoudend destination in the Xs-app.json file.
This tutorial from mariusobert might help you as well: https://developers.sap.com/tutorials/sapui5-webide-setup-datasource.html
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi prasun_k, I'm facing the same issue. were you able to solve it?
valid URL - https://XXX-approuter.cfapps.eu10.hana.ondemand.com/V2/Northwind/Northwind.svc/$metadata
Invalid URL - https://XXX-approuter.cfapps.eu10.hana.ondemand.com/appname-1.0.0/V2/Northwind/Northwind.svc/$metada...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi prasun_k,
Since you're using the HTML5 repository on SAP Cloud Foundry, your app will run through the single point of entry => the approuter.
Did you check the xs-app.json of your approuter? Did you add a route that points to your destination there?
Example of what I'm using for one of my projects:
Best regards,
Geert-Jan Klaps
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
70 | |
10 | |
10 | |
10 | |
10 | |
8 | |
8 | |
7 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.