rack-action_logger 0.1.0 → 0.1.1
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 +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +39 -4
- data/lib/rack/action_logger/emit_adapter.rb +12 -0
- data/lib/rack/action_logger/version.rb +1 -1
- data/lib/rack/action_logger.rb +0 -2
- data/rack-action_logger.gemspec +1 -1
- metadata +2 -145
- data/docs/action_log.png +0 -0
- data/docs/attributed_log.png +0 -0
- data/docs/request_log.png +0 -0
- data/docs/sample_log.png +0 -0
- data/example/rails4/.generators +0 -8
- data/example/rails4/.gitignore +0 -48
- data/example/rails4/.rakeTasks +0 -7
- data/example/rails4/Gemfile +0 -53
- data/example/rails4/Gemfile.lock +0 -192
- data/example/rails4/README.rdoc +0 -28
- data/example/rails4/Rakefile +0 -6
- data/example/rails4/app/assets/images/.keep +0 -0
- data/example/rails4/app/assets/javascripts/application.js +0 -16
- data/example/rails4/app/assets/javascripts/hello.coffee +0 -3
- data/example/rails4/app/assets/stylesheets/application.css +0 -15
- data/example/rails4/app/assets/stylesheets/hello.scss +0 -3
- data/example/rails4/app/controllers/application_controller.rb +0 -7
- data/example/rails4/app/controllers/concerns/.keep +0 -0
- data/example/rails4/app/controllers/hello_controller.rb +0 -6
- data/example/rails4/app/helpers/application_helper.rb +0 -2
- data/example/rails4/app/helpers/hello_helper.rb +0 -2
- data/example/rails4/app/mailers/.keep +0 -0
- data/example/rails4/app/models/.keep +0 -0
- data/example/rails4/app/models/concerns/.keep +0 -0
- data/example/rails4/app/views/hello/index.html.erb +0 -2
- data/example/rails4/app/views/layouts/application.html.erb +0 -14
- data/example/rails4/bin/bundle +0 -3
- data/example/rails4/bin/rails +0 -4
- data/example/rails4/bin/rake +0 -4
- data/example/rails4/bin/rspec +0 -17
- data/example/rails4/bin/setup +0 -29
- data/example/rails4/config/application.rb +0 -37
- data/example/rails4/config/boot.rb +0 -3
- data/example/rails4/config/database.yml +0 -25
- data/example/rails4/config/environment.rb +0 -5
- data/example/rails4/config/environments/development.rb +0 -41
- data/example/rails4/config/environments/production.rb +0 -79
- data/example/rails4/config/environments/test.rb +0 -42
- data/example/rails4/config/initializers/assets.rb +0 -11
- data/example/rails4/config/initializers/backtrace_silencers.rb +0 -7
- data/example/rails4/config/initializers/cookies_serializer.rb +0 -3
- data/example/rails4/config/initializers/filter_parameter_logging.rb +0 -4
- data/example/rails4/config/initializers/fluent_logger.rb +0 -1
- data/example/rails4/config/initializers/inflections.rb +0 -16
- data/example/rails4/config/initializers/mime_types.rb +0 -4
- data/example/rails4/config/initializers/rack-action_logger.rb +0 -6
- data/example/rails4/config/initializers/session_store.rb +0 -3
- data/example/rails4/config/initializers/wrap_parameters.rb +0 -14
- data/example/rails4/config/locales/en.yml +0 -23
- data/example/rails4/config/routes.rb +0 -3
- data/example/rails4/config/secrets.yml +0 -22
- data/example/rails4/config.ru +0 -4
- data/example/rails4/db/schema.rb +0 -16
- data/example/rails4/db/seeds.rb +0 -7
- data/example/rails4/lib/assets/.keep +0 -0
- data/example/rails4/lib/tasks/.keep +0 -0
- data/example/rails4/public/404.html +0 -67
- data/example/rails4/public/422.html +0 -67
- data/example/rails4/public/500.html +0 -66
- data/example/rails4/public/favicon.ico +0 -0
- data/example/rails4/public/robots.txt +0 -5
- data/example/rails4/spec/controllers/hello_controller_spec.rb +0 -10
- data/example/rails4/spec/rails_helper.rb +0 -57
- data/example/rails4/spec/spec_helper.rb +0 -99
- data/example/rails4/vendor/assets/javascripts/.keep +0 -0
- data/example/rails4/vendor/assets/stylesheets/.keep +0 -0
- data/example/rails5/.generators +0 -8
- data/example/rails5/.gitignore +0 -48
- data/example/rails5/.rakeTasks +0 -7
- data/example/rails5/Gemfile +0 -54
- data/example/rails5/Gemfile.lock +0 -205
- data/example/rails5/README.md +0 -24
- data/example/rails5/Rakefile +0 -6
- data/example/rails5/app/assets/config/manifest.js +0 -3
- data/example/rails5/app/assets/images/.keep +0 -0
- data/example/rails5/app/assets/javascripts/application.js +0 -16
- data/example/rails5/app/assets/javascripts/cable.js +0 -13
- data/example/rails5/app/assets/javascripts/channels/.keep +0 -0
- data/example/rails5/app/assets/javascripts/hello.coffee +0 -3
- data/example/rails5/app/assets/stylesheets/application.css +0 -15
- data/example/rails5/app/assets/stylesheets/hello.scss +0 -3
- data/example/rails5/app/channels/application_cable/channel.rb +0 -4
- data/example/rails5/app/channels/application_cable/connection.rb +0 -4
- data/example/rails5/app/controllers/application_controller.rb +0 -5
- data/example/rails5/app/controllers/concerns/.keep +0 -0
- data/example/rails5/app/controllers/hello_controller.rb +0 -6
- data/example/rails5/app/helpers/application_helper.rb +0 -2
- data/example/rails5/app/helpers/hello_helper.rb +0 -2
- data/example/rails5/app/jobs/application_job.rb +0 -2
- data/example/rails5/app/mailers/application_mailer.rb +0 -4
- data/example/rails5/app/models/application_record.rb +0 -3
- data/example/rails5/app/models/concerns/.keep +0 -0
- data/example/rails5/app/views/hello/index.html.erb +0 -2
- data/example/rails5/app/views/layouts/application.html.erb +0 -14
- data/example/rails5/app/views/layouts/mailer.html.erb +0 -13
- data/example/rails5/app/views/layouts/mailer.text.erb +0 -1
- data/example/rails5/bin/bundle +0 -3
- data/example/rails5/bin/rails +0 -4
- data/example/rails5/bin/rake +0 -17
- data/example/rails5/bin/rspec +0 -17
- data/example/rails5/bin/setup +0 -34
- data/example/rails5/bin/update +0 -29
- data/example/rails5/config/application.rb +0 -13
- data/example/rails5/config/boot.rb +0 -3
- data/example/rails5/config/cable.yml +0 -9
- data/example/rails5/config/database.yml +0 -25
- data/example/rails5/config/environment.rb +0 -5
- data/example/rails5/config/environments/development.rb +0 -54
- data/example/rails5/config/environments/production.rb +0 -86
- data/example/rails5/config/environments/test.rb +0 -42
- data/example/rails5/config/initializers/application_controller_renderer.rb +0 -6
- data/example/rails5/config/initializers/assets.rb +0 -11
- data/example/rails5/config/initializers/backtrace_silencers.rb +0 -7
- data/example/rails5/config/initializers/cookies_serializer.rb +0 -5
- data/example/rails5/config/initializers/filter_parameter_logging.rb +0 -4
- data/example/rails5/config/initializers/fluent_logger.rb +0 -1
- data/example/rails5/config/initializers/inflections.rb +0 -16
- data/example/rails5/config/initializers/mime_types.rb +0 -4
- data/example/rails5/config/initializers/new_framework_defaults.rb +0 -24
- data/example/rails5/config/initializers/rack-action_logger.rb +0 -6
- data/example/rails5/config/initializers/session_store.rb +0 -3
- data/example/rails5/config/initializers/wrap_parameters.rb +0 -14
- data/example/rails5/config/locales/en.yml +0 -23
- data/example/rails5/config/puma.rb +0 -47
- data/example/rails5/config/routes.rb +0 -3
- data/example/rails5/config/secrets.yml +0 -22
- data/example/rails5/config/spring.rb +0 -6
- data/example/rails5/config.ru +0 -5
- data/example/rails5/db/schema.rb +0 -15
- data/example/rails5/db/seeds.rb +0 -7
- data/example/rails5/lib/assets/.keep +0 -0
- data/example/rails5/lib/tasks/.keep +0 -0
- data/example/rails5/public/404.html +0 -67
- data/example/rails5/public/422.html +0 -67
- data/example/rails5/public/500.html +0 -66
- data/example/rails5/public/apple-touch-icon-precomposed.png +0 -0
- data/example/rails5/public/apple-touch-icon.png +0 -0
- data/example/rails5/public/favicon.ico +0 -0
- data/example/rails5/public/robots.txt +0 -5
- data/example/rails5/spec/controllers/hello_controller_spec.rb +0 -10
- data/example/rails5/spec/rails_helper.rb +0 -57
- data/example/rails5/spec/spec_helper.rb +0 -99
- data/example/rails5/vendor/assets/javascripts/.keep +0 -0
- data/example/rails5/vendor/assets/stylesheets/.keep +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c8e8c03cf1b03abb219ce366f186470e1463b076
|
|
4
|
+
data.tar.gz: 66ebdaa2cf3853bc60ae5ffcadb06716b38d9558
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 73a13a6749b1e4da13e799edad40fdda78b61c8b97a172bb806de803a3128667ae9dd5558b1f77046168988505f51feb9759fde290443a4f7c3a72e06ee339a2
|
|
7
|
+
data.tar.gz: 84437cfd8af9b5882c525532eb0d94436521b2b99e9dc8fe04e25967794701c94a7fceef1375f8b9c8a0f995c1f2060e145afe534c296b0c0a040ce3bd1d7cb4
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# Rack::ActionLogger
|
|
2
2
|
|
|
3
|
+
[](https://circleci.com/gh/wapa5pow/rack-action_logger)
|
|
4
|
+
[](https://badge.fury.io/rb/rack-action_logger)
|
|
5
|
+
[](https://codeclimate.com/github/wapa5pow/rack-action_logger)
|
|
6
|
+
|
|
3
7
|
**Rack::ActionLogger** is a tool to collect user action logs via fluentd, Rails.logger or any custome logger.
|
|
4
8
|
|
|
5
9
|
It is intended to collect user request log, action log and any other custome logs.
|
|
@@ -23,7 +27,9 @@ gem 'fluent-logger'
|
|
|
23
27
|
|
|
24
28
|
And then execute:
|
|
25
29
|
|
|
26
|
-
|
|
30
|
+
```
|
|
31
|
+
bundle
|
|
32
|
+
```
|
|
27
33
|
|
|
28
34
|
Then, add Rack::ActionLogger as middleware to config/application.rb.
|
|
29
35
|
|
|
@@ -31,15 +37,17 @@ Then, add Rack::ActionLogger as middleware to config/application.rb.
|
|
|
31
37
|
config.middleware.use Rack::ActionLogger
|
|
32
38
|
```
|
|
33
39
|
|
|
40
|
+
### Setup Initializations
|
|
41
|
+
|
|
34
42
|
Under config/initializers, add the following files.
|
|
35
|
-
|
|
36
|
-
|
|
43
|
+
|
|
44
|
+
#### fluent_logger.rb
|
|
37
45
|
|
|
38
46
|
```ruby
|
|
39
47
|
Fluent::Logger::FluentLogger.open
|
|
40
48
|
```
|
|
41
49
|
|
|
42
|
-
|
|
50
|
+
#### rack-action_logger.rb
|
|
43
51
|
|
|
44
52
|
```ruby
|
|
45
53
|
Rack::ActionLogger.configure do |config|
|
|
@@ -90,6 +98,33 @@ Rack::ActionLogger::Container.merge_attributes({ user_id: 123 })
|
|
|
90
98
|
|
|
91
99
|

|
|
92
100
|
|
|
101
|
+
### Logs out of request
|
|
102
|
+
|
|
103
|
+
If Rails app uses background job system like sidekiq, exported context (e.g. log attributes and request_id) can be passed to the job.
|
|
104
|
+
|
|
105
|
+
For example, a worker is the following.
|
|
106
|
+
|
|
107
|
+
```ruby
|
|
108
|
+
class TestWorker < ApplicationController
|
|
109
|
+
include Sidekiq::Worker
|
|
110
|
+
sidekiq_options queue: :test, retry: 5
|
|
111
|
+
|
|
112
|
+
def perform(title, context)
|
|
113
|
+
Rack::ActionLogger::Emitter.new.emit(context) do
|
|
114
|
+
Rack::ActionLogger::Container.set_append_log({ title: title }, 'action.worker')
|
|
115
|
+
p 'work: title=' + title
|
|
116
|
+
end
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
end
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
To call the worker task, the app should call like the following.
|
|
123
|
+
|
|
124
|
+
```ruby
|
|
125
|
+
action_log_context = Rack::ActionLogger::Container.export
|
|
126
|
+
TestWorker.perform_async('Worker Job', action_log_context)
|
|
127
|
+
```
|
|
93
128
|
|
|
94
129
|
## Development
|
|
95
130
|
|
data/lib/rack/action_logger.rb
CHANGED
data/rack-action_logger.gemspec
CHANGED
|
@@ -15,7 +15,7 @@ Gem::Specification.new do |spec|
|
|
|
15
15
|
spec.license = 'MIT'
|
|
16
16
|
|
|
17
17
|
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
|
18
|
-
f.match(%r{^(test|spec|features)/})
|
|
18
|
+
f.match(%r{^(test|spec|features|docs|example)/})
|
|
19
19
|
end
|
|
20
20
|
spec.bindir = 'exe'
|
|
21
21
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rack-action_logger
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Koichi Ishida
|
|
@@ -99,156 +99,13 @@ files:
|
|
|
99
99
|
- bin/console
|
|
100
100
|
- bin/rspec
|
|
101
101
|
- bin/setup
|
|
102
|
-
- docs/action_log.png
|
|
103
|
-
- docs/attributed_log.png
|
|
104
|
-
- docs/request_log.png
|
|
105
|
-
- docs/sample_log.png
|
|
106
|
-
- example/rails4/.generators
|
|
107
|
-
- example/rails4/.gitignore
|
|
108
|
-
- example/rails4/.rakeTasks
|
|
109
|
-
- example/rails4/Gemfile
|
|
110
|
-
- example/rails4/Gemfile.lock
|
|
111
|
-
- example/rails4/README.rdoc
|
|
112
|
-
- example/rails4/Rakefile
|
|
113
|
-
- example/rails4/app/assets/images/.keep
|
|
114
|
-
- example/rails4/app/assets/javascripts/application.js
|
|
115
|
-
- example/rails4/app/assets/javascripts/hello.coffee
|
|
116
|
-
- example/rails4/app/assets/stylesheets/application.css
|
|
117
|
-
- example/rails4/app/assets/stylesheets/hello.scss
|
|
118
|
-
- example/rails4/app/controllers/application_controller.rb
|
|
119
|
-
- example/rails4/app/controllers/concerns/.keep
|
|
120
|
-
- example/rails4/app/controllers/hello_controller.rb
|
|
121
|
-
- example/rails4/app/helpers/application_helper.rb
|
|
122
|
-
- example/rails4/app/helpers/hello_helper.rb
|
|
123
|
-
- example/rails4/app/mailers/.keep
|
|
124
|
-
- example/rails4/app/models/.keep
|
|
125
|
-
- example/rails4/app/models/concerns/.keep
|
|
126
|
-
- example/rails4/app/views/hello/index.html.erb
|
|
127
|
-
- example/rails4/app/views/layouts/application.html.erb
|
|
128
|
-
- example/rails4/bin/bundle
|
|
129
|
-
- example/rails4/bin/rails
|
|
130
|
-
- example/rails4/bin/rake
|
|
131
|
-
- example/rails4/bin/rspec
|
|
132
|
-
- example/rails4/bin/setup
|
|
133
|
-
- example/rails4/config.ru
|
|
134
|
-
- example/rails4/config/application.rb
|
|
135
|
-
- example/rails4/config/boot.rb
|
|
136
|
-
- example/rails4/config/database.yml
|
|
137
|
-
- example/rails4/config/environment.rb
|
|
138
|
-
- example/rails4/config/environments/development.rb
|
|
139
|
-
- example/rails4/config/environments/production.rb
|
|
140
|
-
- example/rails4/config/environments/test.rb
|
|
141
|
-
- example/rails4/config/initializers/assets.rb
|
|
142
|
-
- example/rails4/config/initializers/backtrace_silencers.rb
|
|
143
|
-
- example/rails4/config/initializers/cookies_serializer.rb
|
|
144
|
-
- example/rails4/config/initializers/filter_parameter_logging.rb
|
|
145
|
-
- example/rails4/config/initializers/fluent_logger.rb
|
|
146
|
-
- example/rails4/config/initializers/inflections.rb
|
|
147
|
-
- example/rails4/config/initializers/mime_types.rb
|
|
148
|
-
- example/rails4/config/initializers/rack-action_logger.rb
|
|
149
|
-
- example/rails4/config/initializers/session_store.rb
|
|
150
|
-
- example/rails4/config/initializers/wrap_parameters.rb
|
|
151
|
-
- example/rails4/config/locales/en.yml
|
|
152
|
-
- example/rails4/config/routes.rb
|
|
153
|
-
- example/rails4/config/secrets.yml
|
|
154
|
-
- example/rails4/db/schema.rb
|
|
155
|
-
- example/rails4/db/seeds.rb
|
|
156
|
-
- example/rails4/lib/assets/.keep
|
|
157
|
-
- example/rails4/lib/tasks/.keep
|
|
158
|
-
- example/rails4/public/404.html
|
|
159
|
-
- example/rails4/public/422.html
|
|
160
|
-
- example/rails4/public/500.html
|
|
161
|
-
- example/rails4/public/favicon.ico
|
|
162
|
-
- example/rails4/public/robots.txt
|
|
163
|
-
- example/rails4/spec/controllers/hello_controller_spec.rb
|
|
164
|
-
- example/rails4/spec/rails_helper.rb
|
|
165
|
-
- example/rails4/spec/spec_helper.rb
|
|
166
|
-
- example/rails4/vendor/assets/javascripts/.keep
|
|
167
|
-
- example/rails4/vendor/assets/stylesheets/.keep
|
|
168
|
-
- example/rails5/.generators
|
|
169
|
-
- example/rails5/.gitignore
|
|
170
|
-
- example/rails5/.rakeTasks
|
|
171
|
-
- example/rails5/Gemfile
|
|
172
|
-
- example/rails5/Gemfile.lock
|
|
173
|
-
- example/rails5/README.md
|
|
174
|
-
- example/rails5/Rakefile
|
|
175
|
-
- example/rails5/app/assets/config/manifest.js
|
|
176
|
-
- example/rails5/app/assets/images/.keep
|
|
177
|
-
- example/rails5/app/assets/javascripts/application.js
|
|
178
|
-
- example/rails5/app/assets/javascripts/cable.js
|
|
179
|
-
- example/rails5/app/assets/javascripts/channels/.keep
|
|
180
|
-
- example/rails5/app/assets/javascripts/hello.coffee
|
|
181
|
-
- example/rails5/app/assets/stylesheets/application.css
|
|
182
|
-
- example/rails5/app/assets/stylesheets/hello.scss
|
|
183
|
-
- example/rails5/app/channels/application_cable/channel.rb
|
|
184
|
-
- example/rails5/app/channels/application_cable/connection.rb
|
|
185
|
-
- example/rails5/app/controllers/application_controller.rb
|
|
186
|
-
- example/rails5/app/controllers/concerns/.keep
|
|
187
|
-
- example/rails5/app/controllers/hello_controller.rb
|
|
188
|
-
- example/rails5/app/helpers/application_helper.rb
|
|
189
|
-
- example/rails5/app/helpers/hello_helper.rb
|
|
190
|
-
- example/rails5/app/jobs/application_job.rb
|
|
191
|
-
- example/rails5/app/mailers/application_mailer.rb
|
|
192
|
-
- example/rails5/app/models/application_record.rb
|
|
193
|
-
- example/rails5/app/models/concerns/.keep
|
|
194
|
-
- example/rails5/app/views/hello/index.html.erb
|
|
195
|
-
- example/rails5/app/views/layouts/application.html.erb
|
|
196
|
-
- example/rails5/app/views/layouts/mailer.html.erb
|
|
197
|
-
- example/rails5/app/views/layouts/mailer.text.erb
|
|
198
|
-
- example/rails5/bin/bundle
|
|
199
|
-
- example/rails5/bin/rails
|
|
200
|
-
- example/rails5/bin/rake
|
|
201
|
-
- example/rails5/bin/rspec
|
|
202
|
-
- example/rails5/bin/setup
|
|
203
|
-
- example/rails5/bin/update
|
|
204
|
-
- example/rails5/config.ru
|
|
205
|
-
- example/rails5/config/application.rb
|
|
206
|
-
- example/rails5/config/boot.rb
|
|
207
|
-
- example/rails5/config/cable.yml
|
|
208
|
-
- example/rails5/config/database.yml
|
|
209
|
-
- example/rails5/config/environment.rb
|
|
210
|
-
- example/rails5/config/environments/development.rb
|
|
211
|
-
- example/rails5/config/environments/production.rb
|
|
212
|
-
- example/rails5/config/environments/test.rb
|
|
213
|
-
- example/rails5/config/initializers/application_controller_renderer.rb
|
|
214
|
-
- example/rails5/config/initializers/assets.rb
|
|
215
|
-
- example/rails5/config/initializers/backtrace_silencers.rb
|
|
216
|
-
- example/rails5/config/initializers/cookies_serializer.rb
|
|
217
|
-
- example/rails5/config/initializers/filter_parameter_logging.rb
|
|
218
|
-
- example/rails5/config/initializers/fluent_logger.rb
|
|
219
|
-
- example/rails5/config/initializers/inflections.rb
|
|
220
|
-
- example/rails5/config/initializers/mime_types.rb
|
|
221
|
-
- example/rails5/config/initializers/new_framework_defaults.rb
|
|
222
|
-
- example/rails5/config/initializers/rack-action_logger.rb
|
|
223
|
-
- example/rails5/config/initializers/session_store.rb
|
|
224
|
-
- example/rails5/config/initializers/wrap_parameters.rb
|
|
225
|
-
- example/rails5/config/locales/en.yml
|
|
226
|
-
- example/rails5/config/puma.rb
|
|
227
|
-
- example/rails5/config/routes.rb
|
|
228
|
-
- example/rails5/config/secrets.yml
|
|
229
|
-
- example/rails5/config/spring.rb
|
|
230
|
-
- example/rails5/db/schema.rb
|
|
231
|
-
- example/rails5/db/seeds.rb
|
|
232
|
-
- example/rails5/lib/assets/.keep
|
|
233
|
-
- example/rails5/lib/tasks/.keep
|
|
234
|
-
- example/rails5/public/404.html
|
|
235
|
-
- example/rails5/public/422.html
|
|
236
|
-
- example/rails5/public/500.html
|
|
237
|
-
- example/rails5/public/apple-touch-icon-precomposed.png
|
|
238
|
-
- example/rails5/public/apple-touch-icon.png
|
|
239
|
-
- example/rails5/public/favicon.ico
|
|
240
|
-
- example/rails5/public/robots.txt
|
|
241
|
-
- example/rails5/spec/controllers/hello_controller_spec.rb
|
|
242
|
-
- example/rails5/spec/rails_helper.rb
|
|
243
|
-
- example/rails5/spec/spec_helper.rb
|
|
244
|
-
- example/rails5/vendor/assets/javascripts/.keep
|
|
245
|
-
- example/rails5/vendor/assets/stylesheets/.keep
|
|
246
102
|
- lib/rack/action_logger.rb
|
|
247
103
|
- lib/rack/action_logger/configuration.rb
|
|
248
104
|
- lib/rack/action_logger/container.rb
|
|
249
105
|
- lib/rack/action_logger/context.rb
|
|
250
106
|
- lib/rack/action_logger/controller_concerns.rb
|
|
251
107
|
- lib/rack/action_logger/controller_concerns/request_log.rb
|
|
108
|
+
- lib/rack/action_logger/emit_adapter.rb
|
|
252
109
|
- lib/rack/action_logger/emit_adapter/base.rb
|
|
253
110
|
- lib/rack/action_logger/emit_adapter/fluent_adapter.rb
|
|
254
111
|
- lib/rack/action_logger/emit_adapter/logger_adapter.rb
|
data/docs/action_log.png
DELETED
|
Binary file
|
data/docs/attributed_log.png
DELETED
|
Binary file
|
data/docs/request_log.png
DELETED
|
Binary file
|
data/docs/sample_log.png
DELETED
|
Binary file
|
data/example/rails4/.generators
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<Settings><!--This file was automatically generated by Ruby plugin.
|
|
3
|
-
You are allowed to:
|
|
4
|
-
1. Reorder generators
|
|
5
|
-
2. Remove generators
|
|
6
|
-
3. Add installed generators
|
|
7
|
-
To add new installed generators automatically delete this file and reload the project.
|
|
8
|
-
--><GeneratorsGroup><Generator name="assets" /><Generator name="coffee:assets" /><Generator name="controller" /><Generator name="generator" /><Generator name="helper" /><Generator name="integration_test" /><Generator name="jbuilder" /><Generator name="job" /><Generator name="js:assets" /><Generator name="mailer" /><Generator name="migration" /><Generator name="model" /><Generator name="resource" /><Generator name="scaffold" /><Generator name="scaffold_controller" /><Generator name="task" /><Generator name="test_unit:controller" /><Generator name="test_unit:generator" /><Generator name="test_unit:helper" /><Generator name="test_unit:integration" /><Generator name="test_unit:job" /><Generator name="test_unit:mailer" /><Generator name="test_unit:model" /><Generator name="test_unit:plugin" /><Generator name="test_unit:scaffold" /></GeneratorsGroup></Settings>
|
data/example/rails4/.gitignore
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# Created by https://www.gitignore.io/api/rails
|
|
3
|
-
|
|
4
|
-
### Rails ###
|
|
5
|
-
*.rbc
|
|
6
|
-
capybara-*.html
|
|
7
|
-
.rspec
|
|
8
|
-
/log
|
|
9
|
-
/tmp
|
|
10
|
-
/db/*.sqlite3
|
|
11
|
-
/db/*.sqlite3-journal
|
|
12
|
-
/public/system
|
|
13
|
-
/coverage/
|
|
14
|
-
/spec/tmp
|
|
15
|
-
**.orig
|
|
16
|
-
rerun.txt
|
|
17
|
-
pickle-email-*.html
|
|
18
|
-
|
|
19
|
-
# TODO Comment out this rule if you are OK with secrets being uploaded to the repo
|
|
20
|
-
config/initializers/secret_token.rb
|
|
21
|
-
|
|
22
|
-
# Only include if you have production secrets in this file, which is no longer a Rails default
|
|
23
|
-
# config/secrets.yml
|
|
24
|
-
|
|
25
|
-
# dotenv
|
|
26
|
-
# TODO Comment out this rule if environment variables can be committed
|
|
27
|
-
.env
|
|
28
|
-
|
|
29
|
-
## Environment normalization:
|
|
30
|
-
/.bundle
|
|
31
|
-
/vendor/bundle
|
|
32
|
-
|
|
33
|
-
# these should all be checked in to normalize the environment:
|
|
34
|
-
# Gemfile.lock, .ruby-version, .ruby-gemset
|
|
35
|
-
|
|
36
|
-
# unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
|
|
37
|
-
.rvmrc
|
|
38
|
-
|
|
39
|
-
# if using bower-rails ignore default bower_components path bower.json files
|
|
40
|
-
/vendor/assets/bower_components
|
|
41
|
-
*.bowerrc
|
|
42
|
-
bower.json
|
|
43
|
-
|
|
44
|
-
# Ignore pow environment settings
|
|
45
|
-
.powenv
|
|
46
|
-
|
|
47
|
-
# Ignore Byebug command history file.
|
|
48
|
-
.byebug_history
|
data/example/rails4/.rakeTasks
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<Settings><!--This file was automatically generated by Ruby plugin.
|
|
3
|
-
You are allowed to:
|
|
4
|
-
1. Remove rake task
|
|
5
|
-
2. Add existing rake tasks
|
|
6
|
-
To add existing rake tasks automatically delete this file and reload the project.
|
|
7
|
-
--><RakeGroup description="" fullCmd="" taksId="rake" /></Settings>
|
data/example/rails4/Gemfile
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
source 'https://rubygems.org'
|
|
2
|
-
|
|
3
|
-
# Install developed gem
|
|
4
|
-
gem 'rack-action_logger', path: '../..'
|
|
5
|
-
|
|
6
|
-
gem 'fluent-logger'
|
|
7
|
-
|
|
8
|
-
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
|
|
9
|
-
gem 'rails', '4.2.7.1'
|
|
10
|
-
# Use sqlite3 as the database for Active Record
|
|
11
|
-
gem 'sqlite3'
|
|
12
|
-
# Use SCSS for stylesheets
|
|
13
|
-
gem 'sass-rails', '~> 5.0'
|
|
14
|
-
# Use Uglifier as compressor for JavaScript assets
|
|
15
|
-
gem 'uglifier', '>= 1.3.0'
|
|
16
|
-
# Use CoffeeScript for .coffee assets and views
|
|
17
|
-
gem 'coffee-rails', '~> 4.1.0'
|
|
18
|
-
# See https://github.com/rails/execjs#readme for more supported runtimes
|
|
19
|
-
# gem 'therubyracer', platforms: :ruby
|
|
20
|
-
|
|
21
|
-
# Use jquery as the JavaScript library
|
|
22
|
-
gem 'jquery-rails'
|
|
23
|
-
# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
|
|
24
|
-
gem 'turbolinks'
|
|
25
|
-
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
|
|
26
|
-
gem 'jbuilder', '~> 2.0'
|
|
27
|
-
# bundle exec rake doc:rails generates the API under doc/api.
|
|
28
|
-
gem 'sdoc', '~> 0.4.0', group: :doc
|
|
29
|
-
|
|
30
|
-
# Use ActiveModel has_secure_password
|
|
31
|
-
# gem 'bcrypt', '~> 3.1.7'
|
|
32
|
-
|
|
33
|
-
# Use Unicorn as the app server
|
|
34
|
-
# gem 'unicorn'
|
|
35
|
-
|
|
36
|
-
# Use Capistrano for deployment
|
|
37
|
-
# gem 'capistrano-rails', group: :development
|
|
38
|
-
|
|
39
|
-
group :development, :test do
|
|
40
|
-
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
|
|
41
|
-
gem 'byebug'
|
|
42
|
-
|
|
43
|
-
gem 'rspec-rails'
|
|
44
|
-
end
|
|
45
|
-
|
|
46
|
-
group :development do
|
|
47
|
-
# Access an IRB console on exception pages or by using <%= console %> in views
|
|
48
|
-
gem 'web-console', '~> 2.0'
|
|
49
|
-
|
|
50
|
-
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
|
|
51
|
-
gem 'spring'
|
|
52
|
-
end
|
|
53
|
-
|
data/example/rails4/Gemfile.lock
DELETED
|
@@ -1,192 +0,0 @@
|
|
|
1
|
-
PATH
|
|
2
|
-
remote: ../..
|
|
3
|
-
specs:
|
|
4
|
-
rack-action_logger (0.1.0)
|
|
5
|
-
activesupport
|
|
6
|
-
fluent-logger (~> 0.5)
|
|
7
|
-
|
|
8
|
-
GEM
|
|
9
|
-
remote: https://rubygems.org/
|
|
10
|
-
specs:
|
|
11
|
-
actionmailer (4.2.7.1)
|
|
12
|
-
actionpack (= 4.2.7.1)
|
|
13
|
-
actionview (= 4.2.7.1)
|
|
14
|
-
activejob (= 4.2.7.1)
|
|
15
|
-
mail (~> 2.5, >= 2.5.4)
|
|
16
|
-
rails-dom-testing (~> 1.0, >= 1.0.5)
|
|
17
|
-
actionpack (4.2.7.1)
|
|
18
|
-
actionview (= 4.2.7.1)
|
|
19
|
-
activesupport (= 4.2.7.1)
|
|
20
|
-
rack (~> 1.6)
|
|
21
|
-
rack-test (~> 0.6.2)
|
|
22
|
-
rails-dom-testing (~> 1.0, >= 1.0.5)
|
|
23
|
-
rails-html-sanitizer (~> 1.0, >= 1.0.2)
|
|
24
|
-
actionview (4.2.7.1)
|
|
25
|
-
activesupport (= 4.2.7.1)
|
|
26
|
-
builder (~> 3.1)
|
|
27
|
-
erubis (~> 2.7.0)
|
|
28
|
-
rails-dom-testing (~> 1.0, >= 1.0.5)
|
|
29
|
-
rails-html-sanitizer (~> 1.0, >= 1.0.2)
|
|
30
|
-
activejob (4.2.7.1)
|
|
31
|
-
activesupport (= 4.2.7.1)
|
|
32
|
-
globalid (>= 0.3.0)
|
|
33
|
-
activemodel (4.2.7.1)
|
|
34
|
-
activesupport (= 4.2.7.1)
|
|
35
|
-
builder (~> 3.1)
|
|
36
|
-
activerecord (4.2.7.1)
|
|
37
|
-
activemodel (= 4.2.7.1)
|
|
38
|
-
activesupport (= 4.2.7.1)
|
|
39
|
-
arel (~> 6.0)
|
|
40
|
-
activesupport (4.2.7.1)
|
|
41
|
-
i18n (~> 0.7)
|
|
42
|
-
json (~> 1.7, >= 1.7.7)
|
|
43
|
-
minitest (~> 5.1)
|
|
44
|
-
thread_safe (~> 0.3, >= 0.3.4)
|
|
45
|
-
tzinfo (~> 1.1)
|
|
46
|
-
arel (6.0.3)
|
|
47
|
-
binding_of_caller (0.7.2)
|
|
48
|
-
debug_inspector (>= 0.0.1)
|
|
49
|
-
builder (3.2.2)
|
|
50
|
-
byebug (9.0.6)
|
|
51
|
-
coffee-rails (4.1.1)
|
|
52
|
-
coffee-script (>= 2.2.0)
|
|
53
|
-
railties (>= 4.0.0, < 5.1.x)
|
|
54
|
-
coffee-script (2.4.1)
|
|
55
|
-
coffee-script-source
|
|
56
|
-
execjs
|
|
57
|
-
coffee-script-source (1.10.0)
|
|
58
|
-
concurrent-ruby (1.0.2)
|
|
59
|
-
debug_inspector (0.0.2)
|
|
60
|
-
diff-lcs (1.2.5)
|
|
61
|
-
erubis (2.7.0)
|
|
62
|
-
execjs (2.7.0)
|
|
63
|
-
fluent-logger (0.6.1)
|
|
64
|
-
msgpack (>= 0.5.6, < 2)
|
|
65
|
-
globalid (0.3.7)
|
|
66
|
-
activesupport (>= 4.1.0)
|
|
67
|
-
i18n (0.7.0)
|
|
68
|
-
jbuilder (2.6.0)
|
|
69
|
-
activesupport (>= 3.0.0, < 5.1)
|
|
70
|
-
multi_json (~> 1.2)
|
|
71
|
-
jquery-rails (4.2.1)
|
|
72
|
-
rails-dom-testing (>= 1, < 3)
|
|
73
|
-
railties (>= 4.2.0)
|
|
74
|
-
thor (>= 0.14, < 2.0)
|
|
75
|
-
json (1.8.3)
|
|
76
|
-
loofah (2.0.3)
|
|
77
|
-
nokogiri (>= 1.5.9)
|
|
78
|
-
mail (2.6.4)
|
|
79
|
-
mime-types (>= 1.16, < 4)
|
|
80
|
-
mime-types (3.1)
|
|
81
|
-
mime-types-data (~> 3.2015)
|
|
82
|
-
mime-types-data (3.2016.0521)
|
|
83
|
-
mini_portile2 (2.1.0)
|
|
84
|
-
minitest (5.9.1)
|
|
85
|
-
msgpack (1.0.2)
|
|
86
|
-
multi_json (1.12.1)
|
|
87
|
-
nokogiri (1.6.8.1)
|
|
88
|
-
mini_portile2 (~> 2.1.0)
|
|
89
|
-
rack (1.6.5)
|
|
90
|
-
rack-test (0.6.3)
|
|
91
|
-
rack (>= 1.0)
|
|
92
|
-
rails (4.2.7.1)
|
|
93
|
-
actionmailer (= 4.2.7.1)
|
|
94
|
-
actionpack (= 4.2.7.1)
|
|
95
|
-
actionview (= 4.2.7.1)
|
|
96
|
-
activejob (= 4.2.7.1)
|
|
97
|
-
activemodel (= 4.2.7.1)
|
|
98
|
-
activerecord (= 4.2.7.1)
|
|
99
|
-
activesupport (= 4.2.7.1)
|
|
100
|
-
bundler (>= 1.3.0, < 2.0)
|
|
101
|
-
railties (= 4.2.7.1)
|
|
102
|
-
sprockets-rails
|
|
103
|
-
rails-deprecated_sanitizer (1.0.3)
|
|
104
|
-
activesupport (>= 4.2.0.alpha)
|
|
105
|
-
rails-dom-testing (1.0.7)
|
|
106
|
-
activesupport (>= 4.2.0.beta, < 5.0)
|
|
107
|
-
nokogiri (~> 1.6.0)
|
|
108
|
-
rails-deprecated_sanitizer (>= 1.0.1)
|
|
109
|
-
rails-html-sanitizer (1.0.3)
|
|
110
|
-
loofah (~> 2.0)
|
|
111
|
-
railties (4.2.7.1)
|
|
112
|
-
actionpack (= 4.2.7.1)
|
|
113
|
-
activesupport (= 4.2.7.1)
|
|
114
|
-
rake (>= 0.8.7)
|
|
115
|
-
thor (>= 0.18.1, < 2.0)
|
|
116
|
-
rake (11.3.0)
|
|
117
|
-
rdoc (4.3.0)
|
|
118
|
-
rspec-core (3.5.4)
|
|
119
|
-
rspec-support (~> 3.5.0)
|
|
120
|
-
rspec-expectations (3.5.0)
|
|
121
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
|
122
|
-
rspec-support (~> 3.5.0)
|
|
123
|
-
rspec-mocks (3.5.0)
|
|
124
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
|
125
|
-
rspec-support (~> 3.5.0)
|
|
126
|
-
rspec-rails (3.5.2)
|
|
127
|
-
actionpack (>= 3.0)
|
|
128
|
-
activesupport (>= 3.0)
|
|
129
|
-
railties (>= 3.0)
|
|
130
|
-
rspec-core (~> 3.5.0)
|
|
131
|
-
rspec-expectations (~> 3.5.0)
|
|
132
|
-
rspec-mocks (~> 3.5.0)
|
|
133
|
-
rspec-support (~> 3.5.0)
|
|
134
|
-
rspec-support (3.5.0)
|
|
135
|
-
sass (3.4.22)
|
|
136
|
-
sass-rails (5.0.6)
|
|
137
|
-
railties (>= 4.0.0, < 6)
|
|
138
|
-
sass (~> 3.1)
|
|
139
|
-
sprockets (>= 2.8, < 4.0)
|
|
140
|
-
sprockets-rails (>= 2.0, < 4.0)
|
|
141
|
-
tilt (>= 1.1, < 3)
|
|
142
|
-
sdoc (0.4.2)
|
|
143
|
-
json (~> 1.7, >= 1.7.7)
|
|
144
|
-
rdoc (~> 4.0)
|
|
145
|
-
spring (2.0.0)
|
|
146
|
-
activesupport (>= 4.2)
|
|
147
|
-
sprockets (3.7.0)
|
|
148
|
-
concurrent-ruby (~> 1.0)
|
|
149
|
-
rack (> 1, < 3)
|
|
150
|
-
sprockets-rails (3.2.0)
|
|
151
|
-
actionpack (>= 4.0)
|
|
152
|
-
activesupport (>= 4.0)
|
|
153
|
-
sprockets (>= 3.0.0)
|
|
154
|
-
sqlite3 (1.3.12)
|
|
155
|
-
thor (0.19.1)
|
|
156
|
-
thread_safe (0.3.5)
|
|
157
|
-
tilt (2.0.5)
|
|
158
|
-
turbolinks (5.0.1)
|
|
159
|
-
turbolinks-source (~> 5)
|
|
160
|
-
turbolinks-source (5.0.0)
|
|
161
|
-
tzinfo (1.2.2)
|
|
162
|
-
thread_safe (~> 0.1)
|
|
163
|
-
uglifier (3.0.3)
|
|
164
|
-
execjs (>= 0.3.0, < 3)
|
|
165
|
-
web-console (2.3.0)
|
|
166
|
-
activemodel (>= 4.0)
|
|
167
|
-
binding_of_caller (>= 0.7.2)
|
|
168
|
-
railties (>= 4.0)
|
|
169
|
-
sprockets-rails (>= 2.0, < 4.0)
|
|
170
|
-
|
|
171
|
-
PLATFORMS
|
|
172
|
-
ruby
|
|
173
|
-
|
|
174
|
-
DEPENDENCIES
|
|
175
|
-
byebug
|
|
176
|
-
coffee-rails (~> 4.1.0)
|
|
177
|
-
fluent-logger
|
|
178
|
-
jbuilder (~> 2.0)
|
|
179
|
-
jquery-rails
|
|
180
|
-
rack-action_logger!
|
|
181
|
-
rails (= 4.2.7.1)
|
|
182
|
-
rspec-rails
|
|
183
|
-
sass-rails (~> 5.0)
|
|
184
|
-
sdoc (~> 0.4.0)
|
|
185
|
-
spring
|
|
186
|
-
sqlite3
|
|
187
|
-
turbolinks
|
|
188
|
-
uglifier (>= 1.3.0)
|
|
189
|
-
web-console (~> 2.0)
|
|
190
|
-
|
|
191
|
-
BUNDLED WITH
|
|
192
|
-
1.13.6
|
data/example/rails4/README.rdoc
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
== README
|
|
2
|
-
|
|
3
|
-
This README would normally document whatever steps are necessary to get the
|
|
4
|
-
application up and running.
|
|
5
|
-
|
|
6
|
-
Things you may want to cover:
|
|
7
|
-
|
|
8
|
-
* Ruby version
|
|
9
|
-
|
|
10
|
-
* System dependencies
|
|
11
|
-
|
|
12
|
-
* Configuration
|
|
13
|
-
|
|
14
|
-
* Database creation
|
|
15
|
-
|
|
16
|
-
* Database initialization
|
|
17
|
-
|
|
18
|
-
* How to run the test suite
|
|
19
|
-
|
|
20
|
-
* Services (job queues, cache servers, search engines, etc.)
|
|
21
|
-
|
|
22
|
-
* Deployment instructions
|
|
23
|
-
|
|
24
|
-
* ...
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
Please feel free to use a different markup language if you do not plan to run
|
|
28
|
-
<tt>rake doc:app</tt>.
|
data/example/rails4/Rakefile
DELETED
|
File without changes
|