Bug 1781827 - Only the first occurrence of a console log link variable gets replaced
Summary: Only the first occurrence of a console log link variable gets replaced
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console
Version: 4.3.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 4.4.0
Assignee: Samuel Padgett
QA Contact: Yadan Pei
URL:
Whiteboard:
Depends On:
Blocks: 1782873 1783312
TreeView+ depends on / blocked
 
Reported: 2019-12-10 16:29 UTC by Samuel Padgett
Modified: 2020-05-13 21:54 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Previously, OpenShift console would only replace the first occurrence of a variable in ConsoleExternalLogLink URL templates. Console now correctly replaces every instance of the variable in the template with the correct value.
Clone Of:
: 1782873 1783312 (view as bug list)
Environment:
Version: 4.3.0-0.nightly-2019-12-09-035405 Cluster ID: bfecd802-f81b-4cbb-b826-7d1b216d9eb0 Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:71.0) Gecko/20100101 Firefox/71.0
Last Closed: 2020-05-13 21:54:28 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Github openshift console pull 3745 None closed Bug 1781827: Replace multiple occurrences of log link variable expressions 2020-04-24 14:35:20 UTC
Red Hat Product Errata RHBA-2020:0581 None None None 2020-05-13 21:54:32 UTC

Description Samuel Padgett 2019-12-10 16:29:44 UTC
Console log links with multiple occurrences of the same variable expression aren't handled correctly. Only the first expression is replaced. Console should replace all occurrences.

Comment 1 Samuel Padgett 2019-12-10 16:31:19 UTC
https://github.com/openshift/console/pull/3745

Comment 3 XiaochuanWang 2019-12-18 02:07:12 UTC
Using the below url:
``` 
  hrefTemplate: >-
    https://example.com/logs?resourceName=${resourceName}&containerName=${containerName}&Namespace=${resourceNamespace}&resourceNamespace=${resourceNamespace}&podLabels=${podLabels}
  text: Example Logs
```
Test on 4.4.0-0.nightly-2019-12-16-124946 and it does not reproduce. This could be Verified.

Comment 5 errata-xmlrpc 2020-05-13 21:54:28 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:0581


Note You need to log in before you can comment on or make changes to this bug.