[
https://issues.apache.org/jira/browse/SLING-10925?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17445867#comment-17445867
]
Robert Munteanu commented on SLING-10925:
-----------------------------------------
Merged https://github.com/apache/sling-org-apache-sling-testing-clients/pull/24
, thanks [~gatopardo] for the contribution and [~angela] for the review.
> OsgiConsoleClient breaks if response Location header is an absolute URL
> -----------------------------------------------------------------------
>
> Key: SLING-10925
> URL: https://issues.apache.org/jira/browse/SLING-10925
> Project: Sling
> Issue Type: Bug
> Components: Apache Sling Testing Clients
> Affects Versions: Apache Sling Testing Clients 2.0.10
> Reporter: Jose Antonio Insua
> Assignee: Angela Schreiber
> Priority: Major
> Fix For: Apache Sling Testing Clients 2.0.12
>
> Time Spent: 40m
> Remaining Estimate: 0h
>
> OsgiConsoleClient.editConfiguration() breaks if the HTTP response has an
> absolute URL in the Location header.
>
> The extra characters break the logic of the return statement:
> {code:java}
> return locationHeader[0].getValue().substring(URL_CONFIGURATION.length() + 1);
> {code}
> This can be easily accounted for:
> {code:java}
> int urlPathStart =
> locationHeader[0].getValue().indexOf(URL_CONFIGURATION);
> return locationHeader[0].getValue().substring(urlPathStart +
> URL_CONFIGURATION.length() + 1)
> {code}
--
This message was sent by Atlassian Jira
(v8.20.1#820001)