[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MirageOS-devel] Logging


  • To: Anil Madhavapeddy <anil@xxxxxxxxxx>
  • From: Drup <drupyog+caml@xxxxxxxx>
  • Date: Tue, 12 May 2015 17:48:09 +0200
  • Cc: "mirageos-devel@xxxxxxxxxxxxxxxxxxxx" <mirageos-devel@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Tue, 12 May 2015 15:48:19 +0000
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=zapps768; d=zoho.com; h=message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type; b=a5DkvG7GgPpv4CqUimcyJHTZN0M8W6j5+uYQ6aRqzgiu0AZOlYexC48Iq5XZ31ryUKFS8yRKZ07Z ip9bPjx8rJf5tWRZL4gxrUDF5FQ5z9CCvMbr1gntd8lJSjiqaFF1
  • List-id: Developer list for MirageOS <mirageos-devel.lists.xenproject.org>

Agreed. I had in mind a branching structure that would include a branch per 
component, followed by the debug levels.  Other listeners could then do 
aggregation into different views, including operations such as time-based 
rotation and aggregation across components.  For an Irmin backend, such 
listeners can just be watchers (either offline or online, which is nice!).
If I understand correctly, this would allow to encode Lwt_log's sections quite easily, is that right ? It is a feature that I found rather lacking in other logging libraries (in particular, dolog).

I like your "only one function" idea.
The alternative of passing around the unique function is to have a global reference containing the dispatcher function. It's the solution used by Lwt_log. It's mostly equivalent (and it works ok in practice) but I think it's indeed better to pass the function explicitly.

I'm not really convinced by the extension syntax trick (it was done for Lwt_log too and it uses a very syntactic criteria, which makes it a bit fishy). What would it do exactly ? Can't you rely on partial evaluation and Flambda's inlining to do the correct thing ?


_______________________________________________
MirageOS-devel mailing list
MirageOS-devel@xxxxxxxxxxxxxxxxxxxx
http://lists.xenproject.org/cgi-bin/mailman/listinfo/mirageos-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.