Commit graph

10505 commits

Author SHA1 Message Date
Jordan Sissel
f35a1ea88a - Follow symlink if pattern_dir is one 2009-10-25 04:27:27 +00:00
Jordan Sissel
78cfbff565 - uri paths can have /[@{}]/ in it 2009-10-25 04:26:10 +00:00
Jordan Sissel
226027c024 - Disable message buffering internal to logstash. Previously, sendmsg() would
push into an array which would get flushed when full or once per second.
  This was causing any normally-fast search request to take a minimum of 1 second.

  The original need for buffering was due to features of STOMP (not used
  anymore) that would limit the number of messages we could handle at once. We
  would buffer multiple messages to a single STOMP queue message so that we
  could handle multiple messages. This may not be a problem anymore with AMQP.

  Set BUFFER_DELAY_MESSAGES to true in socket.rb if you want to re-enable this.

- Add 'timestamp' attribute for all messages. This attribute is set
  automatically when it is sent with MessageSocket#sendmsg.
- Add blocking on MessageSocket#initialize to wait for the AMQP thread. Uses
  the same mutex/conditionvariable method we use to block LogStash::Operation
  instances.
- Removed old 'USE_MARSHAL' support as I think we're pretty happy with JSON now.
2009-10-25 03:24:02 +00:00
Jordan Sissel
b9a273885f - search.rb use new LogStash::StopWatch class 2009-10-25 03:19:11 +00:00
Jordan Sissel
646a0948ed - Add LogStash::StopWatch class for recording execution time of code 2009-10-25 03:14:42 +00:00
Jordan Sissel
18476af99b - Only ever create one search client, and do it on app startup. 2009-10-25 03:11:04 +00:00
Jordan Sissel
b5ff853c4a - remove file that doesn't need to be in svn 2009-10-25 03:10:42 +00:00
Jordan Sissel
4abe95037a - syslog program names can have periods or underscores 2009-10-23 16:57:27 +00:00
Jordan Sissel
9195abd6de - make get_ferret open a new IndexReader and Searcher every time, otherwise we
can get stale search results.
2009-10-23 10:07:10 +00:00
Jordan Sissel
645d17da70 - version bump 2009-10-23 08:44:21 +00:00
Jordan Sissel
4de3175b57 - remove old sanbox we don't need anymore 2009-10-23 08:43:45 +00:00
Jordan Sissel
629c264113 - fix web search config yaml path
- fix web dependencies
2009-10-23 08:42:17 +00:00
Jordan Sissel
807461e79e - set default / to /search 2009-10-23 08:12:30 +00:00
Jordan Sissel
ddbf0ebe36 - Add new webapp which is of 'merb-gen core' lineage. Much fewer dependencies than previous version. 2009-10-23 08:11:44 +00:00
Jordan Sissel
5ce84cf45b - Remove 'web' as it requires too many things we don't use. 2009-10-23 08:10:53 +00:00
Jordan Sissel
ddc06fd32b - Update INSTALL docs 2009-10-23 06:56:45 +00:00
Jordan Sissel
b4b831ce9d - version bump for stomp removal 2009-10-21 08:32:13 +00:00
Jordan Sissel
bb22cf63b7 - purge stomp 2009-10-21 08:30:45 +00:00
Pete Fritchman
168ca8cbf5 - include lib/clients/ in logstash-libs RPM 2009-10-21 07:10:27 +00:00
Jordan Sissel
4a3d5f2e8b - explicitly catch Ferret::FileNotFound 2009-10-21 02:47:53 +00:00
Pete Fritchman
04d2cee11e - fix pid/dying? logic
- handle exceptions from get_ferret (trying to search unindexed log types)
- die if we can't create a new index
2009-10-21 02:38:26 +00:00
Jordan Sissel
af918884c9 - default search query includes 'AND -@NEEDSPARSING:1' unless we have
@NEEDSPARSING in the query
2009-10-21 02:19:36 +00:00
Jordan Sissel
1b7e57b8d0 - Update Clients::Search to block on the search ops.
Clients::Search#search now returns [hits, results_array]
2009-10-21 02:06:38 +00:00
Jordan Sissel
a35abbbdad - factor out search client
- make web and bin/search.rb use the new search client class
2009-10-21 01:58:42 +00:00
Jordan Sissel
15b830abc4 - use new BaseConfig for search tool
- limit search results to 100 for now
2009-10-21 01:32:55 +00:00
Jordan Sissel
f42fe931e1 - Use File.basename($0) 2009-10-21 01:03:47 +00:00
Jordan Sissel
875a6a9fee - make the agent use LogStash::Program 2009-10-21 01:02:38 +00:00
Jordan Sissel
21f04f4e8b - remove debugging
- abort if @daemonize and no @logfile set
2009-10-21 01:00:26 +00:00
Pete Fritchman
4879992ab2 - add lib/program.rb to logstash-libs 2009-10-21 00:52:49 +00:00
Jordan Sissel
a2c4c15918 - Add workaround for signal/syscall interruption bug in ruby 1.8.5 2009-10-21 00:47:56 +00:00
Jordan Sissel
1ac4ed62a6 - facter out common program activities to LogStash::Program 2009-10-21 00:41:32 +00:00
Pete Fritchman
8b32b04aea - start using config values for connecting to the broker
- print some warnings when we are reconnecting to the broker (could be
  indicative of bad MQ settings)
2009-10-21 00:36:11 +00:00
Pete Fritchman
3db7ad4a77 - handle pidfile better on shutdown
- INT just calls TERM
2009-10-21 00:13:11 +00:00
Pete Fritchman
dc27987d9e - ENV["LOGSTASH_DIR"] is deprecated. 2009-10-20 23:52:40 +00:00
Pete Fritchman
6d685bfdcf - RPM spec file 2009-10-20 21:57:00 +00:00
Pete Fritchman
e5c9d75efd - fix init script 2009-10-20 21:56:19 +00:00
Jordan Sissel
9ad4e04f89 - open with happier mode (create if not exist, open readwrite) 2009-10-20 21:53:29 +00:00
Pete Fritchman
f3ba581fcb - we want "w+" for the pidfile open because it may not exist yet 2009-10-20 21:24:41 +00:00
Pete Fritchman
282d153d11 - logstash-agent init script & configuration 2009-10-20 21:07:38 +00:00
Pete Fritchman
811ee9410c - make status & condrestart work 2009-10-20 21:07:28 +00:00
Pete Fritchman
a6bb2b9405 - rename agent.rb to logstash-agent 2009-10-20 20:59:47 +00:00
Jordan Sissel
2edda3d34c - Add locking to our pidfile. 2009-10-20 20:59:08 +00:00
Pete Fritchman
b9f811eea5 - fix pattern_dir support (again)
- some defaults
2009-10-20 20:50:02 +00:00
Pete Fritchman
7e7dc90cfa - proper support for pattern_dir 2009-10-20 20:37:57 +00:00
Pete Fritchman
a9bc1324f0 - If one of our children dies, send ourselves a SIGTERM and do a clean
shutdown. We want our OS/watcher/whatever to know logstash is dead,
  rather than continue to run with random children dead.
- Remove pidfile on shutdown
2009-10-20 20:35:16 +00:00
Pete Fritchman
4a70384313 - logfile option 2009-10-20 20:19:46 +00:00
Pete Fritchman
2711d2a6f6 - first pass at rhel init script & sample sysconfig 2009-10-20 20:13:53 +00:00
Pete Fritchman
24169ef165 - refactor agent to be a real daemon
- refactor configs (all inherit from BaseConfig)
- move beef of agent code to lib/net/clients/
- use optionparser's ".order" instead of ".parse"
2009-10-20 17:40:44 +00:00
Jordan Sissel
26082d9309 - Proper daemonizing
- Add --logfile for directing STDOUT and STDERR to a file.
- Require logfile if we are to daemonize
- Set parent process $0 to 'logstash (supervisor)'
2009-10-20 06:59:02 +00:00
Pete Fritchman
c151016413 - support daemonizing
- support a pid file
- set $0 on our indexer & parser children
- handle INT and TERM signals (clean up children)
- switch to waitpid/WNOHANG/sleep(5) loop instead of Process.waitall because
  of a lame bug with ruby 1.8.5 and SIGTERM
2009-10-20 04:55:34 +00:00