933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
|
;;======================================================================
;; Server? Start up here.
;;
(if (args:get-arg "-server")
(let* ((run-id (args:get-arg "-run-id"))
(dbfname (args:get-arg "-db"))
(tl (launch:setup)))
(case (rmt:transport-mode)
((http)(http-transport:launch))
((tcp)
(debug:print 0 *default-log-port* "INFO: Running using tcp method.")
(if run-id
(tt:start-server tl run-id dbfname api:tcp-dispatch-request-make-handler)
(begin
(debug:print 0 *default-log-port* "ERROR: transport mode is tcp - -run-id is required.")
(exit 1))))
(else (debug:print 0 *default-log-port* "ERROR: rmt:transport-mode value not recognised "(rmt:transport-mode))))
(set! *didsomething* #t)))
;; The adjutant is a bit different, it does NOT run (launch:setup) as it is not necessarily tied to
|
|
>
|
|
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
|
;;======================================================================
;; Server? Start up here.
;;
(if (args:get-arg "-server")
(let* ((run-id (args:get-arg "-run-id"))
(dbfname (args:get-arg "-db"))
(tl (launch:setup))
(keys (keys:config-get-fields *configdat*)))
(case (rmt:transport-mode)
((http)(http-transport:launch))
((tcp)
(debug:print 0 *default-log-port* "INFO: Running using tcp method.")
(if run-id
(tt:start-server tl run-id dbfname api:tcp-dispatch-request-make-handler keys)
(begin
(debug:print 0 *default-log-port* "ERROR: transport mode is tcp - -run-id is required.")
(exit 1))))
(else (debug:print 0 *default-log-port* "ERROR: rmt:transport-mode value not recognised "(rmt:transport-mode))))
(set! *didsomething* #t)))
;; The adjutant is a bit different, it does NOT run (launch:setup) as it is not necessarily tied to
|