Bug #6543
closed[RFE] Subcription Events need to be consumed by katello
Description
Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1115602
Candlepin can create and delete sub-pools based on subscription events. Candlepin is now publishing these events to an AMQP Topic.
This RFE should cover the following:
1) Enhance Katello, perhaps using dynflow, to recieve these events and update the subscription list in katello.
2) Improve the subscription list to not re-poll the subscriptions in candlepin
Updated by dustin tsang over 10 years ago
- Follows Feature #6544: katello-installer needs to setup a queue so that katello can pull from for entitlement events added
Updated by The Foreman Bot over 10 years ago
- Status changed from New to Ready For Testing
- Target version set to 49
- Pull request https://github.com/Katello/katello/pull/4431 added
Updated by Eric Helms over 10 years ago
- Category set to 78
- Difficulty set to medium
- Triaged changed from No to Yes
Updated by dustin tsang over 10 years ago
- Related to Bug #6800: qpid-cpp-client-devel in comps added
Updated by dustin tsang about 10 years ago
Test Scenarios¶
Prereqs¶
Subscriptions Queue ( if katello-installer was used the queue name would be katello_event_queue )¶
qpid_messaging gem requires that qpid-cpp-client-devel and qpid-cpp-client be present and can be found in the katello-pulp nighties repo.
ensure that /etc/qpid/qpidc.conf exists
if it doens't exist create one using this example: https://gist.github.com/dustint-rh/7115f89cba4f389ab470
ensure your foreman user (the user rails starts as) is in the qpidd group.
May need to re-login to the shell to refresh the group membership for your user.
test to see if there is a 'subscriptions' queue bound to *.* event
qpid-config --ssl-certificate /etc/pki/katello/certs/java-client.crt --ssl-key /etc/pki/katello/private/java-client.key -b 'amqps://localhost:5671' queues -r
and check that output has
(if katello-installer was used the queue name would be katello_event_queue)
Queue 'subscriptions' bind [subscriptions] => '' bind [*.*] => event
if subscriptions queue isn't present add the queue using
pid-config --ssl-certificate /etc/pki/katello/certs/java-client.crt --ssl-key /etc/pki/katello/private/java-client.key -b 'amqps://localhost:5671' add queue subscriptions --durable
and bind to messages in the event topic with the subject matching *.*
qpid-config --ssl-certificate /etc/pki/katello/certs/java-client.crt --ssl-key /etc/pki/katello/private/java-client.key -b 'amqps://localhost:5671' bind event subscriptions "*.*"
Katello config¶
in katello.yml ensure that qpid configurations are present under common.
(if katello-installer was used the queue name would be katello_event_queue instead of subscriptions)
common: qpid: url: 'amqp:ssl:<fqdn>:5671' subscriptions_queue_address: subscriptions
Test Scenario¶
1. create a new org
2. create/upload a new manifest with a rhel subscription
3. register a content host
subscription-manager register --org="mouse" --environment="Library"
4. go to the Content -> Red Hat Subscriptions ensure that the quantity consumed is 0 for the rhel subscription
5. on the content-host attach to the rhel subscription
subscription-manager attach --pool xxx
6.refresh the page on the browser
=> verify that quantity consumed has been incremented.
7. under Hosts -> Content Hosts, click on the content-host
8. under the subscriptions tab
=> verify the quantity consumed
Updated by dustin tsang about 10 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset katello-installer|f7ecd4ed301678553ea09caa1642107b49750574.
Updated by Eric Helms almost 10 years ago
- Translation missing: en.field_release set to 14