Git Product home page Git Product logo

scribe-log4j-appender's Introduction

Scribe log4j Appender
====================================
Much of this work is based on Alex Loddengaard (http://github.com/alexlod/scribe-log4j-appender).

I cleaned up his code to work in non-hadoop environments. I added support to reconnect if it loses a connection or if scribe goes away.

You will need the following libraries for your project, which are in lib/ folder for convenience:

./lib/libthrift-r808609.jar
./lib/log4j-1.2.15.jar
./lib/slf4j-api-1.5.8.jar
./lib/slf4j-log4j12-1.5.8.jar

Example to enable in log4j:

# Add scribe to end of rootLogger:

log4j.rootLogger=DEBUG,stdout,scribe

#
# Add this to your log4j.properties
#
# You can adjust the scribe_host and scribe_port you want messages sent to by setting
# scribe_host and scribe_port
#
# You can also set the hostname if you do not want to rely on Java picking the correct hostname

log4j.appender.scribe=org.apache.log4j.scribe.ScribeAppender
log4j.appender.scribe.scribe_category=MyScribeCategoryName
log4j.appender.scribe.DatePattern='.'yyyy-MM-dd-HH
log4j.appender.scribe.layout=org.apache.log4j.PatternLayout
log4j.appender.scribe.layout.ConversionPattern=%5p [%t] %d{ISO8601} %F (line %L) %m%n

scribe-log4j-appender's People

Contributors

lenn0x avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.