Bug 1896209

Summary: When having connection issue, scan CDN always fail silently and return empty result which is hard to debug
Product: Red Hat Satellite Reporter: Hao Chang Yu <hyu>
Component: RepositoriesAssignee: wclark
Status: CLOSED MIGRATED QA Contact: Satellite QE Team <sat-qe-bz-list>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.8.0CC: dsynk, iballou, pdwyer, rbertolj, rlavi, wpinheir
Target Milestone: UnspecifiedKeywords: EasyFix, MigratedToJIRA, Triaged, UserExperience
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-06-06 00:36:13 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Hao Chang Yu 2020-11-10 02:15:03 UTC
Description of problem:
Scan CDN always fail silently when it encounter an error connecting to the Red Hat CDN for whatever reason, such as 403 forbidden and http proxy issue. It just return an empty result without any error. This makes it very hard to debug an issue when empty result is returned.


Steps to Reproduce:
1. In the Satellite, use firewall to block connection to 443 port to simulate the connection issue

firewall-cmd --direct --add-rule ipv4 filter OUTPUT 1 -p tcp -m tcp --dport=443 -j REJECT

2. Login to the Satellite web ui -> Content -> Red Hat Repositories page. Expand any repository set

Actual results:
No repositories available.

Expected results:
Should raise proper error

Additional info:

In 'app/lib/katello/util/cdn_var_substitutor.rb'

      def find_substitutions(paths_with_substitutions)
        to_resolve = paths_with_substitutions.select { |path| path.substitutable? }
        resolved = paths_with_substitutions - to_resolve

        return resolved if to_resolve.empty?

        futures = to_resolve.map do |path_with_substitution|
          Concurrent::Promises.future do
            path_with_substitution.resolve_substitutions(@resource)
          end
        end

        futures.each do |future|
          begin
            resolved << future.value  <=============== Might need to use future.value! here so that exception can be raised
          end
        end

        find_substitutions(resolved.compact.flatten)
      end

Comment 1 Brad Buckingham 2023-05-08 12:47:51 UTC
Upon review of our valid but aging backlog the Satellite Team has concluded that this Bugzilla does not meet the criteria for a resolution in the near term, and are planning to close in a month. This message may be a repeat of a previous update and the bug is again being considered to be closed. If you have any concerns about this, please contact your Red Hat Account team.  Thank you.

Comment 3 Brad Buckingham 2023-06-12 23:14:21 UTC
Based upon feedback during auto-closure, leaving this bugzilla open a while longer for additional investigation.

Comment 5 Eric Helms 2024-06-06 00:36:13 UTC
This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there.

Due to differences in account names between systems, some fields were not replicated.  Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information.

To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "SAT-" followed by an integer.  You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like:

"Bugzilla Bug" = 1234567

In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues. You can also visit https://access.redhat.com/articles/7032570 for general account information.