hugs 2.7.0 → 2.7.1

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -1,26 +1,26 @@
1
1
  # Hugs
2
2
 
3
3
  Hugs net-http-persistent with convenient delete, get, head, post, and put methods.
4
+ Automatically parses JSON and XML responses.
4
5
 
5
- Opted to write this gem for four reasons:
6
+ ## Why?
7
+
8
+ Opted to write this gem for a few reasons:
6
9
 
7
10
  * [Ganeti's API](http://docs.ganeti.org/ganeti/2.2/html/rapi.html), required
8
11
  the sending of a message body with the HTTP Get request, which
9
- [rest-client](https://github.com/archiloque/rest-client) does not do.
10
- * Wanted a [fast](http://blog.segment7.net/articles/2010/05/07/net-http-is-not-slow),
12
+ [rest-client](https://github.com/archiloque/rest-client) does not allow.
13
+ * A [fast](http://blog.segment7.net/articles/2010/05/07/net-http-is-not-slow),
11
14
  thread-safe, and persistent client.
12
15
  * [Excon](https://github.com/geemus/excon) does most everything right, <del>but is not
13
16
  compatible with [VCR](https://github.com/myronmarston/vcr) (more specifically
14
17
  [webmock](https://github.com/bblimke/webmock) and [fakeweb](https://github.com/chrisk/fakeweb))</del>.
15
18
  There looks to be [work on this front](https://github.com/geemus/excon/issues#issue/29).
16
- * Wanted to learn how to handle this pattern.
19
+ * Continued learning.
17
20
 
18
21
  ## Opinionated
19
22
 
20
- * The webservice returns JSON or XML.
21
- * It is okay to parse the response.
22
- * A Hash is returned when response is JSON.
23
- * A Nokogiri::XML::Document is returned when XML.
23
+ Intended for but not limited to, endpoints that return JSON or XML.
24
24
 
25
25
  ## Usage
26
26
 
@@ -179,7 +179,6 @@ module Hugs
179
179
 
180
180
  chunked_headers = {
181
181
  "Content-Type" => mime_type(:binary),
182
- "Content-Length" => File.size(upload[:file]),
183
182
  "Transfer-Encoding" => "chunked"
184
183
  }.merge upload[:headers] || {}
185
184
  end
@@ -1,3 +1,3 @@
1
1
  module Hugs
2
- VERSION = "2.7.0"
2
+ VERSION = "2.7.1"
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: hugs
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 2.7.0
5
+ version: 2.7.1
6
6
  platform: ruby
7
7
  authors:
8
8
  - John Dewey
@@ -11,7 +11,7 @@ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
13
 
14
- date: 2011-06-07 00:00:00 -07:00
14
+ date: 2011-06-14 00:00:00 -07:00
15
15
  default_executable:
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency