← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1859258] Re: switch to reader context

 

Reviewed:  https://review.opendev.org/701909
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=af274fa826fc97c15f9fe9b51a966caa8c5cf2eb
Submitter: Zuul
Branch:    master

commit af274fa826fc97c15f9fe9b51a966caa8c5cf2eb
Author: zhanghao <zhanghao2@xxxxxxxxxxxxxxxxxxxx>
Date:   Tue Jan 7 03:18:12 2020 -0500

    Switch to reader context
    
    Since the mtu is already non-nullable, the writer context
    can be switched to a reader context. In addition, the redundant
    reader context can be removed.
    
    Change-Id: I482a3892dee8ee94ab70142cf734f71e766178ed
    Closes-Bug: #1859258


** Changed in: neutron
       Status: In Progress => Fix Released

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

Title:
  switch to reader context

Status in neutron:
  Fix Released

Bug description:
  The mtu is already non-nullable, so the writer context can be switched
  to a reader context.

  like this can be removed, and change it.
  # NOTE(ihrachys) use writer manager to be able to update mtu
  # TODO(ihrachys) remove in Queens when mtu is not nullable
  with db_api.CONTEXT_WRITER.using(context):

  In addition, redundant reader context can be removed.
  def _get_subnet
      # TODO(ihrachys) remove explicit reader usage when subnet OVO switches
      # to engine facade by default
      with db_api.CONTEXT_READER.using(context):

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


References