JLog - Journaled Log
C Perl Python Java XS Shell Other
Latest commit 9907d4d Jun 13, 2017 @postwait postwait retry on bulk_read
Permalink
Failed to load latest commit information.
java remove stderr print on java api failure, error check unlink on pre-co… Aug 22, 2016
perl more complete shared lib support Feb 19, 2015
php Replacing broken call to ZVAL_ADDREF with Z_ADDREF_P. Jan 3, 2013
python add new features to java based jlog May 17, 2016
.gitignore Enhance throughput by using a pre-commit buffer space along with a mu… May 16, 2016
CONCEPTS.md Import docs from OmniTI Labs Feb 8, 2017
LICENSE Sync with the ecelerity jlog sources Apr 17, 2008
Makefile.in Bump to Version 2.3.0 May 19, 2017
README.md Import docs from OmniTI Labs Feb 8, 2017
V210_CHANGES.txt further testing and removal of tabs Mar 3, 2016
config.guess allow building as shared object, wire up perl module build Apr 17, 2008
config.sub allow building as shared object, wire up perl module build Apr 17, 2008
configure.in Revert "This is c99 code, but need pwritev which requires visisbility… Feb 9, 2017
fassert.h further testing and removal of tabs Mar 3, 2016
getopt_long.c Use clean-IP getopt implementation. Apr 17, 2008
getopt_long.h Use clean-IP getopt implementation. Apr 17, 2008
install-sh initial import with Ecelerity bits removed and some autoconf glue add… Sep 27, 2007
jlog.c Add jlog_ctx_bulk_read_messages Function May 19, 2017
jlog.h Add jlog_ctx_bulk_read_messages Function May 19, 2017
jlog_change_endian.pl use a perl that's likely there Feb 19, 2015
jlog_compress.c Build on darwin and build clean May 19, 2016
jlog_compress.h Enhance throughput by using a pre-commit buffer space along with a mu… May 16, 2016
jlog_config.h.in Build on darwin and build clean May 19, 2016
jlog_hash.c dead assignments May 26, 2010
jlog_hash.h Sync with the ecelerity jlog sources Apr 17, 2008
jlog_io.c FreeBSD fixes Feb 9, 2017
jlog_io.h use a new multi-process setting to elide file locking when not needed… May 6, 2016
jlog_lz4_compression_provider.h Enhance throughput by using a pre-commit buffer space along with a mu… May 16, 2016
jlog_null_compression_provider.h Enhance throughput by using a pre-commit buffer space along with a mu… May 16, 2016
jlog_private.h obey pre-commit size if specified on any new ctx_open_writer command,… Aug 22, 2016
jlog_sanity_check.pl reverse argument order and add magic_hdr fixing Feb 19, 2015
jlogctl.c clearer error message on failure to open Jan 22, 2015
jlogtail.c add sleep backoff and simplify subscriber removal Dec 13, 2014
jtest.c retry on bulk_read Jun 13, 2017
jthreadtest.c FreeBSD fixes Feb 9, 2017
mkinstalldirs fixup installation of shared lib and perl bits Apr 17, 2008

README.md

JLog

JLog is short for "journaled log" and this package is really an API and implementation that is libjlog. What is libjlog? libjlog is a pure C, very simple durable message queue with multiple subscribers and publishers (both thread- and multi-process safe). The basic concept is that publishers can open a log and write messages to it while subscribers open the log and consume messages from it. "That sounds easy." libjlog abstracts away the need to perform log rotation or maintenance by publishing into fixed size log buffers and eliminating old log buffers when there are no more consumers pending.

Implementation Goal

The goal of libjlog is to provide a dead-simple API, and a very small, uncomplicated implementation. The goal of the JLog is to have others use this project for adding durability to some of their asynchronous notification needs.

Sample Use Case

We run an application on server A and would like to write logs to server B. If server B is down, we don't want to lose logs and we do want A to continue operating. So A writes to a JLog and B consumes from that JLog. Sounds simple, but JLog is a low-level API. The implementor must provide a service on A to which B can connect to consume the JLog messages over the network. If you want to have you cake and eat it too, become a baker and use this fine ingredient!

Read through Concepts for a bit more detail on core concepts and a brief overview of how to use the C API.

Installing

FreeBSD port databases/jlog:

    pkg install jlog

MacOS via Homebrew:

    brew install jlog

If JLog is not packaged by your OS vendor, read on for build instructions.

The LZ4 library is required if you want support for compressed logs.

Java 6 or newer is required if you want to support using JLog from a Java application.

To build from source, clone this repo and then:

autoconf
./configure
make
make install

Team

  • Wez Furlong
  • Alec Peterson
  • George Schlossnagle
  • Theo Schlossnagle
  • Alexey Toptygin (current maintainer)

License

JLog is released under a new BSD license. See our license for details.