Compare commits
5 Commits
upstream/1
...
master
Author | SHA1 | Date | |
---|---|---|---|
|
86d9cb14e4 | ||
|
f05f29903c | ||
|
05e277c3d3 | ||
|
a75ecd2b5d | ||
|
067a295bd5 |
5
debian/changelog
vendored
Normal file
5
debian/changelog
vendored
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
liblog-log4perl-appender-graylog-perl (1.7-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* Initial Release.
|
||||||
|
|
||||||
|
-- Mario Fetka <mario.fetka@gmail.com> Tue, 27 Mar 2018 20:31:40 +0200
|
1
debian/compat
vendored
Normal file
1
debian/compat
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
9
|
16
debian/control
vendored
Normal file
16
debian/control
vendored
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
Source: liblog-log4perl-appender-graylog-perl
|
||||||
|
Section: perl
|
||||||
|
Priority: optional
|
||||||
|
Maintainer: Mario Fetka <mario.fetka@gmail.com>
|
||||||
|
Build-Depends: debhelper (>= 9), libdata-faker-perl, libdata-printer-perl, libdata-random-string-perl, libio-compress-perl, libjson-perl, liblog-log4perl-perl, libtest-mockmodule-perl, libtest-moose-more-perl, libtest-most-perl, perl-base, libdata-uuid-perl, libdevel-stacktrace-perl, libjson-tiny-perl, liblog-gelf-util-perl, liblog-log4perl-perl, libmoose-perl, libmoosex-types-perl, libreadonly-perl, libnamespace-autoclean-perl, libtime-hires-perl
|
||||||
|
Build-Depends-Indep: perl
|
||||||
|
Standards-Version: 3.9.6
|
||||||
|
Homepage: https://metacpan.org/release/Log-Log4perl-Appender-Graylog
|
||||||
|
|
||||||
|
Package: liblog-log4perl-appender-graylog-perl
|
||||||
|
Architecture: all
|
||||||
|
Depends: ${misc:Depends}, ${perl:Depends}, libdata-uuid-perl, libdevel-stacktrace-perl, libjson-tiny-perl, liblog-gelf-util-perl, liblog-log4perl-perl, libmoose-perl, libmoosex-types-perl, libreadonly-perl, libnamespace-autoclean-perl, libio-compress-perl, libtime-hires-perl
|
||||||
|
Description: Log dispatcher writing to udp Graylog server
|
||||||
|
(no description was found)
|
||||||
|
.
|
||||||
|
This description was automagically extracted from the module by dh-make-perl.
|
36
debian/copyright
vendored
Normal file
36
debian/copyright
vendored
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
||||||
|
Source: https://metacpan.org/release/Log-Log4perl-Appender-Graylog
|
||||||
|
Upstream-Contact: Brandon "Dimentox Travanti" Husbands <xotmid@gmail.com>
|
||||||
|
Upstream-Name: Log-Log4perl-Appender-Graylog
|
||||||
|
DISCLAIMER: This copyright info was automatically extracted
|
||||||
|
from the perl module. It may not be accurate, so you better
|
||||||
|
check the module sources in order to ensure the module for its
|
||||||
|
inclusion in Debian or for general legal information. Please,
|
||||||
|
if licensing information is incorrectly generated, file a bug
|
||||||
|
on dh-make-perl.
|
||||||
|
NOTE: Don't forget to remove this disclaimer once you are happy
|
||||||
|
with this file.
|
||||||
|
|
||||||
|
Files: *
|
||||||
|
Copyright: Brandon "Dimentox Travanti" Husbands <xotmid@gmail.com>
|
||||||
|
License: Artistic or GPL-1+
|
||||||
|
|
||||||
|
Files: debian/*
|
||||||
|
Copyright: 2018, Mario Fetka <mario.fetka@gmail.com>
|
||||||
|
License: Artistic or GPL-1+
|
||||||
|
|
||||||
|
License: Artistic
|
||||||
|
This program is free software; you can redistribute it and/or modify
|
||||||
|
it under the terms of the Artistic License, which comes with Perl.
|
||||||
|
.
|
||||||
|
On Debian systems, the complete text of the Artistic License can be
|
||||||
|
found in `/usr/share/common-licenses/Artistic'.
|
||||||
|
|
||||||
|
License: GPL-1+
|
||||||
|
This program is free software; you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation; either version 1, or (at your option)
|
||||||
|
any later version.
|
||||||
|
.
|
||||||
|
On Debian systems, the complete text of version 1 of the GNU General
|
||||||
|
Public License can be found in `/usr/share/common-licenses/GPL-1'.
|
1
debian/liblog-log4perl-appender-graylog-perl.docs
vendored
Normal file
1
debian/liblog-log4perl-appender-graylog-perl.docs
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
README.md
|
97
debian/patches/JohannesLogFormat.patch
vendored
Normal file
97
debian/patches/JohannesLogFormat.patch
vendored
Normal file
@ -0,0 +1,97 @@
|
|||||||
|
diff -uNr Log-Log4perl-Appender-Graylog-1.7.orig/lib/Data/DTO/GELF.pm Log-Log4perl-Appender-Graylog-1.7/lib/Data/DTO/GELF.pm
|
||||||
|
--- Log-Log4perl-Appender-Graylog-1.7.orig/lib/Data/DTO/GELF.pm 2018-03-28 14:15:13.708000000 +0200
|
||||||
|
+++ Log-Log4perl-Appender-Graylog-1.7/lib/Data/DTO/GELF.pm 2018-03-28 14:57:01.000000000 +0200
|
||||||
|
@@ -13,6 +13,7 @@
|
||||||
|
use Sys::Hostname;
|
||||||
|
use Data::UUID;
|
||||||
|
use POSIX qw(strftime);
|
||||||
|
+use Time::HiRes;
|
||||||
|
|
||||||
|
use Log::Log4perl;
|
||||||
|
|
||||||
|
@@ -47,7 +48,8 @@
|
||||||
|
|
||||||
|
has 'timestamp' => (
|
||||||
|
is => 'ro',
|
||||||
|
- isa => 'Int',
|
||||||
|
+ #isa => 'Int',
|
||||||
|
+ isa => 'Num',
|
||||||
|
builder => '_build_timestamp',
|
||||||
|
);
|
||||||
|
|
||||||
|
@@ -61,12 +63,27 @@
|
||||||
|
isa => 'Str',
|
||||||
|
);
|
||||||
|
|
||||||
|
-has '_line' => (
|
||||||
|
+has '_SourceLineNumber' => (
|
||||||
|
is => 'rw',
|
||||||
|
isa => 'Int',
|
||||||
|
);
|
||||||
|
|
||||||
|
-has '_file' => (
|
||||||
|
+has '_SourceFileName' => (
|
||||||
|
+ is => 'rw',
|
||||||
|
+ isa => 'Str',
|
||||||
|
+);
|
||||||
|
+
|
||||||
|
+has '_SourceClassName' => (
|
||||||
|
+ is => 'rw',
|
||||||
|
+ isa => 'Str',
|
||||||
|
+);
|
||||||
|
+
|
||||||
|
+has '_SourceMethodName' => (
|
||||||
|
+ is => 'rw',
|
||||||
|
+ isa => 'Str',
|
||||||
|
+);
|
||||||
|
+
|
||||||
|
+has '_Severity' => (
|
||||||
|
is => 'rw',
|
||||||
|
isa => 'Str',
|
||||||
|
);
|
||||||
|
@@ -83,13 +100,20 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
my $trace = Devel::StackTrace->new;
|
||||||
|
+ my $subroutine_next = '';
|
||||||
|
+ my $found = 0;
|
||||||
|
foreach my $frame ( $trace->frames ) {
|
||||||
|
+
|
||||||
|
+ $subroutine_next ||= $frame->{subroutine} if ($found and $frame->{subroutine} ne "Log::Log4perl::Logger::__ANON__");
|
||||||
|
+
|
||||||
|
if ( $frame->{subroutine} eq "Log::Log4perl::Logger::__ANON__" ) {
|
||||||
|
- $self->_line( $frame->{line} );
|
||||||
|
- $self->_file( $frame->{filename} );
|
||||||
|
- $self->_facility( $frame->{package} );
|
||||||
|
+ $self->_SourceLineNumber( $frame->{line} );
|
||||||
|
+ $self->_SourceFileName( $frame->{filename} );
|
||||||
|
+ $self->_SourceClassName( $frame->{package} );
|
||||||
|
+ $found++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
+ $self->_SourceMethodName( $subroutine_next );
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -105,7 +129,7 @@
|
||||||
|
|
||||||
|
sub _build_timestamp {
|
||||||
|
my $self = shift;
|
||||||
|
- return time();
|
||||||
|
+ return Time::HiRes::time();
|
||||||
|
}
|
||||||
|
|
||||||
|
sub message {
|
||||||
|
diff -uNr Log-Log4perl-Appender-Graylog-1.7.orig/lib/Log/Log4perl/Appender/Graylog.pm Log-Log4perl-Appender-Graylog-1.7/lib/Log/Log4perl/Appender/Graylog.pm
|
||||||
|
--- Log-Log4perl-Appender-Graylog-1.7.orig/lib/Log/Log4perl/Appender/Graylog.pm 2018-03-28 14:15:13.708000000 +0200
|
||||||
|
+++ Log-Log4perl-Appender-Graylog-1.7/lib/Log/Log4perl/Appender/Graylog.pm 2018-03-28 14:57:01.000000000 +0200
|
||||||
|
@@ -70,7 +70,8 @@
|
||||||
|
'_name' => $params{name},
|
||||||
|
'_category' => $params{log4p_category},
|
||||||
|
"_pid" => $$,
|
||||||
|
-
|
||||||
|
+ "_facility" => $self->{facility} || '',
|
||||||
|
+ "_Severity" => $params{log4p_level},
|
||||||
|
);
|
||||||
|
|
||||||
|
my $msg = validate_message( $packet->TO_HASH() );
|
2
debian/patches/series
vendored
Normal file
2
debian/patches/series
vendored
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
JohannesLogFormat.patch
|
||||||
|
|
4
debian/rules
vendored
Executable file
4
debian/rules
vendored
Executable file
@ -0,0 +1,4 @@
|
|||||||
|
#!/usr/bin/make -f
|
||||||
|
|
||||||
|
%:
|
||||||
|
dh $@
|
1
debian/source/format
vendored
Normal file
1
debian/source/format
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
3.0 (quilt)
|
7
debian/upstream/metadata
vendored
Normal file
7
debian/upstream/metadata
vendored
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
Archive: CPAN
|
||||||
|
Bug-Database: https://github.com/dimentox/log-log4perl-appender-graylog/issues
|
||||||
|
Contact: Brandon "Dimentox Travanti" Husbands <xotmid@gmail.com>
|
||||||
|
Name: Log-Log4perl-Appender-Graylog
|
||||||
|
Repository: git://github.com/dimentox/log-log4perl-appender-graylog.git
|
||||||
|
Repository-Browse: https://github.com/dimentox/log-log4perl-appender-graylog
|
2
debian/watch
vendored
Normal file
2
debian/watch
vendored
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
version=3
|
||||||
|
https://metacpan.org/release/Log-Log4perl-Appender-Graylog .*/Log-Log4perl-Appender-Graylog-v?(\d[\d.-]*)\.(?:tar(?:\.gz|\.bz2)?|tgz|zip)$
|
Loading…
x
Reference in New Issue
Block a user