[ECOMMERCE-581]  Magnolia freezes the UI for 5 minutes on connection timeout Created: 28/Jun/23  Updated: 30/Nov/23

Status: Open
Project: E-commerce
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Andrei Ichimescu Assignee: Andrei Ichimescu
Resolution: Unresolved Votes: 1
Labels: None
Remaining Estimate: 0d
Time Spent: 0.25d
Original Estimate: Not Specified

Issue Links:
Cloners
is cloned by ECOMMERCE-589 External eCommerce search suppliers s... Open
Relates
relates to ECOMMERCE-495 Sap - Set & Allow configure connectio... Closed
relates to MAGNOLIA-9054 Better progress feedback on long runn... Open
relation
is related to ECOMMERCE-587 The timeouts values for e-commerce co... Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:
Epic Link: AuthorX Maintenance
Story Points: 5
Team: AuthorX

 Description   

All e-commerce connectors are affected

Steps to reproduce

  1. Simulate a connection timeout (e.g: personal firewall or disable the internet connection)
  2. click on check connection or select product field

Expected results

  • The requests/connections are being tried for a decent amount of time
  • The UI is not getting blocked.

Actual results

 Magnolia freezes for 5 minutes

Workaround

Development notes  

Slack conversation: https://magnolia-cms.slack.com/archives/CDQMBJVV1/p1687955555000469

Connection timeout: https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-salesforce-connector/src/main/java/info/magnolia/ecommerce/salesforce/client/SalesforceHttpClient.java#63



 Comments   
Comment by Raphael Falvo [ 28/Jun/23 ]

Hello aichimescu 
I was about to create the same ticket

Let me add my 2 cents here:

Connection timeouts are not defined the same across the different connectors. Moreover, most of the connectors have a default connection timeout set to 5 minutes, which is far too long for a timeout.

Because of this 5 minutes timeout, when an e-commerce instance is not reachable, it freezes magnolia without having any way to unblock this. Opening a new tab doesn't help as the thread seems to be linked to the session. Only opening an incognito window with a new session lets the access to magnolia again.

SAP connector:
 - buildClient method is using the configurable connection and read timeout : https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-sap-connector/src/main/java/info/magnolia/ecommerce/sap/client/SapHttpClient.java#124

 -but generateToken method is still using the 5 minutes timeout : https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-sap-connector/src/main/java/info/magnolia/ecommerce/sap/client/SapHttpClient.java#303

Magento connector:

 - is using the 5 minutes timeout : https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-magento-connector/src/main/java/info/magnolia/ecommerce/magento/client/MagentoHttpClient.java#175

Salesforce connector:

 - is using the 5 minutes timeout : https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-salesforce-connector/src/main/java/info/magnolia/ecommerce/salesforce/client/SalesforceHttpClient.java#251

Commercetools:

 - Seems to use a timeout set to 3 minutes:

https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-commercetools-connector/src/main/java/info/magnolia/ecommerce/commercetools/SphereClient.java#35

https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-commercetools-connector/src/main/java/info/magnolia/ecommerce/commercetools/SphereClientProvider.java#76

It would be nice to have those timeouts harmonized across the different connectors, sticking to what has been done in SAP connector for example, with a default connection timeout set to 2 seconds and read timeout set to 10 seconds looks to be a reasonable option.

 

 

 

 

Comment by Mykola [ 19/Jul/23 ]

We are experiencing this behaviour also

Comment by Raphael Falvo [ 21/Jul/23 ]

Hey NDQ 
Which connector are you using ? Have you opened a SUPPORT ticket for it? Thanks

Comment by Mykola [ 23/Jul/23 ]

Magento
No, I have not opened SUPPORT ticket since this ticket already exists
thought that it's better to not multiply duplicates

Comment by Raphael Falvo [ 25/Jul/23 ]

Hi NDQ ,

Thank you for your response. I appreciate your consideration of this E-commerce ticket.

Creating a SUPPORT ticket in addition to that one will help us prioritize and resolve the issue faster. Your SUPPORT ticket will ensure that the right teams are aware of the impact on our valued customers.

Rest assured that team in charge of E-commerce module will actively collaborate with the SUPPORT team to expedite the resolution process.

Your cooperation in opening the SUPPORT ticket would be highly beneficial. If you have any questions or concerns, please feel free to share them, and I'll be glad to assist you.

Thank you for your understanding.

Generated at Mon Feb 12 01:45:26 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.