rstreamor 0.2.3 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b05b8bc962447397c64dc63d6a66e6b21297b131
4
- data.tar.gz: 900268b16fc87b23cf950e02959bd1df5734781e
3
+ metadata.gz: 581d9a126b6ea78ee0ce602daf8adf61363a7890
4
+ data.tar.gz: e0924a5564245385bd116ac100245bf5e82109b9
5
5
  SHA512:
6
- metadata.gz: 9a125769f0ffe92a07a1177c3230e036b658b3c3c766f8b37b0221056b06babacf2e5136a70dfce8076e839af23dc04f90c6d3d486542437fc94eb4c1ad3423b
7
- data.tar.gz: f954a3c2070bf60912e9de80b4071acbcdc06d896ea0515d4b79d00740e70246457e287f56c100e05da4756268befef8a8511924b8f5afb9c7a15724c1b7bae8
6
+ metadata.gz: 380b203fa6028d3523a41aba632bc95c0868df61205ad3a5bdbd70bd0cc622816be8205e859983797e4be42db1a8eeeaede4217468df8dee69b913e55259a6e9
7
+ data.tar.gz: 081bfd93d9b5b621316bd8f86d0eca8753651b5e6ba45d6ecec99a8ce2694540fc544ad29c6d241409449b7451c984b70b6585ec7c57c912c494d856cc4a0eec
data/README.md CHANGED
@@ -8,7 +8,7 @@ gem 'rstreamor', git: 'https://github.com/ndea/rstreamor.git', branch: 'master'
8
8
  ```
9
9
  ###### Rubygems
10
10
  ```ruby
11
- gem 'rstreamor', '~> 0.2.3'
11
+ gem 'rstreamor', '~> 0.2.4'
12
12
  ```
13
13
  # Install
14
14
  ```ruby
@@ -34,6 +34,8 @@ If you dont use Carrierwave as a file make sure your file method has the followi
34
34
  - #data
35
35
  - #content_type
36
36
 
37
+ Please note that if you don't specify any range request headers Rstreamor will return the whole file from byte 0 to EOF with status code *200*
38
+
37
39
  # What is a range request?
38
40
  Byte serving is the process of sending only a portion of an HTTP/1.1 message from a server to a client. Byte serving begins when an HTTP server advertises its willingness to serve partial requests using the Accept-Ranges response header. A client then requests a specific part of a file from the server using the Range request header. If the range is valid, the server sends it to the client with a 206 Partial Content status code and a Content-Range header listing the range sent. Clients which request byte-serving might do so in cases in which a large file has been only partially delivered and a limited portion of the file is needed in a particular range. Byte Serving is therefore a method of bandwidth optimization. [Wikipedia](https://en.wikipedia.org/wiki/Byte_serving)
39
41
 
@@ -84,3 +86,12 @@ Content-Type:application/mp4
84
86
  3. Commit your changes (`git commit -am 'Add some feature'`)
85
87
  4. Push to the branch (`git push origin my-new-feature`)
86
88
  5. Create a new Pull Request
89
+
90
+ # Contribution topics wanted
91
+
92
+ - Specs
93
+ - Documentation
94
+ - Bugfixes
95
+ - Codestyle
96
+ - Anything that improves this gem
97
+
@@ -8,7 +8,7 @@ module Rstreamor
8
8
  end
9
9
 
10
10
  def ranges
11
- self.request.headers['HTTP_RANGE'].gsub('bytes=', '').split('-')
11
+ self.request.headers['HTTP_RANGE'].gsub('bytes=', '').split('-') if self.request.headers['HTTP_RANGE']
12
12
  end
13
13
 
14
14
  def upper_bound
@@ -1,3 +1,3 @@
1
1
  module Rstreamor
2
- VERSION = "0.2.3"
2
+ VERSION = "0.2.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rstreamor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Erwin Schens
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-08-07 00:00:00.000000000 Z
11
+ date: 2015-11-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -101,7 +101,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
101
101
  version: '0'
102
102
  requirements: []
103
103
  rubyforge_project:
104
- rubygems_version: 2.4.6
104
+ rubygems_version: 2.4.8
105
105
  signing_key:
106
106
  specification_version: 4
107
107
  summary: Stream files using HTTP range requests.