[Yahoo-eng-team] [Bug 1959778] [NEW] "get_rule_type" should not check the context admin status

2022-02-02 Thread Rodolfo Alonso
Public bug reported:

Method "get_rule_type" should not check the context admin status [1].
This should be done in the policy hook, before calling this method. This
is covered and tested in the new secure RBAC policies.

[1]https://github.com/openstack/neutron/blob/e7b70521d0e230143a80974e7e4795a2acafcc9b/neutron/services/qos/qos_plugin.py#L867-L868

** Affects: neutron
 Importance: Low
 Status: New

** Changed in: neutron
   Importance: Undecided => Low

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1959778

Title:
  "get_rule_type" should not check the context admin status

Status in neutron:
  New

Bug description:
  Method "get_rule_type" should not check the context admin status [1].
  This should be done in the policy hook, before calling this method.
  This is covered and tested in the new secure RBAC policies.

  
[1]https://github.com/openstack/neutron/blob/e7b70521d0e230143a80974e7e4795a2acafcc9b/neutron/services/qos/qos_plugin.py#L867-L868

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1959778/+subscriptions


-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1959749] Re: minimum_packet_rate qos rule type is not visible in the GET /v2.0/qos/rule-types response

2022-02-02 Thread Rodolfo Alonso
** Changed in: neutron
   Status: Won't Fix => Confirmed

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1959749

Title:
  minimum_packet_rate qos rule type is not visible in the GET
  /v2.0/qos/rule-types response

Status in neutron:
  Confirmed

Bug description:
  The GET /v2.0/qos/rule-types API does not return the
  minimum_packet_rate rule type even though the feature itself is
  configured, qos policy can be created with that rule type and ports
  can be bound with such qos policy.

  It is reproduced on recent neutron and neutron-lib master in a
  devstack.

  stack@master0:~/neutron$ git log --oneline | head -n1
  e7b70521d0 Merge "Use elevated context to update router's external gateway"

  stack@master0:~/neutron-lib$ git log --oneline | head -n1
  c5fd706 Merge "Add "connectivity" property to "MechanismDriver""

  Example outputs from this system:

  stack@master0:~$ openstack network qos rule type list

  +---+
  | Type |
  +---+
  | minimum_bandwidth |
  | bandwidth_limit |
  +---+

  stack@master0:~$ openstack network qos rule list qp3-bw-pps

  
+--+--+-+--+-+--+---+---+
  | ID | QoS Policy ID | Type | Max Kbps | Max Burst Kbits | Min Kbps | DSCP 
mark | Direction |
  
+--+--+-+--+-+--+---+---+
  | 27a29b90-ce72-4f9c-8a0f-e36596a62e19 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_bandwidth | | | 2000 | | egress |
  | 2872f1cd-88df-4f13-a689-d53a2b4bf923 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_bandwidth | | | 2000 | | ingress |
  | 3aa02806-fe95-4bd9-b840-3d7472466f72 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_packet_rate | | | | | any |
  
+--+--+-+--+-+--+---+---+

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1959749/+subscriptions


-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1959749] Re: minimum_packet_rate qos rule type is not visible in the GET /v2.0/qos/rule-types response

2022-02-02 Thread Rodolfo Alonso
Thanks!

** Changed in: neutron
   Status: New => Won't Fix

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1959749

Title:
  minimum_packet_rate qos rule type is not visible in the GET
  /v2.0/qos/rule-types response

Status in neutron:
  Won't Fix

Bug description:
  The GET /v2.0/qos/rule-types API does not return the
  minimum_packet_rate rule type even though the feature itself is
  configured, qos policy can be created with that rule type and ports
  can be bound with such qos policy.

  It is reproduced on recent neutron and neutron-lib master in a
  devstack.

  stack@master0:~/neutron$ git log --oneline | head -n1
  e7b70521d0 Merge "Use elevated context to update router's external gateway"

  stack@master0:~/neutron-lib$ git log --oneline | head -n1
  c5fd706 Merge "Add "connectivity" property to "MechanismDriver""

  Example outputs from this system:

  stack@master0:~$ openstack network qos rule type list

  +---+
  | Type |
  +---+
  | minimum_bandwidth |
  | bandwidth_limit |
  +---+

  stack@master0:~$ openstack network qos rule list qp3-bw-pps

  
+--+--+-+--+-+--+---+---+
  | ID | QoS Policy ID | Type | Max Kbps | Max Burst Kbits | Min Kbps | DSCP 
mark | Direction |
  
+--+--+-+--+-+--+---+---+
  | 27a29b90-ce72-4f9c-8a0f-e36596a62e19 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_bandwidth | | | 2000 | | egress |
  | 2872f1cd-88df-4f13-a689-d53a2b4bf923 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_bandwidth | | | 2000 | | ingress |
  | 3aa02806-fe95-4bd9-b840-3d7472466f72 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_packet_rate | | | | | any |
  
+--+--+-+--+-+--+---+---+

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1959749/+subscriptions


-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1959750] [NEW] potential performance issue when scheduling network segments

2022-02-02 Thread Sahid Orentino
Public bug reported:

During some investigations regarding segments we may have noticed
performance issues related to the current algorithm that schedules
network segments on hosts.

When an agent is reporting a change in segment, the process goes to the
function `auto_schedule_new_network_segments` with the list of the
segments that this host handles.

This function is retrieving from the segments the related networks, then
we can notice that the algorithm is running a double for loop. That one
iterates through network and per segments to schedule network segments
on all hosts.

for network_id in network_ids:
for segment in segments:
self._schedule_network(
payload.context, network_id, dhcp_notifier,
candidate_hosts=segment['hosts'])

Depending on the design chosen, in a setup that has hundred segments per
host with hundred networks and potentially segments that share the same
list of hosts, we will endup by calling _schedule_network 1 times
with duplication.

To avoid such duplication and unnecessary calls of _schedule_network for
the same hosts we may want to provide a datastructure that is storing
for each network the hosts already scheduled.

 for network_id in network_ids:
 for segment in segments:
 if not _already_scheduled(network_id, segment['hosts']):
 self._schedule_network(
 payload.context, network_id, dhcp_notifier,
 candidate_hosts=segment['hosts'])

With this same scenario, and by using such algorithm we may reduce the
number of call per the number of networks, 100.

Thanks,
s.

** Affects: neutron
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1959750

Title:
  potential performance issue when scheduling network segments

Status in neutron:
  New

Bug description:
  During some investigations regarding segments we may have noticed
  performance issues related to the current algorithm that schedules
  network segments on hosts.

  When an agent is reporting a change in segment, the process goes to
  the function `auto_schedule_new_network_segments` with the list of the
  segments that this host handles.

  This function is retrieving from the segments the related networks,
  then we can notice that the algorithm is running a double for loop.
  That one iterates through network and per segments to schedule network
  segments on all hosts.

  for network_id in network_ids:
  for segment in segments:
  self._schedule_network(
  payload.context, network_id, dhcp_notifier,
  candidate_hosts=segment['hosts'])

  Depending on the design chosen, in a setup that has hundred segments
  per host with hundred networks and potentially segments that share the
  same list of hosts, we will endup by calling _schedule_network 1
  times with duplication.

  To avoid such duplication and unnecessary calls of _schedule_network
  for the same hosts we may want to provide a datastructure that is
  storing for each network the hosts already scheduled.

   for network_id in network_ids:
   for segment in segments:
   if not _already_scheduled(network_id, segment['hosts']):
   self._schedule_network(
   payload.context, network_id, dhcp_notifier,
   candidate_hosts=segment['hosts'])

  With this same scenario, and by using such algorithm we may reduce the
  number of call per the number of networks, 100.

  Thanks,
  s.

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1959750/+subscriptions


-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp


[Yahoo-eng-team] [Bug 1959749] [NEW] minimum_packet_rate qos rule type is not visible in the GET /v2.0/qos/rule-types response

2022-02-02 Thread Balazs Gibizer
Public bug reported:

The GET /v2.0/qos/rule-types API does not return the minimum_packet_rate
rule type even though the feature itself is configured, qos policy can
be created with that rule type and ports can be bound with such qos
policy.

It is reproduced on recent neutron and neutron-lib master in a devstack.

stack@master0:~/neutron$ git log --oneline | head -n1
e7b70521d0 Merge "Use elevated context to update router's external gateway"

stack@master0:~/neutron-lib$ git log --oneline | head -n1
c5fd706 Merge "Add "connectivity" property to "MechanismDriver""

Example outputs from this system:

stack@master0:~$ openstack network qos rule type list

+---+
| Type |
+---+
| minimum_bandwidth |
| bandwidth_limit |
+---+

stack@master0:~$ openstack network qos rule list qp3-bw-pps

+--+--+-+--+-+--+---+---+
| ID | QoS Policy ID | Type | Max Kbps | Max Burst Kbits | Min Kbps | DSCP mark 
| Direction |
+--+--+-+--+-+--+---+---+
| 27a29b90-ce72-4f9c-8a0f-e36596a62e19 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 | 
minimum_bandwidth | | | 2000 | | egress |
| 2872f1cd-88df-4f13-a689-d53a2b4bf923 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 | 
minimum_bandwidth | | | 2000 | | ingress |
| 3aa02806-fe95-4bd9-b840-3d7472466f72 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 | 
minimum_packet_rate | | | | | any |
+--+--+-+--+-+--+---+---+

** Affects: neutron
 Importance: Undecided
 Status: New


** Tags: api

** Tags added: api

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1959749

Title:
  minimum_packet_rate qos rule type is not visible in the GET
  /v2.0/qos/rule-types response

Status in neutron:
  New

Bug description:
  The GET /v2.0/qos/rule-types API does not return the
  minimum_packet_rate rule type even though the feature itself is
  configured, qos policy can be created with that rule type and ports
  can be bound with such qos policy.

  It is reproduced on recent neutron and neutron-lib master in a
  devstack.

  stack@master0:~/neutron$ git log --oneline | head -n1
  e7b70521d0 Merge "Use elevated context to update router's external gateway"

  stack@master0:~/neutron-lib$ git log --oneline | head -n1
  c5fd706 Merge "Add "connectivity" property to "MechanismDriver""

  Example outputs from this system:

  stack@master0:~$ openstack network qos rule type list

  +---+
  | Type |
  +---+
  | minimum_bandwidth |
  | bandwidth_limit |
  +---+

  stack@master0:~$ openstack network qos rule list qp3-bw-pps

  
+--+--+-+--+-+--+---+---+
  | ID | QoS Policy ID | Type | Max Kbps | Max Burst Kbits | Min Kbps | DSCP 
mark | Direction |
  
+--+--+-+--+-+--+---+---+
  | 27a29b90-ce72-4f9c-8a0f-e36596a62e19 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_bandwidth | | | 2000 | | egress |
  | 2872f1cd-88df-4f13-a689-d53a2b4bf923 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_bandwidth | | | 2000 | | ingress |
  | 3aa02806-fe95-4bd9-b840-3d7472466f72 | 53bc1d66-c4ce-4f98-b703-8ae29afab6b1 
| minimum_packet_rate | | | | | any |
  
+--+--+-+--+-+--+---+---+

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1959749/+subscriptions


-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp