glance_store/glance_store
wangxiyuan 9c8364bacf Prevent unicode object error from zero-byte read
During large file uploads under py3, we are occasionally seeing a
"unicode objects must be encoded before hashing" error even though
we are reading from a byte stream.  From what I can tell, it looks
like it's happening when a zero-byte read is requested, so we handle
that case explicitly.  This is a band-aid fix; we still need to track
down the source.

Co-authored-by: wangxiyuan <wangxiyuan1007@gmail.com>
Co-authored-by: Brian Rosmaita <rosmaita.fossdev@gmail.com>

Related-bug: #1805332
Change-Id: Ia7653f9fcbe902abc203c10c80ab44a641a4d8f9
(cherry picked from commit 1d25a2b7a2)
2019-03-20 14:09:09 +00:00
..
_drivers Prevent unicode object error from zero-byte read 2019-03-20 14:09:09 +00:00
common Use oslo_utils.encodeutils.exception_to_unicode() 2016-01-21 11:07:10 +01:00
locale Imported Translations from Zanata 2018-08-15 06:21:39 +00:00
tests Merge "Filesystem driver: add chunk size config option" 2019-02-28 08:15:52 +00:00
__init__.py Enable multi store support for glance 2018-07-15 15:10:27 +00:00
backend.py Update deprecation notices 2018-12-20 11:24:44 -05:00
capabilities.py Cleanup i18n marker functions to match Oslo usage 2016-07-20 16:11:42 -04:00
driver.py Multihash Implementation for Glance 2018-07-18 09:27:54 -04:00
exceptions.py Multihash Implementation for Glance 2018-07-18 09:27:54 -04:00
i18n.py Update oslo libraries 2015-03-19 11:43:42 -05:00
location.py Merge "Address multi store nits" 2018-07-19 17:25:15 +00:00
multi_backend.py Provision to add new config options in sample config file 2018-09-18 10:18:54 +00:00