columbo 0.1.4 → 0.1.5
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.md +1 -1
- data/lib/columbo/capture.rb +2 -2
- data/lib/columbo/db_client.rb +1 -1
- data/lib/columbo/inspector.rb +1 -0
- data/lib/columbo/version.rb +1 -1
- metadata +18 -2
data/README.md
CHANGED
@@ -45,7 +45,7 @@ Check the Rack configuration:
|
|
45
45
|
|
46
46
|
## Disclaimer
|
47
47
|
|
48
|
-
This is an alpha release, it is
|
48
|
+
This is an alpha release, it is tested with Sinatra and Rails 3 only.
|
49
49
|
UI to explore sessions will be completed later (ETA: 2013'Q2).
|
50
50
|
|
51
51
|
## Author
|
data/lib/columbo/capture.rb
CHANGED
@@ -14,7 +14,7 @@ module Columbo
|
|
14
14
|
@capture = opts[:capture]
|
15
15
|
@bench = opts[:capture] && opts[:bench]
|
16
16
|
@capture_crawlers = opts[:capture_crawlers]
|
17
|
-
@crawlers = opts[:crawlers] || "(Baidu|Gigabot|Googlebot|libwww-perl|lwp-trivial|msnbot|SiteUptime|Slurp|WordPress|ZIBB|ZyBorg|bot|crawler|spider|robot|crawling|facebook|w3c|coccoc)"
|
17
|
+
@crawlers = opts[:crawlers] || "(Baidu|Gigabot|Googlebot|libwww-perl|lwp-trivial|msnbot|SiteUptime|Slurp|WordPress|ZIBB|ZyBorg|bot|crawler|spider|robot|crawling|facebook|w3c|coccoc|Daumoa)"
|
18
18
|
@mongo_uri = opts[:mongo_uri]
|
19
19
|
|
20
20
|
Columbo.logger = opts[:logger] if opts[:logger]
|
@@ -56,7 +56,7 @@ module Columbo
|
|
56
56
|
|
57
57
|
if @bench
|
58
58
|
stop = Time.now
|
59
|
-
duration = ((stop-start)
|
59
|
+
duration = ((stop-start) * 1000).round(3)
|
60
60
|
log(env, "Time: #{duration}ms")
|
61
61
|
headers['Columbo'] = "version #{Columbo::VERSION}, time #{duration}ms"
|
62
62
|
end
|
data/lib/columbo/db_client.rb
CHANGED
data/lib/columbo/inspector.rb
CHANGED
@@ -15,6 +15,7 @@ module Columbo
|
|
15
15
|
client = Columbo::DbClient.new @mongo_uri
|
16
16
|
# Normalise request from env
|
17
17
|
request = Rack::Request.new(env)
|
18
|
+
# Don't capture bots traffic by default
|
18
19
|
rg = Regexp.new(crawlers, Regexp::IGNORECASE)
|
19
20
|
return if request.user_agent.match(rg) && !capture_crawlers
|
20
21
|
html = ''
|
data/lib/columbo/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: columbo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-05-14 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rack
|
@@ -91,6 +91,22 @@ dependencies:
|
|
91
91
|
- - ! '>='
|
92
92
|
- !ruby/object:Gem::Version
|
93
93
|
version: 1.6.1
|
94
|
+
- !ruby/object:Gem::Dependency
|
95
|
+
name: sinatra
|
96
|
+
requirement: !ruby/object:Gem::Requirement
|
97
|
+
none: false
|
98
|
+
requirements:
|
99
|
+
- - ! '>='
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: 1.3.0
|
102
|
+
type: :development
|
103
|
+
prerelease: false
|
104
|
+
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ! '>='
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: 1.3.0
|
94
110
|
description: ! 'A Ruby client library for Columbo: a Customer Experience Management
|
95
111
|
tool'
|
96
112
|
email: jtblin@gmail.com
|