GBP: Using GBP CLI, update of shared flag for classifier fails

Bug #1474591 reported by puppet-py
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Group Based Policy Client
Fix Released
Medium
Sumit Naiksatam

Bug Description

Using GBP CLI:

1. Create a Policy Classifier with shared=True
2. Create a Policy Rule using the above classifier and shared=True
3. Update of Policy Classifier shared=False does NOT take into effect, although CLI does not give any error(separate bug for this)
4. Delete of Policy Rule
5. Repeat Step 3. In case of CLI it does NOT take into effect, however incase of UI the update goes through succuessfully

===================

[root@f3-controller ~(keystone_admin)]# gbp policy-classifier-show C1
+-------------+--------------------------------------+
| Field | Value |
+-------------+--------------------------------------+
| description | |
| direction | in |
| id | ed299dde-f42d-4e42-897b-c1807aa9c88e |
| name | C1 |
| port_range | |
| protocol | tcp |
| shared | True |
| tenant_id | 8a594bae332d405f92a463af80d2f44c |
+-------------+--------------------------------------+
[root@f3-controller ~(keystone_admin)]#
[root@f3-controller ~(keystone_admin)]# gbp policy-action-show Act
+--------------+--------------------------------------+
| Field | Value |
+--------------+--------------------------------------+
| action_type | allow |
| action_value | |
| description | |
| id | a6032f07-7a2c-49ea-8fed-582b9364d073 |
| name | Act |
| shared | True |
| tenant_id | 8a594bae332d405f92a463af80d2f44c |
+--------------+--------------------------------------+
[root@f3-controller ~(keystone_admin)]#
[root@f3-controller ~(keystone_admin)]# gbp policy-rule-create R1 --classifier C1 --action Act --shared=True
+----------------------+--------------------------------------+
| Field | Value |
+----------------------+--------------------------------------+
| description | |
| enabled | True |
| id | ad358524-411f-4976-bb08-36dd09f722a5 |
| name | R1 |
| policy_actions | a6032f07-7a2c-49ea-8fed-582b9364d073 |
| policy_classifier_id | ed299dde-f42d-4e42-897b-c1807aa9c88e |
| shared | True |
| tenant_id | 8a594bae332d405f92a463af80d2f44c |
+----------------------+--------------------------------------+
[root@f3-controller ~(keystone_admin)]#
[root@f3-controller ~(keystone_admin)]# gbp policy-rule-delete R1
Deleted policy_rule: R1
[root@f3-controller ~(keystone_admin)]#
[root@f3-controller ~(keystone_admin)]# gbp policy-classifier-update C1 --shared=False <<<<<Step: 5
Updated policy_classifier: C1
[root@f3-controller ~(keystone_admin)]#
[root@f3-controller ~(keystone_admin)]#
[root@f3-controller ~(keystone_admin)]# gbp policy-classifier-show C1
+-------------+--------------------------------------+
| Field | Value |
+-------------+--------------------------------------+
| description | |
| direction | in |
| id | ed299dde-f42d-4e42-897b-c1807aa9c88e |
| name | C1 |
| port_range | |
| protocol | tcp |
| shared | True | <<<<<<<<<<<<<<<< Still shows True
| tenant_id | 8a594bae332d405f92a463af80d2f44c |
+-------------+--------------------------------------+
[root@f3-controller ~(keystone_admin)]#

Changed in group-based-policy-client:
status: New → Confirmed
importance: Undecided → Medium
milestone: none → next
Revision history for this message
Sumit Naiksatam (snaiksat) wrote :

This issue affects the CLI for all resources, not just the policy classifier.

Changed in group-based-policy-client:
assignee: nobody → Sumit Naiksatam (snaiksat)
Revision history for this message
Sumit Naiksatam (snaiksat) wrote :
Changed in group-based-policy-client:
milestone: next → 1.0.0
Changed in group-based-policy-client:
status: Confirmed → Fix Committed
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.