Changeset d4fb1f2b8cfe8b55c5211ef68e6c1a33c8c56761 in xas-collector


Ignore:
Timestamp:
10/12/16 10:04:30 (14 months ago)
Author:
Kevin L. Esteb <kevin@…>
Branches:
master
Parents:
0a0ffd7c5226bb490a69dbd4745261cdc62160b3
git-author:
Kevin L. Esteb <kevin@…> (10/12/16 10:04:30)
git-committer:
Kevin L. Esteb <kevin@…> (10/12/16 10:04:30)
Message:

adding support for Elasticsearch
added an empty database for messaging

Location:
trunk
Files:
2 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Build.PL

    rc424993bf0a40515b896cbad5dc4cf43bfe68845 rd4fb1f2b8cfe8b55c5211ef68e6c1a33c8c56761  
    44 
    55my $requires = { 
    6     'perl'       => 5.008_08, 
    7     'XAS'        => 0.08, 
    8     'XAS::Model' => 0.01, 
     6    'perl'                  => 5.008_08, 
     7    'XAS'                   => 0.08, 
     8    'XAS::Model'            => 0.01, 
     9    'File::Slurp'           => 9999.19', 
     10    'Search::Elasticsearch' => 2.03, 
    911}; 
    1012     
    1113my $sysconfig = ( -e '/etc/default' ) ? '/etc/default' : '/etc/sysconfig'; 
    1214my $install_path = { 
     15    db            => '/var/lib/xas', 
    1316    etc           => '/etc/xas', 
    1417    sbin          => '/usr/sbin', 
     
    2528 
    2629    my $install_path = { 
     30        db            => $path . '\\var\\lib', 
    2731        etc           => $path . '\\etc', 
    2832        sbin          => $path . '\\sbin', 
     
    237241    # correctly process additional directories 
    238242 
     243    sub process_db_files { 
     244        my $self = shift; 
     245 
     246             
     247        my $result; 
     248        my $dir = catfile('blib', 'lib'); 
     249        my $files = $self->find_db_files; 
     250 
     251        mkdir $dir unless (-e $dir); 
     252 
     253        while (my ($from, $to) = each %$files) { 
     254 
     255            $to = catfile('blib', $to); 
     256            $result = $self->copy_if_modified(from => $from, to => $to); 
     257 
     258        } 
     259 
     260        return $self; 
     261 
     262    } 
     263 
    239264    sub process_etc_files { 
    240265        my $self = shift; 
     
    362387    } 
    363388 
     389    sub find_db_files { shift->find_all_files_no_scm('db'); } 
    364390    sub find_etc_files { shift->find_all_files_no_scm('etc'); } 
    365391    sub find_sbin_files { shift->find_all_files_no_scm('sbin'); } 
     
    426452); 
    427453 
     454$builder->add_build_element('db'); 
    428455$builder->add_build_element('etc'); 
    429456$builder->add_build_element('msg'); 
  • trunk/MANIFEST

    rd187e3285505df70b9109629c0cf96dedf65936d rd4fb1f2b8cfe8b55c5211ef68e6c1a33c8c56761  
    11Build.PL 
    22Changes 
     3db/messaging.db 
    34debian/changelog 
    45debian/compat 
     
    2829lib/XAS/Collector/Output/Database/Logs.pm 
    2930lib/XAS/Collector/Output/Socket/Base.pm 
     31lib/XAS/Collector/Output/Socket/ElasticSearch.pm 
    3032lib/XAS/Collector/Output/Socket/Logstash.pm 
    3133lib/XAS/Collector/Output/Socket/OpenTSDB.pm 
  • trunk/lib/XAS/Msgs/Collector.msg

    r31a54954f58d48745b33976eb5c95036b27a6ff2 rd4fb1f2b8cfe8b55c5211ef68e6c1a33c8c56761  
    88 
    99[messages] 
    10 collector_send         = %s: sent packet to logstash 
    11 collector_down         = %s: the logstash connection is down 
    12 collector_up           = %s: the logstash connection is up 
    13 collector_connected    = %s: connected to %s on %s 
    14 collector_unknownmsg   = %s: unknown protocol type: %s 
    15 collector_subscribed   = %s: subscribed to %s 
    16 collector_receipts     = %s: received a receipt %s 
    17 collector_unsubscribed = %s: unsubscribed from %s 
    18 collector_errors       = %s: received an error %s, message: %s, reason: %s 
    19 collector_unknowntype  = %s: unknown packet type: %s 
    20 collector_received     = %s: received message %s, type: "%s" from %s 
    21 collector_processed    = %s: processed %s items from: %s; time: %s 
    22 collector_pausing      = %s: pausing queue %s 
    23 collector_resuming     = %s: resuming queue %s 
    24 collector_notype       = %s: no message type defined 
    25 collector_waiting      = %s: waiting on connection for: %s 
     10collector_send             = %s: sent packet to logstash 
     11collector_down             = %s: the logstash connection is down 
     12collector_up               = %s: the logstash connection is up 
     13collector_connected        = %s: connected to %s on %s 
     14collector_unknownmsg       = %s: unknown protocol type: %s 
     15collector_subscribed       = %s: subscribed to %s 
     16collector_receipts         = %s: received a receipt %s 
     17collector_unsubscribed     = %s: unsubscribed from %s 
     18collector_errors           = %s: received an error %s, message: %s, reason: %s 
     19collector_unknowntype      = %s: unknown packet type: %s 
     20collector_received         = %s: received message %s, type: "%s" from %s 
     21collector_processed        = %s: processed %s items from: %s; time: %s 
     22collector_pausing          = %s: pausing queue %s 
     23collector_resuming         = %s: resuming queue %s 
     24collector_notype           = %s: no message type defined 
     25collector_waiting          = %s: waiting on connection for: %s 
     26collector_elastic_sent     = %s: sent message %s 
     27colelctor_elastic_connect  = %s: using elasticsearch on %s 
     28colelctor_elastic_template = %s: installing index template - %s 
     29collector_elastic_error    = %s: message: %s, type: %s, status: %s; reason: %s 
     30colector_baddate           = error: "%s" for date: "%s" 
     31 
  • trunk/perl-XAS-Collector.spec

    r2e6a65d2165554fb9277b2732ae22581537f0867 rd4fb1f2b8cfe8b55c5211ef68e6c1a33c8c56761  
    1212BuildRequires:  perl(Test::More) 
    1313Requires:       perl(XAS) >= 0.08 
    14 Requires:       perl(XAS::Model> >= 0.01 
     14Requires:       perl(XAS::Model) >= 0.01 
     15Requires:       perl(File::Slurp) >= 9999.19 
     16Requires:       perl(Search::Elasticsearch) >= 2.03 
    1517Requires:       perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) 
    1618 
Note: See TracChangeset for help on using the changeset viewer.