[ECOMMERCE-369] Investigation. SapConnectionValidator considers a connection as valid in cases when connection properties authUrl, username, password, clientId, clientSecret, imagePrefix are invalid. Created: 17/Mar/21 Updated: 26/Aug/22 |
|
| Status: | Open |
| Project: | E-commerce |
| Component/s: | None |
| Affects Version/s: | 1.2.3 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Neutral |
| Reporter: | Antonín Juran | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | Tech | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | 3d 3h | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Template: |
|
||||||||
| Acceptance criteria: |
[ ]*
Display "Connection failed" message on "Test connection" button click, when the connection properties are set with invalid values.
|
||||||||
| 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)
|
||||||||
| Date of First Response: | |||||||||
| Epic Link: | Commerce Improvements 1.3.x | ||||||||
| Story Points: | 5 | ||||||||
| Team: | |||||||||
| Description |
|
SapConnectionValidator considers a connection as valid in cases when connection properties authUrl, username, password, clientId, clientSecret, imagePrefix are invalid. How to reproduce:
|
| Comments |
| Comment by Michael Duerig [ 23/Mar/21 ] |
|
jalonso I noted that many of the properties of the connection configuration are not required when working against our sandbox. I.e. authUrl, username, password, clientId, clientSecret, (imagePrefix) can apparently all be changed to arbitrary values and we are still able to connect. Do you have more information about why those properties are needed and where they are actually used or whether this is just an artefact of the sandbox? |
| Comment by Jesus Alonso [ 23/Mar/21 ] |
|
All these properties are mandatories for obtaining the admin token (not the imagePrefix, which is needed for properly rendering the images). Unless something has been changed, I'd say there is some cache issue or something was wrong in the test. See https://git.magnolia-cms.com/projects/ADDON/repos/ecommerce/browse/magnolia-ecommerce-sap-connector/src/main/java/info/magnolia/ecommerce/sap/client/SapHttpClient.java#263 for details. For instance, if the authUrl is incorrect, obviously the request to obtain the token will fail. |