Hi Evert,

Thanks for the links. This will help me a lot.

I have some random remarks:

- In the DebugPlugin you do not define how many log levels you have.
- Due to the parameters which have to be given in the constructor the
plugin can only be used for writing log files. It would not be possible to
create a DebugPlugin with a database-based backend. It would be cool if
there would be a "backend-neutral" interface which your debug plugin
implements. Then other programmers could easily create other debug plugins.
- On the WritingPlugins wiki page it is nowhere written if the initialize
method is really needed or not and when exactly it is invoked and with
which parameters.
- On the same page it says "beforeMethod is called whenever any http method
handler is called.". Wouldn't it be better to write "beforeMethod is called
right before a http method handler is called."? Or does it not happen right
before the http method is called?
- It would be good as well if this page answers as well the question what
happens when serveral methods are subscribed to the same event. E.g:

$server->subscribeEvent('beforeMethod','foo');
$server->subscribeEvent('beforeMethod','bar');

In what order will they be called etc.

These are just a few questions that came to my mind when reading the two
pages. It would be great if you would find the time to update the wiki page
etc.

But thanks for the work so far.

Raffael


On Mon, Jan 27, 2014 at 2:18 AM, Evert Pot <evert...@gmail.com> wrote:

> Hello Raffael,
>
> It kinda depends on what you are trying to log, but most actions can be
> intercepted by using the event system.
>
> I've started work on a debug plugin, specifically for that purpose.
> Haven't had a lot of time to dig into it though. You can find it here:
>
>
> https://github.com/fruux/sabre-dav/blob/debugplugin/lib/Sabre/DAV/DebugPlugin.php
>
> Most events are described on the wiki. Keep in mind that most of the
> events will change in the upcoming sabredav release though:
>
> http://code.google.com/p/sabredav/wiki/WritingPlugins
>
> Hope this helps,
> Evert
>
>
> On Wednesday, January 22, 2014 9:40:18 AM UTC-5, Raffael Luthiger wrote:
>>
>> Hi,
>>
>> Is there already a logging class implemented which I could use? Or what
>> is the best way to implement some logging. I would like to log when someone
>> tries to log in with the wrong password etc.
>>
>> Regards,
>>
>> Raffael
>>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "SabreDAV Discussion" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/sabredav-discuss/VdxDv7GLcvo/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an email to
> sabredav-discuss+unsubscr...@googlegroups.com.
> To post to this group, send email to sabredav-discuss@googlegroups.com.
> Visit this group at http://groups.google.com/group/sabredav-discuss.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"SabreDAV Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sabredav-discuss+unsubscr...@googlegroups.com.
To post to this group, send email to sabredav-discuss@googlegroups.com.
Visit this group at http://groups.google.com/group/sabredav-discuss.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to