logo

Are you need IT Support Engineer? Free Consultant

Composable storefront issues for JDK21 upgrade

  • By Sanjay
  • 31/05/2026
  • 18 Views


Following SAP Commerce Cloud upgrade policy , its essentials for customers to migrate to JDK 21.

There are multiple blogs , help document to bring you upto the speed on this upgrade & help you resolve common issues.

https://help.sap.com/docs/SAP_COMMERCE_CLOUD_PUBLIC_CLOUD/75d4c3895cb346008545900bffe851ce/9efd1f621…

https://community.sap.com/t5/crm-and-cx-blog-posts-by-sap/building-a-custom-login-page-for-sap-comme…

https://community.sap.com/t5/crm-and-cx-blog-posts-by-sap/sap-cc-jdk-21-upgrade/ba-p/14282138

https://help.sap.com/docs/SAP_COMMERCE_COMPOSABLE_STOREFRONT/eaef8c61b6d9477daf75bff9ac1b7eb4/7e237c…

 

I would go through some of the issues I have faced from CS pov during this upgrade. 
You are  on jdk21 & custom login page is enabled.

1. Infinite loop on Login 

Issue

On click of login your storefront goes into an infinite loop

Infinite Loopinfinite loop

 

 

 

 

 

Reason

You have defined a custom routing for login page as below

    provideConfig({
      routing: {
        routes: {
          login: {
            paths: ['login'],
            protected: false,
            authFlow: true,
          },
        },
      },
    }),
Solution
  • Post jdk21 upgrade , default login path is ‘sign-in'
  • Remove/adjust your routing path 
  • Check standard code for the login route

2.  After login , user is again is redirected back to login page

Issue
  • Post logon details are filled & login is clicked , nothing happens.
  • No API failure detected in network

Issue 2.Gif 

Reason
  • You have made custom implementation of class OAuthLibWrapperService & overridden tryLogin method like below
    override tryLogin(): Promise {
    return new Promise((resolve) => {
      resolve({
        result: false,
        tokenReceived: false,
      });
    });
  }
Solution 
  • Check standard implementation of class OAuthLibWrapperService
  • tokenReceived & result should not be hardcoded.
  • token Received means if a user has completed a login redirect

3. Login failed

Issue
  • On click of login you get an error angular-oauth2-oidc – Error performing ${grantType} flow 

K_Rituraj_0-1780246602147.Png

  • In network tab token call is still taking old parameters as payload

K_Rituraj_1-1780246689878.Png

Reason
  • You have a custom implementation of login form component module & template is overridden.
  • OOTB login form component utilize nativeForm concept to enable form submit
  • Check login method of OOTB LoginFormComponentService
Solution
  • Revisit your template implementation 
  • Add view child decorator #loginForm. Check OOTB login-form.component.html

K_Rituraj_2-1780247147393.Png

Cheers

K Rituraj

P.S- I would keep on updating list as I would encounter them



Source link

Leave a Reply

Your email address will not be published. Required fields are marked *