2405 Commits

Author SHA1 Message Date
Michael Biebl
5ab3e8005f Fix compiler warnings
include <string.h> for memcpy and strlen.

Signed-off-by: Rainer Gerhards <rgerhards@adiscon.com>
2009-05-19 07:31:22 +02:00
Michael Biebl
735a02c656 Cleanup and typo fixes
Signed-off-by: Rainer Gerhards <rgerhards@adiscon.com>
2009-05-19 07:31:22 +02:00
Michael Biebl
81875845e6 Add autogen.sh
This file is useful for building rsyslog from git.
It is a shortcut for
autoreconf and ./configure and enables shave by default.

Signed-off-by: Rainer Gerhards <rgerhards@adiscon.com>
2009-05-19 07:31:21 +02:00
Michael Biebl
1bbd2b07f8 Add shave support
shave tranforms the verbose autotools output into a pretty Kbuild-like
one which makes it easier to spot warnings.

See also
http://damien.lespiau.name/blog/2009/02/18/shave-making-the-autotools-output-sane/
git clone git://git.lespiau.name/shave

By default, shave is disabled and you have to explicitly enable it via
./configure --enable-shave.

Signed-off-by: Rainer Gerhards <rgerhards@adiscon.com>
2009-05-19 07:31:21 +02:00
Rainer Gerhards
d1985c4a65 doc: given some concrete advise on the common %hostname% content problem 2009-05-11 22:00:48 +02:00
Rainer Gerhards
8e430258fd added capability to draw configuration graphs
- added $GenerateConfigGraph configuration command which can be used
  to generate nice-looking (and very informative) rsyslog configuration
  graphs.
- added $ActionName configuration directive (currently only used for
  graph generation, but may find other uses)
2009-05-11 17:38:33 +02:00
Luis Fernando Muñoz Mejías
9823c73d1d Make it recover from errors on insertions.
If the database rejected some entry, making the statement fail on it,
the batch was not cleaned and the same values were retried over and
over, causing a cascade of failures and a denial of service.

We use now OCI_BATCH_ERRORS so that everything valid in the batch is
inserted, and rejected values can be discarded.
2009-04-29 17:10:19 +02:00
Luis Fernando Muñoz Mejías
c35ce31aed Replace get_db_statement by a template.
Instead of reading a complete line, we'll use a template and delegate
in the core to read such template. Then, all omoracle has to do is to
find that template and use it as the prepared statement.

I'm not sure if this is the correct approach, though. It has to dig
too much into rsyslog's structures...

txt_statement is stored in a private area, so that we don't mess too
much with rsyslog's internals (I still don't feel comfortable with
this much digging into template structures).
2009-04-29 17:10:00 +02:00
Luis Fernando Muñoz Mejías
65a69831e9 Add the $OmoracleBatchItemSize directive
This directive controls the amount of memory needed for properties in
the batch. Users should specify the largest value they expect in the
statement. As per Rainer's comment:

on MAX_BUFSIZE: I'd tend to make this configurable, because with
RFC5424 messages can be much longer and RFC5425 now recommends a
minimum maximum size of 8K.

So we let users to choose. Maybe we need a sensible default value to
make users' lifes easier?

Also, the old non-vector based interface is not supported anymore. I
broke it already when moving to this stage.
2009-04-29 17:09:20 +02:00
Luis Fernando Muñoz Mejías
e65a30ddaa Add licensing information.
I'm not sure if GPLv3 contemplates the ability to link to proprietary
software, if it was previous work. I explicitly allow linking to OCI.
2009-04-29 17:08:37 +02:00
Rainer Gerhards
42c3dcfc1c performance enhancement: imtcp calls parser no longer on input thread
but rather inside on of the potentially many main msg queue worker
threads (an enhancement scheduled for all input plugins where this is
possible)
2009-04-23 13:39:11 +02:00
Rainer Gerhards
925a5e3471 Merge branch 'beta'
Conflicts:
	ChangeLog
	configure.ac
	doc/manual.html
2009-04-23 11:48:47 +02:00
Rainer Gerhards
f8d9aad082 bugfix: compile problems in im3195 2009-04-23 11:45:50 +02:00
Rainer Gerhards
b38a2208f4 Merge branch 'v3-stable' into beta
Conflicts:
	ChangeLog
	runtime/queue.c
2009-04-23 11:43:12 +02:00
Rainer Gerhards
2e51c75938 bugfix: light and full delay watermarks had invalid values
... badly affecting performance for delayable inputs (but not causeing
any other issues)
2009-04-23 11:33:40 +02:00
Rainer Gerhards
251e48a34c preparing for 4.1.7 v4.1.7 2009-04-22 08:52:13 +02:00
Rainer Gerhards
029218df5b another typo fix... 2009-04-22 08:38:25 +02:00
Rainer Gerhards
1f08d919fd typo fix (important typo) 2009-04-21 17:32:51 +02:00
Rainer Gerhards
8f1fc598c7 doc status update & typo fixes 2009-04-21 17:01:29 +02:00
Rainer Gerhards
9e99fa5812 Merge branch 'nextmaster' 2009-04-21 16:55:09 +02:00
Rainer Gerhards
88caccecf8 Merge branch 'master' into beta
Conflicts:
	ChangeLog
	configure.ac
	doc/manual.html
2009-04-21 16:54:05 +02:00
Rainer Gerhards
6e410a76f6 preparing for 3.22.0 (move to stable) v3.22.0 2009-04-21 16:49:46 +02:00
Rainer Gerhards
aa43d7f831 doc: added (hopefully) easier to grasp queue explanation 2009-04-21 16:32:33 +02:00
Rainer Gerhards
1fb5cee04d improved testbench - added tests for queue disk-only mode 2009-04-17 17:53:33 +02:00
Rainer Gerhards
889a0a1da8 some cleanup
... mostly removal of compile-time warnings (thanks to Michael
Biebl for suggesting to look after that)
2009-04-17 15:19:57 +02:00
Rainer Gerhards
09ca443377 update project status & cleanup
removed some warning in imklog compilation, but may not have
solved a lurking issue (but placed comment so that we know if
something surfaces)
2009-04-17 15:10:06 +02:00
Rainer Gerhards
dc777849fc bugfix: missing header (platform compatibility issue) v4.3.0 2009-04-17 14:37:41 +02:00
Rainer Gerhards
9348f8b9c2 preparing for 4.3.0 release 2009-04-17 14:33:14 +02:00
Rainer Gerhards
3f6c6cff47 Merge branch 'master' into nextmaster 2009-04-17 14:21:52 +02:00
Rainer Gerhards
8e536c5b25 highlighted bugfix imported from beta 2009-04-17 14:21:22 +02:00
Rainer Gerhards
51d68bb9af Merge branch 'beta' 2009-04-17 14:21:02 +02:00
Rainer Gerhards
b408585416 highlighted bugfix imported from v2-stable 2009-04-17 14:20:25 +02:00
Rainer Gerhards
63d3982721 Merge branch 'v3-stable' into beta 2009-04-17 14:19:43 +02:00
Rainer Gerhards
53bff58625 Merge branch 'debian_lenny' into v3-stable 2009-04-17 14:19:22 +02:00
Rainer Gerhards
9ebbe7477c Merge branch 'v2-stable' into debian_lenny 2009-04-17 14:19:02 +02:00
Rainer Gerhards
e8c94fcd89 bugfix: ompgsql did not detect problems in sql command execution
this could cause loss of messages. The handling was correct if the
connection broke, but not if there was a problem with statement
execution. The most probable case for such a case would be invalid
sql inside the template, and this is now much easier to diagnose.
2009-04-17 14:18:39 +02:00
Rainer Gerhards
4beff8dab6 Merge branch 'nextmaster' into oracle
Conflicts:
	runtime/rsyslog.h
2009-04-16 17:28:29 +02:00
Rainer Gerhards
2d5e8ba7cd added a new error code for too-old rsyslog core
which can be emittend when plugin can not load due to missing
core functionality.
2009-04-16 17:26:07 +02:00
Rainer Gerhards
3c886026be added some doc for omoracle 2009-04-16 16:55:25 +02:00
Luis Fernando Muñoz Mejías
668f9a79fb Fixing the batch insertions.
Previous versions inserted garbage (the pointer was interpreted as the
string itself). It seems inserting arrays of strings is not that easy
with OCI.

This approach consumes 2KB per entry in the batch, so if you have
batches of size 1000 you'll be using 2MB for the batch. This size
doesn't change, anyways and the risk of leaking memory is gone. OCI
doesn't deal well with batches of strings. :(
2009-04-16 15:28:01 +02:00
Luis Fernando Muñoz Mejías
ca28204f7b Add the callback for OCIBindDynamic.
Let's hope it works.
2009-04-16 15:27:11 +02:00
Luis Fernando Muñoz Mejías
9a897329ec Add some debugging output 2009-04-16 15:26:40 +02:00
Luis Fernando Muñoz Mejías
f89b761c84 Make the counting of bind parameters aware of literals.
Literal strings passed in the statement may contain ':', let's not
count them.
2009-04-16 15:26:09 +02:00
Luis Fernando Muñoz Mejías
24fcd96203 Fixed a mem leak 2009-04-16 15:25:29 +02:00
Luis Fernando Muñoz Mejías
65a85de3d9 Convert to the array-based interface.
We'll receive a single statement to be prepared and a batch
size. Then, doAction will execute the statement only once per batch
hit, making the process much more efficient.

This will reduce network and DB server overhead. The downside is that
this version cannot be used with rsyslog v3 anymore. If anyone is
interested on backporting the module, they should choose all patches
up to this one.

Better documentation may follow.
2009-04-16 15:24:52 +02:00
Rainer Gerhards
f07d74a87f Merge branch 'master' into nextmaster 2009-04-16 14:59:04 +02:00
Rainer Gerhards
5ccec36e8d highlighting $DirCreateMode fix 2009-04-16 14:58:46 +02:00
Rainer Gerhards
2368ccae46 Merge branch 'beta' 2009-04-16 14:58:10 +02:00
Rainer Gerhards
eec6aff6a9 Merge branch 'v3-stable' into beta
Conflicts:
	ChangeLog
	configure.ac
	doc/manual.html
2009-04-16 14:57:41 +02:00
Rainer Gerhards
481dca7c80 preparing for 3.20.6 v3.20.6 2009-04-16 14:49:39 +02:00