My original plan was to tie the RPC call into gadgets.log so this would 
work for existing gadgets as well.  I then realized I would be adding a 
dependency to RPC and gadgets.log is a core feature so that did not seem 
like a good approach.  I guess creating a new feature would be the only 
way to do this, unfortunately it would require gadgets to explicitly 
require that feature in order to have the rpc function called.

-Ryan

Email: [email protected]
Phone: 978-899-3041
developerWorks Profile



From:   Michael Hermanto <[email protected]>
To:     [email protected], 
Date:   07/27/2011 01:46 AM
Subject:        Re: Enhancing gadgets.log



Good idea. In fact, I've heard (before) a use case where a gadget wants to
log and report back to the container (gadgets.config.init'ed as necessary 
by
container basis), so the parent can do container-specific logging back to
the server. Echoing what John says, don't tie gadgets.rpc into gadgets.log
(and add size). I'd suggest to extend gadgets.log into a new feature that
does logging and rpcing.

2011/7/26 ๏̯͡๏ Jasvir Nagra <[email protected]>

> On Tue, Jul 26, 2011 at 1:37 PM, Ryan J Baxter <[email protected]>
> wrote:
>
> > I would probably be calling the RPC handler in logAtLevel with the 
level
> > and the message.
> >
>
> Great.  My worry (and it's really not a big worry because the only 
effect
> it
> will have on semantics is what gets logged) is rpc'ing the log level and
> the
> message in separate rpcs because then the order matters.
>
>
> >
> > -Ryan
> >
> > Email: [email protected]
> > Phone: 978-899-3041
> > developerWorks Profile
> >
> >
> >
> > From:   ๏̯͡๏ Jasvir Nagra <[email protected]>
> > To:     [email protected],
> > Date:   07/26/2011 04:35 PM
> > Subject:        Re: Enhancing gadgets.log
> >
> >
> >
> > +1.
> >
> > Presumably you won't be hooking up gadgets.setLogLevel for rpc'ing.
>  Since
> > gadgets.log does not return a value, hooking it up to something that 
has
> > async semantics doesn't seem problematic to me.
> >
> > On Tue, Jul 26, 2011 at 1:27 PM, Ryan J Baxter <[email protected]>
> > wrote:
> >
> > > Today the gadgets.log API essentially logs to the windows console. 
The
> > > problem is there is no way to "hook into" gadgets.log to log the
> > > information elsewhere.  There are some application that have other
> > > existing logging mechanisms, or where the console is not available.
> > Would
> > > anyone by opposed to adding an rpc call to gadgets.log so 
applications
> > can
> > > register there own handlers and log the information using other 
means
> if
> > > they want?
> > >
> > > -Ryan
> > >
> > > Email: [email protected]
> > > Phone: 978-899-3041
> > > developerWorks Profile
> > >
> > >
> >
> >
> >
> >
>



Reply via email to