Skip to Content
0
Jan 27, 2022 at 01:11 AM

CAP Java Multitenant MTA with Portal service UI gets 500 error upon redirect

353 Views Last edit Jan 27, 2022 at 01:16 AM 3 rev

Hi all,

I am facing problem in setting up multi tenant Portal service. I am getting

"msg":"GET request to /cp.portal/site completed with status 500 Request failed with status code 401"}

I am able to access the html5 UI directly /app/index.html, I am even able to access the backend service apis from consumer subscribed application. Only from portal service /cp.portal/site I am getting 401 error.

I have configured the routes in approuter xs-app.json

 
{
"welcomeFile": "/cp.portal",
"authenticationMethod": "route",
"routes": [
{
"source": "^/app/(.*)$",
"cacheControl": "no-cache, no-store, must-revalidate",
"target": "$1",
"authenticationType": "xsuaa",
"localDir": "./"
},
{
"source": "^/odata/(.*)$",
"target": "/odata/$1",
"destination": "backend",
"csrfProtection": false
},
{
"source": "^/webapp(.*)$",
"target": "$1",
"service": "html5-apps-repo-rt",
"authenticationType": "xsuaa"
},
{
"source": "^(/applications/.*)$",
"target": "$1",
"service": "html5-apps-repo-rt",
"authenticationType": "xsuaa"
},
{
"source": "^(.*)$",
"target": "$1",
"service": "html5-apps-repo-rt",
"authenticationType": "xsuaa"
}
]
}

I can share code as needed, any guidance is appreciated!