Comments (5)
You might want to check #108 .
There is still one open topic but for me it's minor and should be fixed in another subsequent PR.
Comments welcome.
from logstasher.
Seems problem occurs for any log_level..
As you can see here: https://github.com/shadabahmed/logstasher/blob/master/lib/logstasher/railtie.rb#L7
Logstasher initialized as instance of ActiveSupport::OrderedOptions
:
config.logstasher = ActiveSupport::OrderedOptions.new
But in new rails it also inherit an ActiveSupport
default logger, which sending output to stdout.
And after that.. we moving to setup
method.. where we have already defined logger:
self.logger = app.config.logstasher.logger || new_logger(self.logger_path)
And now at any call of logger
output sends to default ActiveSupport::OrderedOptions
logger..
This can be monkeypatched as follow:
# add this info your development.rb or other environment file
config.to_prepare do
LogStasher.logger = Logger.new("#{Rails.root}/log/logstash_#{Rails.env}.log")
end
from logstasher.
+1 for this issue -- even with the monkey patch, I can't get my development Rails.logger.info
to display anything in the logstash log.
from logstasher.
Same here... Even with the ninja Monkey Patch, no logger calls is logged
from logstasher.
Other then this I'd say get it merged soon as this is really a pain.
from logstasher.
Related Issues (20)
- Custom Fields only works when an Exception is handled HOT 3
- Custom fields are not being added to Request statements in logstasher log HOT 2
- Respect config.log_tags configuration option. HOT 2
- Adding custom fields at the Controller level HOT 1
- Gem initialization not working on MacOS Sierra and later HOT 4
- What's the difference between add_custom_fields and add_custom_fields_to_request_context HOT 3
- Exclude controller parameters HOT 2
- Configuring rotation of logstasher log file HOT 1
- suppress_app_log: true prevent DB timing to be emited HOT 6
- Response Body? HOT 2
- What type of objects can we pass as custom fields ?
- NameError: uninitialized constant LogStasher::ActiveRecord HOT 1
- Logging after action has been processed.
- Cant convince logstasher to write to file instead of console
- How to push logs in elasticsearch HOT 1
- ActiveJob::Logging::LogSubscriber not being unsubscribed HOT 1
- Logstasher custom fields in ApplicationController
- Default message for log lines
- Default log level HOT 3
- Missing ActionContoller event fields due to `#process_action` monkey patch HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from logstasher.