75 Commits

Author SHA1 Message Date
Rainer Gerhards
73abfd1fad added new poperty replacer option, added missing documentation
- added a new property replacer option "sp-if-no-1st-sp" to cover
  a problem with RFC 3164 based interpreation of tag separation. While
  it is a generic approach, it fixes a format problem introduced in
  3.18.0, where kernel messages no longer had a space after the tag.
  This is done by a modifcation of the default templates.
  Please note that this may affect some messages where there intentionally
  is no space between the tag and the first character of the message
  content. If so, this needs to be worked around via a specific
  template. However, we consider this scenario to be quite remote and,
  even if it exists, it is not expected that it will actually cause
  problems with log parsers (instead, we assume the new default template
  behaviour may fix previous problems with log parsers due to the
  missing space).
- doc bugfix: property replacer options secpath-replace and
  secpath-drop were not documented
2008-07-18 12:50:14 +02:00
Rainer Gerhards
c179a9c5c2 bugfix: priority was incorrectly calculated on FreeBSD 7
because the LOG_MAKEPRI() C macro has a different meaning there (it
is just a simple addition of faciltity and severity). I have changed
this to use own, consistent, code for PRI calculation. [Backport from
3.19.10]
2008-07-14 16:06:06 +02:00
Rainer Gerhards
816fda9775 bugfix: potential segfault in creating message mutex in non-direct queue mode.
rsyslogd segfaults on freeeBSD 7.0 (an potentially other platforms)
if an action queue is running in any other mode than non-direct. The
same problem can potentially be triggered by some main message queue
settings. In any case, it will manifest during rsylog's startup. It is
unlikely to happen after a successful startup (the only window of
exposure may be a relatively seldom executed action running in queued
mode). This has been corrected. Thank to HKS for point out the problem.
2008-07-14 11:14:14 +02:00
Rainer Gerhards
5e279ea0f7 properties are now case-insensitive everywhere (script, filters, templates) 2008-04-03 09:31:55 +00:00
Rainer Gerhards
26aa8b09db worked a bit on atomic memory operations to support problem-free threading
(only at non-intrusive places)
2008-03-31 09:07:24 +00:00
Rainer Gerhards
f94cd60dac - bugfix: regular expressions inside property replacer did not work
properly
2008-03-28 14:18:40 +00:00
Rainer Gerhards
562906e64a bugfix: QHOUR and HHOUR properties were wrongly calculated 2008-03-26 08:18:17 +00:00
Rainer Gerhards
752ec6cedd added $HHOUR and $QHOUR system properties - can be used for half- and
quarter-hour logfile rotation
2008-03-25 09:23:31 +00:00
Rainer Gerhards
fdfcb2a8f9 added advanced flow control for congestion cases (mode depending on message
source and its capablity to be delayed without bad side effects)
2008-03-14 11:04:36 +00:00
Rainer Gerhards
4db62823e7 renamed library module file names to lm*, so that they match the overall
scheme (like im* and om*)
2008-03-07 17:26:58 +00:00
Rainer Gerhards
d471e71ada fixed potential infinite loop condition when module load failed on startup 2008-03-07 16:34:51 +00:00
Rainer Gerhards
549c0cccd4 extracted regexp functionality to its own dynamically loadable module 2008-03-07 16:10:58 +00:00
Rainer Gerhards
2391063617 moved date/time handling functions to their own object 2008-03-05 16:31:29 +00:00
Rainer Gerhards
80e69562be did some portability changes to make rsyslog compile on HP UX 2008-03-05 07:01:35 +00:00
Rainer Gerhards
a7eb97b930 - added "debug" command to debug environment settings
- changed the object/interface system to use a new way of calling, giving
    up the numerical object ID. This was necessary as we needed more
    extensibility for third-party modules (which don't play at all with the
    previous fixed object ID). This is stage work for the object loader.
    Please note that I needed to change the object (de)serializer, I can't
    outrule that I have introduced bugs there.
2008-02-29 16:02:07 +00:00
Rainer Gerhards
4412b88148 changed obj base object's calling interface to use the new obj_if_t
interface structure
2008-02-29 09:14:10 +00:00
Rainer Gerhards
5ebc0db1a6 - added PUSHMSGVAR operation
- included expression support in filter module (and it works ;))
2008-02-25 13:27:10 +00:00
Rainer Gerhards
75e9a2dc69 simplified var object, now only supports strings and numbers as a single
type
2008-02-22 17:44:47 +00:00
Rainer Gerhards
013073f1a6 changed rsCStrObj name to cstr_t, which is more inline with the rest of
rsyslog (now) and also much easier to type
2008-02-21 07:00:29 +00:00
Rainer Gerhards
c6bebca3c7 changed rsCStrDestruct() to use the new interface conventions 2008-02-20 14:02:33 +00:00
Rainer Gerhards
33f061484d created var class out of property_t 2008-02-20 13:54:11 +00:00
Rainer Gerhards
cd2b24dfc4 - added doc on how expressions will work
- cleaned up the stringbuf Construct interface
- did some cleanup on stringbuf calls - we now have much better interfaces
    and macros
2008-02-19 10:30:42 +00:00
Rainer Gerhards
6cc46b15d9 - implemented simple output rate limiting
- addded $ActionQueueDequeueSlowdown config directive
- addded $MainMsgQueueDequeueSlowdown config directive
- bugfix: MsgDup() did not work with new base object data structure
2008-01-30 15:37:23 +00:00
Rainer Gerhards
4984c1ba6c - renamed Msg object to usual all-lowercase object name (else we ran into
troubles with the framework, also it was somewhat ugly...)
- fixed a memory leak in object destruction (was recently introduced by
    object naming, not present in any released version)
2008-01-30 08:02:42 +00:00
Rainer Gerhards
19cad8b12f implemented naming for all objects (mostly as a debug aid, but you never
know what else it will be good for)
2008-01-29 10:23:10 +00:00
Rainer Gerhards
5c686c8adc redesigned queue to utilize helper classes for threading support. This is
finally in a running state for regular (non disk-assisted) queues, with
    a minor nit at shutdown. So I can finally commit the work again to
    CVS...
2008-01-24 17:55:09 +00:00
Rainer Gerhards
ed0363210c worked on threading 2008-01-17 12:45:10 +00:00
Rainer Gerhards
ec27ea55f3 begin disk assisted queue memory queue modes (not fully implemented yet) 2008-01-14 17:53:35 +00:00
Rainer Gerhards
3a40f52f89 implemented $MainMsgQueueDiscardMar and $MainMsgQueueDiscardSeverity (but
serverity needs to be specified numerically for the time being)
2008-01-14 14:18:36 +00:00
Rainer Gerhards
366060a51d partial ability to read a disk queue back in (not completed, but would like
to save source for the weekend)
2008-01-11 19:38:09 +00:00
Rainer Gerhards
a80f7776c5 support for de-serializing strm objects added 2008-01-11 16:52:19 +00:00
Rainer Gerhards
46d0a95fc1 changed some config parameters and some cleanup 2008-01-10 13:23:53 +00:00
Rainer Gerhards
fa859275c6 - added write functions for several types to stream class
- changed objSerialize methods to work directly on the stream class
2008-01-10 13:09:43 +00:00
Rainer Gerhards
c40ce62e9c completed deserialization support in msg object (but not deserializer
itself)
2008-01-08 17:46:15 +00:00
Rainer Gerhards
8d0a174a86 - first implementation of "disk" queue mode finished. It still needs some
work and the deserializer needs also to be expanded, but the queue at
    least performs well now.
- fixed a race condition that could occur when input modules were
    terminated
2008-01-08 13:37:19 +00:00
Rainer Gerhards
571d21a33a - MsgSetProperty() implemented
- defined a property class
- implemented deserializer (needs some more work)
2008-01-07 17:26:49 +00:00
Rainer Gerhards
918f281d82 implemented class type registry 2008-01-07 11:04:24 +00:00
Rainer Gerhards
c8b946aa94 performance-tuned stringbuf class 2008-01-07 08:38:14 +00:00
Rainer Gerhards
2c81480d28 worked on object header (now also contains the size) 2008-01-06 17:59:40 +00:00
Rainer Gerhards
22ea87ec59 completed serializer for msg (but needs review) 2008-01-06 17:12:41 +00:00
Rainer Gerhards
b083f69942 worked a bit on object serialization 2008-01-06 12:12:57 +00:00
Rainer Gerhards
62154cdde9 added the "direct" queueing mode to queue class (no queing at all) 2008-01-05 13:39:40 +00:00
Rainer Gerhards
e055d4921b added capability for concurrent access to the msg class. Can be dynamically
activated. If active, locking is employed.
2008-01-05 13:05:17 +00:00
Rainer Gerhards
800ac1889b changed queue object Construction/Startup interface 2008-01-04 17:17:12 +00:00
Rainer Gerhards
e41c0854da moved message destruction back to consumer - the consume should decide what
to do with the object. It may pass it on to someone else. So this would
    have creatd some headache in the future (maybe...).
2008-01-04 16:52:56 +00:00
Rainer Gerhards
3b8457d1da utilized the new auto-destruction capability so that the queue can now
destruct user objects if needed
2008-01-04 16:44:41 +00:00
Rainer Gerhards
eb9f97ee2d removed serialization pointer from queue; used new base class instead 2008-01-04 16:23:37 +00:00
Rainer Gerhards
faf8e5a384 - begun some work on Msg Object serializiation
- created a kind of general base class
2008-01-04 16:05:42 +00:00
Rainer Gerhards
cebbf6d44e some cleanup 2007-12-27 14:29:09 +00:00
Rainer Gerhards
004229dda6 changed license to GPLv3 (for what is to become rsyslog v3) 2007-12-14 11:21:57 +00:00