You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by Jean-Philippe Courson <co...@noos.fr> on 2002/04/29 13:34:41 UTC

Re: ContentInterceptors tests

Christopher Lenz wrote:
 > Have you successfully tested the stuff I've committed ?
 > It'd be great if you could test if all the ContentInterceptor hooks
 > are correctly called. I currently don't have the time to setup a
 > test environment for the changes, so I think it might be easier for
 > you to do the basic testing, as you have your UserQuota stuff
 > in-place already.
 >
 > BTW, preRetrieveContent is not yet being called. I'll look into
 > implementing that ASAP.

Hi Chris,

I have successfully tested the commited stuff with the pre/post store
and remove hooks.

I have performed these tests with the UserQuotaContentInterceptor that
is ready in my side to be commited, except that I think it requires 
another vote due to API modifications :

To be able to support user quota, slide should first have a way to
tell clients that they don't have enougth storage space. This done by 
sending them back a 507 http status.

But to be able to send such status, webdavServlet should have a way to
clearly identify these case, the simpliest one beeing to catch a
specific exception.

This is why Remy suggested some times ago to add a new Exception that we
could name InsufficientStorageException.

The problem is that this exception have to be thrown back to client by
content stores so InsufficientStorageException have to be added to the 
throws clause of the following methods of Content Store interface :

void create(SlideToken token, String strUri,
             NodeRevisionDescriptor revisionDescriptor,
             NodeRevisionContent revisionContent)
void create(SlideToken token, String strUri, String branch,
             NodeRevisionDescriptor newRevisionDescriptor,
             NodeRevisionContent revisionContent)
void fork(SlideToken token, String strUri, String branchName,
           NodeRevisionDescriptor basedOnRevisionDescriptor)
void fork(SlideToken token, String strUri, String branchName,
           NodeRevisionNumber basedOnRevisionNumber)
void merge(SlideToken token, String strUri,
            NodeRevisionDescriptor mainBranch,
            NodeRevisionDescriptor branch,
            NodeRevisionDescriptor newRevisionDescriptor,
            NodeRevisionContent revisionContent)
void merge(SlideToken token, String strUri,
            String mainBranch, String branch,
            NodeRevisionDescriptor newRevisionDescriptor,
            NodeRevisionContent revisionContent)
void store(SlideToken token, String strUri,
            NodeRevisionDescriptor revisionDescriptor,
            NodeRevisionContent revisionContent)

So my question is : do you think (like me) that these Content Store
API modifications are required and if yes is a vote required ?

Regards

jp


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>