jsl-osprey 0.0.6 → 0.0.8
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.
- data/README.rdoc +16 -6
- metadata +8 -2
data/README.rdoc
CHANGED
@@ -27,7 +27,13 @@ In more basic cases, you can use Osprey as follows:
|
|
27
27
|
|
28
28
|
Osprey starts to work its magic when you call fetch more than once, either in the current session or after re-
|
29
29
|
instantiating the program. Osprey will remember the tweets that it last retrieved and show you a list of new_feeds
|
30
|
-
in the response object.
|
30
|
+
in the response object. In order to be efficient with network traffic and to reduce client logic, it automatically
|
31
|
+
populates the last seen tweet id in the query string to the API, resulting in fewer records needing to be transeferred
|
32
|
+
between client and server.
|
33
|
+
|
34
|
+
Note that because this is done, in most cases "results" will be the same as "new_results". Since Twitter doesn't
|
35
|
+
guarantee that results arrive in order, however, Osprey does checking to make sure that new_results really aren't
|
36
|
+
ones that we've seen before.
|
31
37
|
|
32
38
|
= Processing Details
|
33
39
|
|
@@ -54,12 +60,16 @@ of previous tweet ids to store so that we can discern new tweets from ones that
|
|
54
60
|
|
55
61
|
== Backend module configuration
|
56
62
|
|
57
|
-
Osprey stores information about previously fetched terms in the backends.
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
63
|
+
Osprey stores information about previously fetched terms in the backends. Since the backends are implemented by Moneta, which is a unified
|
64
|
+
to key-value storage systems, you can store data about feeds in any of the backends supported by Moneta. Just initialize the Search object
|
65
|
+
with options pointing to the backend:
|
66
|
+
|
67
|
+
require 'osprey'
|
68
|
+
o = Osprey::Search.new('Swine Flu', { :backend => { :moneta_klass => 'Moneta::Memcache', :server => 'localhost:1978' } })
|
62
69
|
|
70
|
+
When you fetch the results, important information about the last tweets received are stored in an efficient structure using the
|
71
|
+
backend. In the case above, storage will be in Tokyo Tyrant running on the local machine.
|
72
|
+
|
63
73
|
== Tweet id pool configuration
|
64
74
|
|
65
75
|
Osprey saves ids of previously fetched tweets in the pool so that it can differentiate between new tweets and previously seen tweets, even
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jsl-osprey
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Justin Leitgeb
|
@@ -53,7 +53,7 @@ dependencies:
|
|
53
53
|
version: "0"
|
54
54
|
version:
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name: memcache
|
56
|
+
name: memcache-client
|
57
57
|
type: :runtime
|
58
58
|
version_requirement:
|
59
59
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -77,6 +77,12 @@ homepage: http://github.com/jsl/osprey
|
|
77
77
|
post_install_message:
|
78
78
|
rdoc_options:
|
79
79
|
- --charset=UTF-8
|
80
|
+
- --title
|
81
|
+
- Osprey
|
82
|
+
- --main
|
83
|
+
- README.rdoc
|
84
|
+
- --line-numbers
|
85
|
+
- --inline-source
|
80
86
|
require_paths:
|
81
87
|
- lib
|
82
88
|
required_ruby_version: !ruby/object:Gem::Requirement
|