X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;ds=sidebyside;f=helm%2Fuwobo%2Fsrc%2Focaml%2Fuwobo.ml;h=c99b4907c9573929c7f16b6d3a67a188b5068ac4;hb=deebdaec7a8b0f678fe45a36fb821a9c82c6931d;hp=abe65f47c135753548e7956a1cde734ce27dde00;hpb=77994a44a78f2a0a510296bdc2ec8c9cf882b222;p=helm.git diff --git a/helm/uwobo/src/ocaml/uwobo.ml b/helm/uwobo/src/ocaml/uwobo.ml index abe65f47c..c99b4907c 100644 --- a/helm/uwobo/src/ocaml/uwobo.ml +++ b/helm/uwobo/src/ocaml/uwobo.ml @@ -34,7 +34,7 @@ open Uwobo_common;; let debug = true;; let debug_level = `Debug;; let debug_print s = if debug then prerr_endline s;; -let http_debug = true;; +let http_debug = false;; Http_common.debug := http_debug;; (* environment settings *) @@ -125,10 +125,12 @@ let usage_string = in (* thread action *) -let callback req outchan = +let callback (req: Http_types.request) outchan = (* perform an 'action' that can be applied to a list of keys or, if no keys was given, to all keys *) - let act_on_keys req styles outchan per_key_action all_keys_action logmsg = + let act_on_keys (req: Http_types.request) + styles outchan per_key_action all_keys_action logmsg + = let log = new Uwobo_logger.processingLogger () in let keys = try @@ -246,7 +248,8 @@ let callback req outchan = outchan) | "/help" -> Http_daemon.respond ~body:usage_string outchan | invalid_request -> - Http_daemon.respond_error ~status:(`Client_error `Bad_request) outchan) + Http_daemon.respond_error ~status:(`Client_error `Bad_request) outchan); + syslogger#log `Debug (sprintf "%s done!" req#path); with | Http_types.Param_not_found attr_name -> bad_request (sprintf "Parameter '%s' is missing" attr_name) outchan