Ignore:
Timestamp:
02/06/07 01:29:41 (18 years ago)
Author:
psmith
Message:

Updates to logging server for cmd line usage

Location:
branches/home/psmith/restructure/src/nio-logger
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified branches/home/psmith/restructure/src/nio-logger/nio-logger.lisp

    r66 r72  
    5959(defparameter +log-file-name+ "./out")
    6060
    61 (defun run-logging-server()
     61(defun run-logging-server(listen-ip out-file &optional (allowed-ips "ips.txt"))
    6262  (setf nio-yarpc:+process-jobs-inline+ nil)
    63   (nio:load-ips "ips.txt")
    64   (sb-thread:make-thread #'(lambda()(nio:start-server 'identity 'identity 'nio-yarpc:yarpc-state-machine :host "127.0.0.1" :accept-connection 'nio:check-ip)) :name "nio-server")
     63  (setf  +log-file-name+ out-file)
     64  (nio:load-ips allowed-ips)
     65  (sb-thread:make-thread #'(lambda()(nio:start-server 'identity 'identity 'nio-yarpc:yarpc-state-machine :host listen-ip :accept-connection 'nio:check-ip)) :name "nio-server")
    6566  (loop
    6667    ;;block waiting for jobs
  • TabularUnified branches/home/psmith/restructure/src/nio-logger/run-logging-server.lisp

    r61 r72  
    2929(require :asdf)
    3030(require :nio-logger)
    31 (nio-logger:run-logging-server)
     31
     32(let ((listen-ip (second sb-ext:*posix-argv*))
     33      (out-file (third sb-ext:*posix-argv*))
     34      (allowed-ips-filename (fourth sb-ext:*posix-argv*)))
     35  (format t "Starting logging Server with ~A ~A ~A~%" listen-ip out-file allowed-ips-filename)
     36  (nio-logger:run-logging-server listen-ip out-file allowed-ips-filename))
  • TabularUnified branches/home/psmith/restructure/src/nio-logger/run.sh

    r71 r72  
    22#
    33# run.sh <logging-client in-file dest-ip>
    4 # run.sh <logging-server out-file>
     4# run.sh <logging-server listen-ip out-file allowed-ips-filename>
    55#
    66
    77export LANG=en_US.UTF-8
    8 sbcl --load run-$1.lisp --end-toplevel-options $2 $3
     8sbcl --load run-$1.lisp --end-toplevel-options $2 $3 $4
Note: See TracChangeset for help on using the changeset viewer.