Commit Graph

197 Commits

Author SHA1 Message Date
Adrian-Ken Rueegsegger 9e11144aa6 Use Dst_Filter package in policy tests
This paves the way to let the Policy_DB package only provide type
definitions required to implement identifier-based filtering.
2019-09-26 11:15:43 +02:00
Adrian-Ken Rueegsegger 60be0164f1 Minor: Use constant string for test facility names 2019-09-26 11:15:43 +02:00
Adrian-Ken Rueegsegger f057dc4290 Use Dst_Filter package for destination filtering 2019-09-26 11:15:43 +02:00
Adrian-Ken Rueegsegger 818776e6a7 Consider default loglevel in dest filtering
Make destination filtering behavior analogous to source filtering: if no
entry for the identifier is found in the database consider the default
loglevel.
2019-09-26 11:13:25 +02:00
Adrian-Ken Rueegsegger 385edaedd3 Replace Alog_Default_Level with Log_Level'First
Instead of declaring a constant with a more or less arbitrary value use
Log_Level'First instead.
2019-09-25 16:27:02 +02:00
Adrian-Ken Rueegsegger be5fa36e06 Do not set default log level in Log_Request.Create
Mandate that the caller must specify what loglevel the request has.
Setting a default does not make much sense.
2019-09-17 16:54:38 +02:00
Adrian-Ken Rueegsegger 00017b0483 Streamline test data and ref filenames 2019-09-17 15:35:07 +02:00
Adrian-Ken Rueegsegger 540e9751cc Create test files in obj directory
This simplifies cleanup of test data when tests fail.
2019-09-17 14:26:16 +02:00
Markus Vogt 22ab479bd6 Added possibility to log to stderr 2019-01-31 15:51:52 +01:00
Adrian-Ken Rueegsegger ee2ba06bee Add support for '*' wildcard
Extend wildcard map so '*' matches all keys.
2017-11-14 11:48:45 +01:00
Adrian-Ken Rueegsegger d1a98fe033 Drop unneeded use clauses 2017-09-26 16:41:19 +02:00
Reto Buerki 64be417670 Fix delay loop in Verify_Iterate_Facilities test
Only exit delay loop if the expected count is met as otherwise the
counter might be one instead of two.
2016-02-24 10:23:08 +01:00
Adrian-Ken Rueegsegger e605843cc3 Update copyright 2014-10-15 12:17:20 +02:00
Adrian-Ken Rueegsegger 016af5ca08 Adjust name of test suite 2014-09-21 18:18:56 +02:00
Adrian-Ken Rueegsegger cb33a9d1f5 Rename profiler_base to profiler 2014-09-21 18:18:56 +02:00
Adrian-Ken Rueegsegger d2dbabad22 Rename runner_base to test_runner 2014-09-21 18:09:51 +02:00
Adrian-Ken Rueegsegger 5ee22d57e2 Drop Alog 'full' tests including project file
This is in preparation of removal of the PostgreSQL, SMTP and XMPP
facilities.
2014-09-21 17:47:08 +02:00
Adrian-Ken Rueegsegger ca12c8edd2 Make Set_Invalid_Logfile_Fd test more robust
Set the current directory as invalid log file destination, which is guaranteed
to fail. The test will execute as expected even when run as root.
2014-03-27 00:26:14 +01:00
Reto Buerki c244fa8b9e Facility: Implement Set_Timestamp_Format procedure
This setter can be used to change the log timestamp format. The format
follows the GNU Date specification with some GNAT specific extensions.
See the GNAT.Calendar.Time_IO specs for details about the accepted
directives. The procedure raises an Invalid_Timestamp_Format exception
if the given format is incorrect.

If no specific format is set, '%b %d %Y %T' is used as default.
2012-05-17 15:54:21 +02:00
Reto Buerki fdbe219d20 Remove 'secunet SwissIT AG' from copyright header
R.I.P. Ad perpetuam memoriam.
2011-11-17 12:15:15 +01:00
Reto Buerki 6d37a3c308 Syslog: Add setter/getter for origin value. 2011-04-11 11:58:18 +02:00
Reto Buerki df292dd9b0 Remove unneeded protected exception map. 2011-03-09 12:32:35 +01:00
Reto Buerki e48fddefe7 Rewrite tasked logger exception handling.
The user of a tasked logger can now register an exception handling
callback to be notified when an exception occurs in the tasked logger
(outside of a rendezvous).

If no custom handler is registered, the calling task's ID and the
exception information is printed to standard error.
2011-03-09 11:35:16 +01:00
Reto Buerki ba2d8e4510 Update Compiler_Switches (use -gnatygAdISuxo). 2011-02-14 15:38:13 +01:00
Adrian-Ken Rueegsegger 2fa7136b48 Remove policy handling from loggers.
When and where a policy should be applied is up to the users of a
logger so we should not do it implicitly.
2010-12-07 17:00:45 +01:00
Reto Buerki 4056ac2757 Update base profiler. 2009-12-10 14:16:45 +01:00
Adrian-Ken Rueegsegger 227d7a17d0 Minor cleanup in PGSQL facility. 2009-12-10 12:31:06 +01:00
Adrian-Ken Rueegsegger 256a690185 Add Open_File_Error exception. 2009-12-09 18:37:32 +01:00
Adrian-Ken Rueegsegger b155f1cee9 Minor corrections in XMPP facility tests. 2009-12-09 16:53:04 +01:00
Adrian-Ken Rueegsegger da70b0feb0 Fix accessibility issue with GNAT 4.4 (RM 3.10.2 (13)). 2009-12-08 22:38:43 +00:00
Reto Buerki 99dbfdaff7 Small format corrections in SMTP facility. 2009-12-08 18:54:18 +01:00
Adrian-Ken Rueegsegger a7c0ec7d4d Add additional test for invalid config file. 2009-12-08 18:11:13 +01:00
Adrian-Ken Rueegsegger 709f11dff4 Policy: Add Accept_Dst() function.
This function returns True if a given loglevel is accepted for a
destination identifier. If no match for the given identifier is
found True is returned.
2009-12-07 17:46:48 +01:00
Adrian-Ken Rueegsegger ae58df6d91 Rename Accept_Ident to Accept_Src. 2009-12-07 17:46:48 +01:00
Reto Buerki 023ec3e120 Only test additional facilities in 'full' runner. 2009-12-03 22:40:29 +01:00
Reto Buerki 941b9bf9cb Add test for active logger message queue length. 2009-12-03 17:42:39 +01:00
Reto Buerki 9b5370cf4f Add test to verify destination loglevels. 2009-12-03 17:28:36 +01:00
Reto Buerki de5bb7af5f Move source identifier writing logic to facility. 2009-12-03 16:51:08 +01:00
Reto Buerki 80121b86a1 Update policy test names (sources vs. identifiers). 2009-12-03 15:57:45 +01:00
Reto Buerki a176092058 Helpers: Rename Sources to Identifiers. 2009-12-03 15:56:52 +01:00
Reto Buerki 8e83bf9582 Remove redundant logger tests. 2009-12-03 15:33:03 +01:00
Reto Buerki c21cc205d4 Fix Log_Multiple_FD_Facilities test. 2009-12-03 15:31:39 +01:00
Reto Buerki 1bd381b426 Facility: Remove threshold field. 2009-12-03 15:24:06 +01:00
Reto Buerki 725a17e465 Policy: Rename Accept_Src to Accept_Ident. 2009-12-03 15:13:33 +01:00
Reto Buerki 3182d6ecab Policy: Rename Lookup_Src_Loglevel to Lookup. 2009-12-03 15:04:52 +01:00
Reto Buerki 388c0b76e1 Policy: Rename Get_Src_Loglevel to Get_Loglevel. 2009-12-03 15:00:12 +01:00
Reto Buerki efa193def1 Policy: Rename Set_Src_Loglevel to Set_Loglevel (map). 2009-12-03 14:55:00 +01:00
Reto Buerki f09ebe288c Policy: Rename Source parameter to Identifier. 2009-12-03 14:52:20 +01:00
Reto Buerki 52aa397c10 Policy: Rename Set_Src_Loglevel to Set_Loglevel. 2009-12-03 14:45:24 +01:00
Reto Buerki d4906a103c Implement Lookup_Src_Loglevel() function.
This function returns the closest loglevel match for a given
source, if no associated loglevel is found the default loglevel
is returned.
2009-11-27 18:59:15 +01:00