Changeset b72d72d21ecb21b279719abbd51c0d6a94e8a11f in xas-spooler


Ignore:
Timestamp:
12/16/15 16:47:05 (3 years ago)
Author:
Kevin L. Esteb <kevin@…>
Branches:
master
Children:
86d00c1c13b8ebcac97592b43d14a122d37795db
Parents:
df5f72ccd4ccc008b26a5ec87acc336fba51e743
git-author:
Kevin L. Esteb <kevin@…> (12/16/15 16:47:05)
git-committer:
Kevin L. Esteb <kevin@…> (12/16/15 16:47:05)
Message:

updating documentation

Location:
trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/XAS/Apps/Spooler/Process.pm

    rcd267643a706fc823f4192cf5614208bf5bf33c2 rb72d72d21ecb21b279719abbd51c0d6a94e8a11f  
    126126to a STOMP based message queue server. 
    127127 
     128=head1 CONFIGURATION 
     129 
     130The configuration file uses the familiar Windows .ini format. It has the  
     131following stanza. 
     132 
     133 [spooler: logs] 
     134 directory = logs 
     135 schedule = */1 * * * * 
     136 queue = /queue/logs 
     137 packet-type = xas-logs 
     138 tasks = 6 
     139 
     140Where the section header "spooler:" may have addtional qualifiers and repeated 
     141as many times as needed. The following properties may be used. 
     142 
     143=over 4 
     144 
     145=item B<directory> 
     146 
     147The directory to scan for files. If this is a relative directory it is  
     148referenced from $XAS_SPOOL. 
     149 
     150=item B<schedule> 
     151 
     152The schedule to run the directory scan. It uses cron semantics. This defaults  
     153to "*/1 * * * *" 
     154 
     155=item B<queue> 
     156 
     157The queue to use on the message queue server. 
     158 
     159=item B<packet-type> 
     160 
     161The type of packet. 
     162 
     163=item B<tasks> 
     164 
     165The number of internal processing tasks to use. Adding more tasks 
     166may speed up processing. This defaults to 1.  
     167 
     168=back 
     169 
    128170=head1 METHODS 
    129171 
    130172=head2 setup 
    131173 
     174This method will process the config file. 
     175 
    132176=head2 main 
    133177 
     178This method will start the processing. 
     179 
    134180=head2 options 
    135181 
     182This method defines these additional command line options. 
     183 
     184=over 4 
     185 
     186=item B<--host> 
     187 
     188The host that the message queue server resides on. 
     189 
     190=item B<--port> 
     191 
     192The port that the message queue server is listening too. 
     193 
     194=back 
     195 
    136196=head1 SEE ALSO 
    137197 
    138198=over 4 
    139199 
     200=item L<XAS::Spooler|XAS::Spooler> 
     201 
    140202=item L<XAS|XAS> 
    141203 
    142 =item L<XAS::Spooler|XAS::Spooler> 
    143  
    144204=back 
    145205 
     
    150210=head1 COPYRIGHT AND LICENSE 
    151211 
    152 Copyright (c) 2014 Kevin L. Esteb 
     212Copyright (c) 2101-2015 Kevin L. Esteb 
    153213 
    154214This is free software; you can redistribute it and/or modify it under 
  • trunk/lib/XAS/Spooler.pm

    r18b750359f94cbcc63edbd47d785f81bcc107c3b rb72d72d21ecb21b279719abbd51c0d6a94e8a11f  
    1212=head1 NAME 
    1313 
    14 XAS::Spooler - A set of procedures and modules to interact with message queues 
     14XAS::Spooler - A set of procedures and modules to implement a spooler 
    1515 
    1616=head1 DESCRIPTION 
    1717 
    18 These modules are used to scan directories. Any files found are processed and 
    19 sent to queues on a STOMP based message queue server.  
     18The spooler is used for messaging within XAS. A spooler is as old as computing. 
     19Computer lore has it that IBM coined the term SPOOL and used spoolers to 
     20buffer line printer output. In our case it is being used to implement a store  
     21and forward messaging scheme. Which in itself, is almost as old a spooling. 
     22 
     23When a process wants to send a message, it creates a spool file. The spool file 
     24is a serialized Perl data structure in JSON format, with special headers. 
     25The spooler scans the spool directory and sends the packet to an appropiate 
     26queue on a message queue server. The protocol used to do this is known as 
     27STOMP, which is a text based protocol. 
     28 
     29The reason to do all of this, is to decouple the message sender from the 
     30message receiver. This simplifies the sender. There is no need to implement 
     31all of the logic to open network conections and the maintainence of those  
     32connections. It also allows for buffering of the message stream. A fast sender 
     33doesn't have to worry about a slow receiver. The spooler takes care of this. 
     34 
     35=head1 UTILITIES 
     36 
     37This module provides the following utilities. 
     38 
     39=head2 xas-spooler 
     40 
     41This is the actual spooler. It reads a configuration file to determine which 
     42spool directories to scan. The configuration file also says which queues to 
     43use for those packets. 
    2044 
    2145=head1 SEE ALSO 
    2246 
    2347=over 4 
    24  
    25 =item L<XAS|XAS> 
    2648 
    2749=item L<XAS::Apps::Spooler::Process|XAS::Apps::Spooler::Process> 
     
    3052 
    3153=item L<XAS::Spooler::Processor|XAS::Spooler::Processor> 
     54 
     55=item L<XAS|XAS> 
    3256 
    3357=back 
     
    3963=head1 COPYRIGHT AND LICENSE 
    4064 
    41 Copyright (c) 2014 Kevin L. Esteb 
     65Copyright (c) 2012-2015 Kevin L. Esteb 
    4266 
    4367This is free software; you can redistribute it and/or modify it under 
  • trunk/lib/XAS/Spooler/Connector.pm

    rcd267643a706fc823f4192cf5614208bf5bf33c2 rb72d72d21ecb21b279719abbd51c0d6a94e8a11f  
    261261=over 4 
    262262 
     263=item L<XAS::Spooler::Processor|XAS::Spooler::Processor> 
     264 
    263265=item L<XAS::Spooler|XAS::Spooler> 
    264266 
     
    273275=head1 COPYRIGHT AND LICENSE 
    274276 
    275 Copyright (c) 2014 Kevin L. Esteb 
     277Copyright (c) 2012-2015 Kevin L. Esteb 
    276278 
    277279This is free software; you can redistribute it and/or modify it under 
  • trunk/lib/XAS/Spooler/Processor.pm

    rf8f5068b6d7b351efbd4791cac10e6a686fc31cd rb72d72d21ecb21b279719abbd51c0d6a94e8a11f  
    590590=over 4 
    591591 
     592=item L<XAS::Spooler::Connector|XAS::Spooler::Connector> 
     593 
    592594=item L<XAS::Spooler|XAS::Spooler> 
    593595 
     
    602604=head1 LICENSE AND COPYRIGHT 
    603605 
    604 Copyright (c) 2014 Kevin L. Esteb 
     606Copyright (c) 2012-2015 Kevin L. Esteb 
    605607 
    606608This is free software; you can redistribute it and/or modify it under 
  • trunk/sbin/xas-spooler

    re2a78981048c5962bf8c670ed32c160d9260a285 rb72d72d21ecb21b279719abbd51c0d6a94e8a11f  
    9595driven. 
    9696 
     97=head1 CONFIGURATION 
     98 
     99Please refer to L<XAS::Apps::Spooler::Process|XAS::Apps::Spooler::Process> 
     100for configuration file information. 
     101 
    97102=head1 OPTIONS AND ARGUMENTS 
    98103 
     
    173178=over 4 
    174179 
     180 
     181=item L<XAS::Apps::Spooler::Process|XAS::Apps::Spooler::Process> 
     182 
     183=item L<XAS::Spooler|XAS::Spooler> 
     184 
    175185=item L<XAS|XAS> 
    176186 
    177 =item L<XAS::Spooler|XAS::Spooler> 
    178  
    179 =item L<XAS::Apps::Spooler::Process|XAS::Apps::Spooler::Process> 
    180  
    181187=back 
    182188 
     
    187193=head1 COPYRIGHT AND LICENSE 
    188194 
    189 Copyright (C) 2014 by Kevin L. Esteb 
    190  
    191 This library is free software; you can redistribute it and/or modify 
    192 it under the same terms as Perl itself, either Perl version 5.8.8 or, 
    193 at your option, any later version of Perl 5 you may have available. 
     195Copyright (c) 2012-2015 by Kevin L. Esteb 
     196 
     197This is free software; you can redistribute it and/or modify it under 
     198the terms of the Artistic License 2.0. For details, see the full text 
     199of the license at http://www.perlfoundation.org/artistic_license_2_0. 
    194200 
    195201=cut 
Note: See TracChangeset for help on using the changeset viewer.