<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openstack/python-glanceclient.git/glanceclient/tests/unit/test_http.py, branch stable/mitaka</title>
<subtitle>opendev.org: openstack/python-glanceclient.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/'/>
<entry>
<title>Fix "Codec can't encode characters"</title>
<updated>2016-05-23T14:37:35+00:00</updated>
<author>
<name>Darja Shakhray</name>
<email>dshakhray@mirantis.com</email>
</author>
<published>2016-05-13T12:03:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=4a5567109174a05d434fe336c056ca09eda4b976'/>
<id>4a5567109174a05d434fe336c056ca09eda4b976</id>
<content type='text'>
Headers were encoded in HTTPClient, but when glance client started
to use SessionClient this functionality was lost.

This commit replaces static method "encode_headers" from HTTPClient
and makes it a common function, that SessionClient can use when
converting image meta to headers.


Change-Id: If9f8020220d2a0431b4241b38b9c83c09c0d75cb
Closes-bug: #1574587
(cherry picked from commit 9329ef0bc40375cd9b115415e10baf89789f56f0)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Headers were encoded in HTTPClient, but when glance client started
to use SessionClient this functionality was lost.

This commit replaces static method "encode_headers" from HTTPClient
and makes it a common function, that SessionClient can use when
converting image meta to headers.


Change-Id: If9f8020220d2a0431b4241b38b9c83c09c0d75cb
Closes-bug: #1574587
(cherry picked from commit 9329ef0bc40375cd9b115415e10baf89789f56f0)
</pre>
</div>
</content>
</entry>
<entry>
<title>Change assertTrue(isinstance()) by optimal assert</title>
<updated>2016-01-06T17:07:41+00:00</updated>
<author>
<name>LiuNanke</name>
<email>nanke.liu@easystack.cn</email>
</author>
<published>2016-01-06T16:23:05+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=c7fc0d6b1d7d2691d28a7d5f6b8dc5dab7204368'/>
<id>c7fc0d6b1d7d2691d28a7d5f6b8dc5dab7204368</id>
<content type='text'>
assertTrue(isinstance(A, B)) or assertEqual(type(A), B) in tests
should be replaced by assertIsInstance(A, B) provided by testtools.


Change-Id: I7135d3b7fe15b16c17b7581e553ce5d289b58f43
Related-bug: #1268480
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
assertTrue(isinstance(A, B)) or assertEqual(type(A), B) in tests
should be replaced by assertIsInstance(A, B) provided by testtools.


Change-Id: I7135d3b7fe15b16c17b7581e553ce5d289b58f43
Related-bug: #1268480
</pre>
</div>
</content>
</entry>
<entry>
<title>Ensure that identity token in header is not an unicode string</title>
<updated>2015-11-17T17:14:20+00:00</updated>
<author>
<name>Vincent Untz</name>
<email>vuntz@suse.com</email>
</author>
<published>2015-04-24T11:29:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=f65ba822682a8ea6939144a77bddef341b997911'/>
<id>f65ba822682a8ea6939144a77bddef341b997911</id>
<content type='text'>
We need all the headers to be safe strings so they can be joined
together and not become an unicode string in doing so.

This fixes a bug when creating an image with non-ascii characters in the
name.

This is required for python 2.6 compatibility.

Change-Id: I66ebc27edf4ccd8f903399da58705711c372536d
Closes-Bug: 1448080
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We need all the headers to be safe strings so they can be joined
together and not become an unicode string in doing so.

This fixes a bug when creating an image with non-ascii characters in the
name.

This is required for python 2.6 compatibility.

Change-Id: I66ebc27edf4ccd8f903399da58705711c372536d
Closes-Bug: 1448080
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge "Add support for setting Accept-Language header"</title>
<updated>2015-10-14T15:25:03+00:00</updated>
<author>
<name>Jenkins</name>
<email>jenkins@review.openstack.org</email>
</author>
<published>2015-10-14T15:25:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=2fcff11b90748b32e6e38c7bdd6fe11103764485'/>
<id>2fcff11b90748b32e6e38c7bdd6fe11103764485</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Add support for setting Accept-Language header</title>
<updated>2015-10-14T12:57:07+00:00</updated>
<author>
<name>Frode Nordahl</name>
<email>frode.nordahl@gmail.com</email>
</author>
<published>2015-08-03T08:04:15+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=ca050ed4c1426e278829dd54471bd63315090e68'/>
<id>ca050ed4c1426e278829dd54471bd63315090e68</id>
<content type='text'>
DocImpact

Closes-Bug: 1480529
Change-Id: I35a37d55edb700a5993bd5cc352335a87a15e47a</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
DocImpact

Closes-Bug: 1480529
Change-Id: I35a37d55edb700a5993bd5cc352335a87a15e47a</pre>
</div>
</content>
</entry>
<entry>
<title>Remove custom SSL compression handling</title>
<updated>2015-08-26T12:26:21+00:00</updated>
<author>
<name>Stuart McLaren</name>
<email>stuart.mclaren@hp.com</email>
</author>
<published>2015-06-08T14:49:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=618637a5bd545d8271d9349b08a8e4ab2841d086'/>
<id>618637a5bd545d8271d9349b08a8e4ab2841d086</id>
<content type='text'>
Custom SSL handling was introduced because disabling SSL layer compression
provided an approximately five fold performance increase in some
cases. Without SSL layer compression disabled the image transfer would be
CPU bound -- with the CPU performing the DEFLATE algorithm.  This would
typically limit image transfers to &lt; 20 MB/s. When --no-ssl-compression
was specified the client would not negotiate any compression algorithm
during the SSL handshake with the server which would remove the CPU
bottleneck and transfers could approach wire speed.

In order to support '--no-ssl-compression' two totally separate code
paths exist depending on whether this is True or False.  When SSL
compression is disabled, rather than using the standard 'requests'
library, we enter some custom code based on pyopenssl and httplib in
order to disable compression.

This patch/spec proposes removing the custom code because:

* It is a burden to maintain

 Eg adding new code such as keystone session support is more complicated

* It can introduce additional failure modes

 We have seen some bugs related to the 'custom' certificate checking

* Newer Operating Systems disable SSL for us.

 Eg. While Debian 7 defaulted to compression 'on', Debian 8 has compression
 'off'. This makes both servers and client less likely to have compression
 enabled.

* Newer combinations of 'requests' and 'python' do this for us

 Requests disables compression when backed by a version of python which
 supports it (&gt;= 2.7.9). This makes clients more likely to disable
 compression out-of-the-box.

* It is (in principle) possible to do this on older versions too

 If pyopenssl, ndg-httpsclient and pyasn1 are installed on older
 operating system/python combinations, the requests library should
 disable SSL compression on the client side.

* Systems that have SSL compression enabled may be vulnerable to the CRIME
(https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2012-4929) attack.
Installations which are security conscious should be running the Glance
server with SSL disabled.

Full Spec: https://review.openstack.org/#/c/187674
Blueprint: remove-custom-client-ssl-handling

Change-Id: I7e7761fc91b0d6da03939374eeedd809534f6edf
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Custom SSL handling was introduced because disabling SSL layer compression
provided an approximately five fold performance increase in some
cases. Without SSL layer compression disabled the image transfer would be
CPU bound -- with the CPU performing the DEFLATE algorithm.  This would
typically limit image transfers to &lt; 20 MB/s. When --no-ssl-compression
was specified the client would not negotiate any compression algorithm
during the SSL handshake with the server which would remove the CPU
bottleneck and transfers could approach wire speed.

In order to support '--no-ssl-compression' two totally separate code
paths exist depending on whether this is True or False.  When SSL
compression is disabled, rather than using the standard 'requests'
library, we enter some custom code based on pyopenssl and httplib in
order to disable compression.

This patch/spec proposes removing the custom code because:

* It is a burden to maintain

 Eg adding new code such as keystone session support is more complicated

* It can introduce additional failure modes

 We have seen some bugs related to the 'custom' certificate checking

* Newer Operating Systems disable SSL for us.

 Eg. While Debian 7 defaulted to compression 'on', Debian 8 has compression
 'off'. This makes both servers and client less likely to have compression
 enabled.

* Newer combinations of 'requests' and 'python' do this for us

 Requests disables compression when backed by a version of python which
 supports it (&gt;= 2.7.9). This makes clients more likely to disable
 compression out-of-the-box.

* It is (in principle) possible to do this on older versions too

 If pyopenssl, ndg-httpsclient and pyasn1 are installed on older
 operating system/python combinations, the requests library should
 disable SSL compression on the client side.

* Systems that have SSL compression enabled may be vulnerable to the CRIME
(https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2012-4929) attack.
Installations which are security conscious should be running the Glance
server with SSL disabled.

Full Spec: https://review.openstack.org/#/c/187674
Blueprint: remove-custom-client-ssl-handling

Change-Id: I7e7761fc91b0d6da03939374eeedd809534f6edf
</pre>
</div>
</content>
</entry>
<entry>
<title>Enable flake8 checks</title>
<updated>2015-07-21T14:08:27+00:00</updated>
<author>
<name>Darja Shakhray</name>
<email>dshakhray@mirantis.com</email>
</author>
<published>2015-07-20T14:29:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=ec0f2dfd8500d230895e286462aaf69c43777038'/>
<id>ec0f2dfd8500d230895e286462aaf69c43777038</id>
<content type='text'>
This commit enables new flake8 checks:
* E265  block comment should start with '# '
* H405  multi line docstring summary not separated with an empty line
* E123  closing bracket does not match indentation of opening bracket's line
* H238  old style class declaration, use new style (inherit from `object`)
* E128  continuation line under-indented for visual indent
and makes related changes in the code.

Change-Id: Ie993afc930f6b74d7a990bcaa9fc0e9f5ba1585c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit enables new flake8 checks:
* E265  block comment should start with '# '
* H405  multi line docstring summary not separated with an empty line
* E123  closing bracket does not match indentation of opening bracket's line
* H238  old style class declaration, use new style (inherit from `object`)
* E128  continuation line under-indented for visual indent
and makes related changes in the code.

Change-Id: Ie993afc930f6b74d7a990bcaa9fc0e9f5ba1585c
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix exception message in Http.py</title>
<updated>2015-07-14T01:01:12+00:00</updated>
<author>
<name>wangxiyuan</name>
<email>wangxiyuan@huawei.com</email>
</author>
<published>2015-07-06T06:37:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=b48ff98e165160abc1354c2dfe8d9edf472b6965'/>
<id>b48ff98e165160abc1354c2dfe8d9edf472b6965</id>
<content type='text'>
In common.http.py, the exception RequestTimeout has
wrong message.This patch fixed it.

Change-Id: Ie8ff188b9c82ce424cb8177278f36e4d1275b306
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In common.http.py, the exception RequestTimeout has
wrong message.This patch fixed it.

Change-Id: Ie8ff188b9c82ce424cb8177278f36e4d1275b306
</pre>
</div>
</content>
</entry>
<entry>
<title>Make glanceclient accept a session object</title>
<updated>2015-06-11T13:11:56+00:00</updated>
<author>
<name>Jamie Lennox</name>
<email>jamielennox@redhat.com</email>
</author>
<published>2014-11-25T03:25:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=5ce9c7dc964be0b3e8f9f273169b77ada85cd8ec'/>
<id>5ce9c7dc964be0b3e8f9f273169b77ada85cd8ec</id>
<content type='text'>
To make this work we create a different HTTPClient that extends the
basic keystoneclient Adapter. The Adapter is a standard set of
parameters that all clients should know how to use like region_name and
user_agent. We extend this with the glance specific response
manipulation like loading and sending iterables.

Implements: bp session-objects
Change-Id: Ie8eb4bbf7d1a037099a6d4b272cab70525fbfc85
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
To make this work we create a different HTTPClient that extends the
basic keystoneclient Adapter. The Adapter is a standard set of
parameters that all clients should know how to use like region_name and
user_agent. We extend this with the glance specific response
manipulation like loading and sending iterables.

Implements: bp session-objects
Change-Id: Ie8eb4bbf7d1a037099a6d4b272cab70525fbfc85
</pre>
</div>
</content>
</entry>
<entry>
<title>Move unit tests to standard directory</title>
<updated>2015-04-18T17:42:20+00:00</updated>
<author>
<name>Stuart McLaren</name>
<email>stuart.mclaren@hp.com</email>
</author>
<published>2015-04-17T14:02:33+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-glanceclient.git/commit/?id=f2a8a520e76a129039b3c4043aeb8db75582b8c8'/>
<id>f2a8a520e76a129039b3c4043aeb8db75582b8c8</id>
<content type='text'>
This patch moves the glanceclient unit tests to the standard directory
(xxxclient/tests/unit) in preparation for adding functional gate tests
'check-glanceclient-dsvm-functional' in the same vein as existing client
tests for other projects, eg:

* check-novaclient-dsvm-functional
* check-keystoneclient-dsvm-functional
* check-neutronclient-dsvm-functional

Change-Id: I29d4b9e3a428c851575ee9afde40d6df583456c4
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch moves the glanceclient unit tests to the standard directory
(xxxclient/tests/unit) in preparation for adding functional gate tests
'check-glanceclient-dsvm-functional' in the same vein as existing client
tests for other projects, eg:

* check-novaclient-dsvm-functional
* check-keystoneclient-dsvm-functional
* check-neutronclient-dsvm-functional

Change-Id: I29d4b9e3a428c851575ee9afde40d6df583456c4
</pre>
</div>
</content>
</entry>
</feed>
