Ring load is slow: use bufferedio with gzipfile

Bug #898169 reported by Therese McHale
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Object Storage (swift)
Fix Released
Low
Chmouel Boudjnah

Bug Description

swift uses pickle.load(gzipfile(self.pickle_gz_path,'rb)) to load a ring. With larger rings (e.g. 2M zipped, 6M unzipped ) the load ..specifically the uncompress ...is very slow. Use of BufferedReader as per http://bugs.python.org/issue7471 appears to improve the load perfomance signficantly. Testing with 1.4.3 of swift but 1.4.4 seems the same

Revision history for this message
Therese McHale (therese-mchale) wrote :

I will submit fix for review

Revision history for this message
Therese McHale (therese-mchale) wrote :

Submitted Change Ia4b0d212 for review

Revision history for this message
Chmouel Boudjnah (chmouel) wrote :

Hi Therere, the change you are referencing is :

https://review.openstack.org/#/c/1968/

any chance to sign the CLA :

http://wiki.openstack.org/HowToContribute

to restore this change, so we can review it and could get us this speed improvement.

Thanks and let me know if you need help with that.

Changed in swift:
assignee: nobody → Therese McHale (therese-mchale)
status: New → Triaged
importance: Undecided → Low
Revision history for this message
Therese McHale (therese-mchale) wrote :

Hi, I believe I signed the cla. I am listed on http://wiki.openstack.org/Contributors and as per the comments on https://review.openstack.org/#/c/1968/ I did sign it. thanks .

Revision history for this message
Chmouel Boudjnah (chmouel) wrote : Re: [Bug 898169] Re: Ring load is slow: use bufferedio with gzipfile

apologies i misunderstood the commit, so are you interested to fix the
error reported by John?

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to swift (master)

Fix proposed to branch: master
Review: https://review.openstack.org/8658

Changed in swift:
assignee: Therese McHale (therese-mchale) → Iryoung Jeong (iryoung)
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to swift (master)

Reviewed: https://review.openstack.org/8658
Committed: http://github.com/openstack/swift/commit/c67e56848cec310193f17b4e006948a17006a442
Submitter: Jenkins
Branch: master

commit c67e56848cec310193f17b4e006948a17006a442
Author: Iryoung Jeong <email address hidden>
Date: Mon Jun 18 23:40:50 2012 +0900

    Use buffered gzip stream with python 2.7.

    - Fixes bug 898169.
    - It's possible to make GzipFile inherits io.BufferedIOBase in python
      2.6, but IMO it's better let people to use 2.7 if they really need
      this feature.

    Change-Id: I4c6e4858e3f616af892e7f4fa6daae0f6ee31723

Changed in swift:
assignee: Iryoung Jeong (iryoung) → Chmouel Boudjnah (chmouel)
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in swift:
milestone: none → 1.6.0
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.