AW: version_history table's branch_id column
Do not use the Slide API directly, but use the webdavclient-library instead. You'll run into trouble if you want to use versioning. This is handled in the WebDAV-layer... Cheers, Daniel > -Ursprüngliche Nachricht- > Von: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] > Im Auftrag von Gao Jun > Gesendet: Montag, 6. Dezember 2004 08:44 > An: [EMAIL PROTECTED] > Betreff: version_history table's branch_id column > > Hi, > > I've some problem in using slide. When I use propfind on a folder I > created, I was told that folder doesn't exist. The backend log reads > "02 Dec 2004 02:27:02 5793672 DEBUG [tcpConnection-80-154] httpclient.wire > - << "HTTP/1.1 500 Internal Server Error: No revision descriptor found on > object MY_FOLDER_NAME[\r][\n]"" > > I created that folder with my own code listed below: > > //create the new folder > SubjectNode collection = new SubjectNode(); > structure.create(slideToken, collection, > folderName);//slide's original implement > > NodeRevisionDescriptor revisionDescriptor = new > NodeRevisionDescriptor(0); > // Resource type > revisionDescriptor.setResourceType(""); > > // Creation date > revisionDescriptor.setCreationDate(new Date()); > > // Last modification date > revisionDescriptor.setLastModified(new Date()); > > // Content length name > revisionDescriptor.setContentLength(0); > > // Source > revisionDescriptor.setSource(""); > > // Owner > String creator = > ((SubjectNode)security.getPrincipal(slideToken)).getPath().lastSegment(); > revisionDescriptor.setCreationUser(creator); > revisionDescriptor.setOwner(creator); > > // Added for DeltaV --start-- > if( Configuration.useVersionControl() ) > { > VersioningHelper vHelp = > VersioningHelper.getVersioningHelper( > slideToken, token, req, resp, getConfig() ); > > // Workspace > vHelp.setWorkspaceProperty( userLinkPath, > revisionDescriptor ); > } > // Added for DeltaV --end-- > > if (isMsProprietarySupport()) { > > NodeProperty property = null; > > // Is hidden > property = new NodeProperty("ishidden", "0", > "MICROSOFT"); > revisionDescriptor.setProperty(property); > > // Is collection > property = new NodeProperty("iscollection", "1", > "MICROSOFT"); > revisionDescriptor.setProperty(property); > > // Is read only > property = new NodeProperty("isreadonly", "0", > "MICROSOFT"); > revisionDescriptor.setProperty(property); > > // Last accessed > property = new NodeProperty("lastaccessed", > (new > Date()).toString(), "MICROSOFT"); > revisionDescriptor.setProperty(property); > } > content.create(slideToken, folderName, > revisionDescriptor, null); > ... > > I found the new folder name has been created in URI table. The odd thing I > found is > in the table version_history, the row for this new folder's URI has a > branch_id which > is a "backup" instead of "main" according to table branch. > > I have no idea of what this "backup" and "main" mean. Could anybody help > explain > and could you see what's the cause of my problem? Thanks a lot. > > regards, > > Jun > > > - > Do you Yahoo!? > Yahoo! Mail - You care about security. So do we. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Slide/WebDav server
Hello! Could you please explain, or where can I read about slide and WebDav server? It is impossible to deploy slide.war in the jboss in one host, and configure slide to work with WebDav server, for example, IIS or Apache2 in other host? Thanks. -- Best regards, Andrew mailto:[EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WCK API question
H. That's just not what I am seeing. I have a printout in each of my BasicWebdavStore implementation methods. Here's what I see when I use the slide webdav client to "put /etc/resolv.conf" into "/music" in my system. %% WebdavStoreImpl: begin %% objectExists: /music/resolv.conf %% objectExists: / %% getChildrenNames: / %% objectExists: /music %% getChildrenNames: /music %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music %% objectExists: /music %% objectExists: /music %% objectExists: /music/resolv.conf %% setResourceContent: /music/resolv.conf %% createResource: /music/resolv.conf %% WebdavStoreImpl: commit Note the order of the setResourceContent and createResource calls. Here's the trace for setResourceContent: java.lang.Exception: Stack trace at java.lang.Thread.dumpStack(Thread.java:1064) at com.ris.manager.gateway.http.WebdavStoreImpl.setResourceContent(WebdavStoreImpl.java:195) at org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionContent(WebdavStoreAdapter.java:520) at org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionContent(WebdavStoreAdapter.java:159) at org.apache.slide.store.AbstractStore.storeRevisionContent(AbstractStore.java:1474) at org.apache.slide.store.ExtendedStore.storeRevisionContent(ExtendedStore.java:546) at org.apache.slide.content.ContentImpl.create(ContentImpl.java:593) at org.apache.slide.webdav.method.PutMethod.executeRequest(PutMethod.java:407) at org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod.java:412) at org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java:151) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:354) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:342) at org.apache.slide.webdav.filter.LogFilter.doFilter(LogFilter.java:141) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) at com.ris.manager.gateway.http.IPAddressRestriction.doFilter(IPAddressRestriction.java:248) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:286) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567) at org.mortbay.http.HttpContext.handle(HttpContext.java:1808) at org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:525) at org.mortbay.http.HttpContext.handle(HttpContext.java:1758) at org.mortbay.http.HttpServer.service(HttpServer.java:879) at org.mortbay.http.HttpConnection.service(HttpConnection.java:790) at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:952) at org.mortbay.http.HttpConnection.handle(HttpConnection.java:807) at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:197) at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:289) at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:501) Here's the trace for createResource: at com.ris.manager.gateway.http.WebdavStoreImpl.createResource(WebdavStoreImpl.java:176) at org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionDescriptor(WebdavStoreAdapter.java:675) at org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionDescriptor(WebdavStoreAdapter.java:255) at org.apache.slide.store.AbstractStore.storeRevisionDescriptor(AbstractStore.java:1305) at org.apache.slide.store.ExtendedStore.storeRevisionDescriptor(ExtendedStore.java:1060) at org.apache.slide.content.ContentImpl.create(ContentImpl.java:608) at org.apache.slide.webdav.method.PutMethod.executeRequest(PutMethod.java:407) at org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod.java:412) at org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java:151) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:354) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:342) at org.apache.slide.webdav.filter.LogFilter.doFilter(LogFilter.java:141) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) at com.ris.manager.gateway.http.IPAddressRestriction.doFilter(IPAddressRestriction.java:248) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.do
Re: Performance
I am seeing this also (see my previous post). We can deal with Very Large Objects in our archive, and the hard-coded 2k buffer size in org/apache/slide/webdav/method/GetMethod.java was killing read performance. Getting a single chunk of data from our archive is a bit expensive, so I implemented a better buffering scheme (with a still hard-coded limit). Unified diff is attached. On my local machine, I went from ~115KB/sec reads to ~9MB/sec reads for large objects. If someone with commit privs would review, I would appreciate it. Thanks -John EngR H wrote: Hello Again! Am working with WCK, customized it to work on my DMS, the problem is that the performance is too slow! when i tried to debug and see which methods takes much time, I found that alot of methods are called twice, and don't know why, for example giving the uri of /files the following methods are called twice before going to the next level: getChildrenNames() readProperties() getLastModified() getLastModified() Is there any thing that should be adjusted?? or is that the normal behaviour of the WebdavServlet?? any suggestions?? Regards rony - Do you Yahoo!? The all-new My Yahoo! – What will yours do? --- GetMethod.java.~1.55.~ 2004-11-09 10:00:28.0 -0500 +++ GetMethod.java 2004-12-03 22:13:09.0 -0500 @@ -70,8 +70,11 @@ // -- Constants -protected final int BUFFER_SIZE = 2048; +/** The default buffer size */ +protected final int DEFAULT_BUFFER_SIZE = 2048; +/** The maximum buffer size */ +protected final int MAX_BUFFER_SIZE = 200 * 1024; /** @@ -393,7 +396,7 @@ (resourceInputStream, input); // Copy the input stream to the output stream -exception = copyRange(istream, ostream); +exception = copyRange(istream, ostream, resourceInfo.length); // Clean up the input and output streams try { @@ -544,11 +547,12 @@ * @return Exception which occured during processing */ private IOException copyRange(InputStream istream, - ServletOutputStream ostream) { + ServletOutputStream ostream, + long resourceLength) { // Copy the input stream to the output stream IOException exception = null; -byte buffer[] = new byte[input]; +byte buffer[] = new byte[getBufferSize(resourceLength)]; int len = buffer.length; while (true) { try { @@ -591,7 +595,7 @@ IOException exception = null; long bytesToRead = end - start + 1; -byte buffer[] = new byte[input]; +byte buffer[] = new byte[getBufferSize(bytesToRead)]; int len = buffer.length; while ( (bytesToRead > 0) && (len >= buffer.length)) { try { @@ -615,6 +619,16 @@ } +/** + * Get a reasonable buffer size. + */ +private int getBufferSize(long resourceLength) +{ +if (resourceLength <= 0) +return DEFAULT_BUFFER_SIZE; + +return (int)Math.min(resourceLength, MAX_BUFFER_SIZE); +} /** * Parse the range header. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Unique ID for a document in the slide repository ?
Hi It seems that the uri for a document (resource) in the slide repository is the only unique identifier. This poses problems for applications which record the id elsewhere, like in a database, and then have to deal with a rename of a node upstream in the document's parent tree. Is there any other id, such as a guid, for identifiying the resource ? Nick
Re: WCK API question
OK, then just throw the ObjectNotFoundException if the object is not there as indicated in the last post. Concerning the occurennce of the method calls, they are just needed by the Slide core... Oliver On Mon, 06 Dec 2004 10:51:18 -0500, John Rousseau <[EMAIL PROTECTED]> wrote: > H. That's just not what I am seeing. I have a printout in each of my > BasicWebdavStore implementation methods. > > Here's what I see when I use the slide webdav client to "put > /etc/resolv.conf" into "/music" in my system. > > %% WebdavStoreImpl: begin > %% objectExists: /music/resolv.conf > %% objectExists: / > %% getChildrenNames: / > %% objectExists: /music > %% getChildrenNames: /music > %% objectExists: /music/resolv.conf > %% objectExists: /music/resolv.conf > %% objectExists: /music/resolv.conf > %% objectExists: /music/resolv.conf > %% objectExists: /music/resolv.conf > %% objectExists: /music > %% objectExists: /music > %% objectExists: /music > %% objectExists: /music/resolv.conf > %% setResourceContent: /music/resolv.conf > %% createResource: /music/resolv.conf > %% WebdavStoreImpl: commit > > Note the order of the setResourceContent and createResource calls. > > Here's the trace for setResourceContent: > java.lang.Exception: Stack trace > at java.lang.Thread.dumpStack(Thread.java:1064) > at > com.ris.manager.gateway.http.WebdavStoreImpl.setResourceContent(WebdavStoreImpl.java:195) > at > org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionContent(WebdavStoreAdapter.java:520) > at > org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionContent(WebdavStoreAdapter.java:159) > at > org.apache.slide.store.AbstractStore.storeRevisionContent(AbstractStore.java:1474) > at > org.apache.slide.store.ExtendedStore.storeRevisionContent(ExtendedStore.java:546) > at org.apache.slide.content.ContentImpl.create(ContentImpl.java:593) > at > org.apache.slide.webdav.method.PutMethod.executeRequest(PutMethod.java:407) > at > org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod.java:412) > at > org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java:151) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > at > org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:354) > at > org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:342) > at > org.apache.slide.webdav.filter.LogFilter.doFilter(LogFilter.java:141) > at > org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) > at > com.ris.manager.gateway.http.IPAddressRestriction.doFilter(IPAddressRestriction.java:248) > at > org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) > at > org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:286) > at > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567) > at org.mortbay.http.HttpContext.handle(HttpContext.java:1808) > at > org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:525) > at org.mortbay.http.HttpContext.handle(HttpContext.java:1758) > at org.mortbay.http.HttpServer.service(HttpServer.java:879) > at org.mortbay.http.HttpConnection.service(HttpConnection.java:790) > at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:952) > at org.mortbay.http.HttpConnection.handle(HttpConnection.java:807) > at > org.mortbay.http.SocketListener.handleConnection(SocketListener.java:197) > at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:289) > at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:501) > > Here's the trace for createResource: > at > com.ris.manager.gateway.http.WebdavStoreImpl.createResource(WebdavStoreImpl.java:176) > at > org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionDescriptor(WebdavStoreAdapter.java:675) > at > org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionDescriptor(WebdavStoreAdapter.java:255) > at > org.apache.slide.store.AbstractStore.storeRevisionDescriptor(AbstractStore.java:1305) > at > org.apache.slide.store.ExtendedStore.storeRevisionDescriptor(ExtendedStore.java:1060) > at org.apache.slide.content.ContentImpl.create(ContentImpl.java:608) > at > org.apache.slide.webdav.method.PutMethod.executeRequest(PutMethod.java:407) > at > org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod.java:412) > at > org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java:151) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > at > org.mortbay.jetty.servlet.ServletHolder.handle(Ser
Re: WCK API question
But if I throw ObjectNotFoundException from createResource, then (as I indicated in my initial post) rollback is called and the client gets a "412 Precondition Failed". Thanks -John Oliver Zeigermann wrote: OK, then just throw the ObjectNotFoundException if the object is not there as indicated in the last post. Concerning the occurennce of the method calls, they are just needed by the Slide core... Oliver On Mon, 06 Dec 2004 10:51:18 -0500, John Rousseau <[EMAIL PROTECTED]> wrote: H. That's just not what I am seeing. I have a printout in each of my BasicWebdavStore implementation methods. Here's what I see when I use the slide webdav client to "put /etc/resolv.conf" into "/music" in my system. %% WebdavStoreImpl: begin %% objectExists: /music/resolv.conf %% objectExists: / %% getChildrenNames: / %% objectExists: /music %% getChildrenNames: /music %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music/resolv.conf %% objectExists: /music %% objectExists: /music %% objectExists: /music %% objectExists: /music/resolv.conf %% setResourceContent: /music/resolv.conf %% createResource: /music/resolv.conf %% WebdavStoreImpl: commit Note the order of the setResourceContent and createResource calls. Here's the trace for setResourceContent: java.lang.Exception: Stack trace at java.lang.Thread.dumpStack(Thread.java:1064) at com.ris.manager.gateway.http.WebdavStoreImpl.setResourceContent(WebdavStoreImpl.java:195) at org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionContent(WebdavStoreAdapter.java:520) at org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionContent(WebdavStoreAdapter.java:159) at org.apache.slide.store.AbstractStore.storeRevisionContent(AbstractStore.java:1474) at org.apache.slide.store.ExtendedStore.storeRevisionContent(ExtendedStore.java:546) at org.apache.slide.content.ContentImpl.create(ContentImpl.java:593) at org.apache.slide.webdav.method.PutMethod.executeRequest(PutMethod.java:407) at org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod.java:412) at org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java:151) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:354) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:342) at org.apache.slide.webdav.filter.LogFilter.doFilter(LogFilter.java:141) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) at com.ris.manager.gateway.http.IPAddressRestriction.doFilter(IPAddressRestriction.java:248) at org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:286) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567) at org.mortbay.http.HttpContext.handle(HttpContext.java:1808) at org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:525) at org.mortbay.http.HttpContext.handle(HttpContext.java:1758) at org.mortbay.http.HttpServer.service(HttpServer.java:879) at org.mortbay.http.HttpConnection.service(HttpConnection.java:790) at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:952) at org.mortbay.http.HttpConnection.handle(HttpConnection.java:807) at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:197) at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:289) at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:501) Here's the trace for createResource: at com.ris.manager.gateway.http.WebdavStoreImpl.createResource(WebdavStoreImpl.java:176) at org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionDescriptor(WebdavStoreAdapter.java:675) at org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionDescriptor(WebdavStoreAdapter.java:255) at org.apache.slide.store.AbstractStore.storeRevisionDescriptor(AbstractStore.java:1305) at org.apache.slide.store.ExtendedStore.storeRevisionDescriptor(ExtendedStore.java:1060) at org.apache.slide.content.ContentImpl.create(ContentImpl.java:608) at org.apache.slide.webdav.method.PutMethod.executeRequest(PutMethod.java:407) at org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod.java:412) at org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java:151) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:354) at org.mor
RE: Performance
John, thanks for the fix! Would you mind opening a bug for this in bugzilla so we can be sure that this fix isn't overlooked? And we can be sure a committer will look at it. Here's a link to the Slide "open bug" page: http://issues.apache.org/bugzilla/enter_bug.cgi?product=Slide Thanks, Warwick > -Original Message- > From: John Rousseau [mailto:[EMAIL PROTECTED] > Sent: Monday, December 06, 2004 10:01 AM > To: Slide Users Mailing List > Subject: Re: Performance > > > I am seeing this also (see my previous post). > > We can deal with Very Large Objects in our archive, and the > hard-coded 2k buffer size in > org/apache/slide/webdav/method/GetMethod.java was killing > read performance. Getting a single chunk of data from our > archive is a bit expensive, so I implemented a better > buffering scheme (with a still hard-coded limit). Unified > diff is attached. > > On my local machine, I went from ~115KB/sec reads to ~9MB/sec > reads for large objects. > > If someone with commit privs would review, I would appreciate it. > > Thanks > -John > > > > > EngR H wrote: > > Hello Again! > > > > Am working with WCK, customized it to work on my DMS, the > problem is > > that the performance is too slow! when i tried to debug and > see which > > methods takes much time, I found that alot of methods are called > > twice, and don't know why, for example giving the uri of /files the > > following methods are called twice before going to the next level: > > getChildrenNames() readProperties() getLastModified() > > getLastModified() > > > > Is there any thing that should be adjusted?? or is that the normal > > behaviour of the WebdavServlet?? > > > > any suggestions?? > > > > Regards rony > > > > - Do you Yahoo!? The > all-new My Yahoo! > > - What will yours do? > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Exceptions on MySQL 4.1
I have upgraded my database to MySQL 4.1 and changed the adapter to "MySql41RDBMSAdapter" in Domain.xml. I also dropped my old Slide database and created a fresh database using the MySQL 4.1 Slide db script. The first startup worked fine, and I was able to access the repository through the WebDAV client API (note that I ran into the same deadlock issues...). Now, every time I start Tomcat, I get the following exceptions in the log. If I try to hit Slide using the browser, it complains about the actions cache not being loaded and also spits out an exception in the logs (at the bottom, below). Any ideas? -Mirko At startup: 06 Dec 2004 14:36:38 - org.apache.slide.common.XMLUnmarshaller - INFO - Loading object / 06 Dec 2004 14:36:38 - org.apache.slide.common.XMLUnmarshaller - INFO - Object already exists at / 06 Dec 2004 14:36:38 - org.apache.slide.store.impl.rdbms.MySqlRDBMSAdapter - ERROR - SQL error 1267 on /: General error message from server: "Illegal mix of collations (utf8_general_ci,IMPLICIT) and (latin1_swedish_ci,COERCIBLE) for operation 'substr_index'" org.apache.slide.common.ServiceAccessException: Service [EMAIL PROTECTED] access error : General error message from server: "Illegal mix of collations (utf8_general_ci,IMPLICIT) and (latin1_swedish_ci,COERCIBLE) for operation 'substr_index'" at org.apache.slide.store.impl.rdbms.MySqlRDBMSAdapter.createException(MySqlRDBMSAdapter.java:66) at org.apache.slide.store.impl.rdbms.StandardRDBMSAdapter.retrieveRevisionDescriptors(StandardRDBMSAdapter.java:942) at org.apache.slide.store.impl.rdbms.AbstractRDBMSStore.retrieveRevisionDescriptors(AbstractRDBMSStore.java:652) at org.apache.slide.store.AbstractStore.retrieveRevisionDescriptors(AbstractStore.java:996) at org.apache.slide.store.ExtendedStore.retrieveRevisionDescriptors(ExtendedStore.java:816) at org.apache.slide.content.ContentImpl.retrieve(ContentImpl.java:168) at org.apache.slide.common.XMLUnmarshaller.loadObjectRevision(XMLUnmarshaller.java:340) at org.apache.slide.common.XMLUnmarshaller.loadDefaultObjectRevision(XMLUnmarshaller.java:307) at org.apache.slide.common.XMLUnmarshaller.loadObjectNode(XMLUnmarshaller.java:237) at org.apache.slide.common.XMLUnmarshaller.unmarshal(XMLUnmarshaller.java:90) at org.apache.slide.common.NamespaceAccessTokenImpl.importData(NamespaceAccessTokenImpl.java:272) at org.apache.slide.common.Namespace.loadBaseData(Namespace.java:808) at org.apache.slide.common.Domain.initNamespace(Domain.java:845) at org.apache.slide.common.Domain.init(Domain.java:432) at org.apache.slide.common.Domain.init(Domain.java:366) at org.apache.slide.common.Domain.init(Domain.java:329) at org.apache.slide.webdav.WebdavServlet.init(WebdavServlet.java:253) at javax.servlet.GenericServlet.init(GenericServlet.java:211) at org.apache.slide.webdav.WebdavServlet.init(WebdavServlet.java:195) at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1029) at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:862) at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4013) at org.apache.catalina.core.StandardContext.start(StandardContext.java:4357) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:823) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:807) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:595) at org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:277) at org.apache.catalina.core.StandardHost.install(StandardHost.java:832) at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:617) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:431) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:968) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:349) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1091) at org.apache.catalina.core.StandardHost.start(StandardHost.java:789) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1083) at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:478) at org.apache.catalina.core.StandardService.start(StandardService.java:480) at org.apache.catalina.core.StandardServer.start(StandardServer.java:2313) at org.apache.catalina.startup.Catalina.start(Catalina.java:556) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.in
Re: Exceptions on MySQL 4.1
May be true, I did my tests with the 4.0 schema and it worked just fine. No idea what the original problem is. Anyway, use the 4.0 schema even for 4.1 and it should work. Oliver On Mon, 06 Dec 2004 14:44:48 -0800, Mirko Froehlich <[EMAIL PROTECTED]> wrote: > I have upgraded my database to MySQL 4.1 and changed the adapter to > "MySql41RDBMSAdapter" in Domain.xml. I also dropped my old Slide > database and created a fresh database using the MySQL 4.1 Slide db > script. The first startup worked fine, and I was able to access the > repository through the WebDAV client API (note that I ran into the same > deadlock issues...). Now, every time I start Tomcat, I get the following > exceptions in the log. If I try to hit Slide using the browser, it > complains about the actions cache not being loaded and also spits out an > exception in the logs (at the bottom, below). Any ideas? > > -Mirko > > At startup: > > > 06 Dec 2004 14:36:38 - org.apache.slide.common.XMLUnmarshaller - INFO - > Loading object / > 06 Dec 2004 14:36:38 - org.apache.slide.common.XMLUnmarshaller - INFO - > Object already exists at / > 06 Dec 2004 14:36:38 - > org.apache.slide.store.impl.rdbms.MySqlRDBMSAdapter - ERROR - SQL error > 1267 on /: General error message from server: "Illegal mix of collations > (utf8_general_ci,IMPLICIT) and (latin1_swedish_ci,COERCIBLE) for > operation 'substr_index'" > org.apache.slide.common.ServiceAccessException: Service > [EMAIL PROTECTED] access error : > General error message from server: "Illegal mix of collations > (utf8_general_ci,IMPLICIT) and (latin1_swedish_ci,COERCIBLE) for > operation 'substr_index'" > at > org.apache.slide.store.impl.rdbms.MySqlRDBMSAdapter.createException(MySqlRDBMSAdapter.java:66) > at > org.apache.slide.store.impl.rdbms.StandardRDBMSAdapter.retrieveRevisionDescriptors(StandardRDBMSAdapter.java:942) > at > org.apache.slide.store.impl.rdbms.AbstractRDBMSStore.retrieveRevisionDescriptors(AbstractRDBMSStore.java:652) > at > org.apache.slide.store.AbstractStore.retrieveRevisionDescriptors(AbstractStore.java:996) > at > org.apache.slide.store.ExtendedStore.retrieveRevisionDescriptors(ExtendedStore.java:816) > at > org.apache.slide.content.ContentImpl.retrieve(ContentImpl.java:168) > at > org.apache.slide.common.XMLUnmarshaller.loadObjectRevision(XMLUnmarshaller.java:340) > at > org.apache.slide.common.XMLUnmarshaller.loadDefaultObjectRevision(XMLUnmarshaller.java:307) > at > org.apache.slide.common.XMLUnmarshaller.loadObjectNode(XMLUnmarshaller.java:237) > at > org.apache.slide.common.XMLUnmarshaller.unmarshal(XMLUnmarshaller.java:90) > at > org.apache.slide.common.NamespaceAccessTokenImpl.importData(NamespaceAccessTokenImpl.java:272) > at > org.apache.slide.common.Namespace.loadBaseData(Namespace.java:808) > at org.apache.slide.common.Domain.initNamespace(Domain.java:845) > at org.apache.slide.common.Domain.init(Domain.java:432) > at org.apache.slide.common.Domain.init(Domain.java:366) > at org.apache.slide.common.Domain.init(Domain.java:329) > at > org.apache.slide.webdav.WebdavServlet.init(WebdavServlet.java:253) > at javax.servlet.GenericServlet.init(GenericServlet.java:211) > at > org.apache.slide.webdav.WebdavServlet.init(WebdavServlet.java:195) > at > org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1029) > at > org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:862) > at > org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4013) > at > org.apache.catalina.core.StandardContext.start(StandardContext.java:4357) > at > org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:823) > at > org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:807) > at > org.apache.catalina.core.StandardHost.addChild(StandardHost.java:595) > at > org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:277) > at > org.apache.catalina.core.StandardHost.install(StandardHost.java:832) > at > org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:617) > at > org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:431) > at > org.apache.catalina.startup.HostConfig.start(HostConfig.java:968) > at > org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:349) > at > org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) > at > org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1091) > at > org.apache.catalina.core.StandardHost.start(StandardHost.java:789) > at > org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1083) > at > org.apache.catalina.core.StandardEngine.start(StandardEngine.java:478)
Re: WCK API question
You should throw in setResourceCountent, not in createResource. Oliver On Mon, 06 Dec 2004 12:10:04 -0500, John Rousseau <[EMAIL PROTECTED]> wrote: > But if I throw ObjectNotFoundException from createResource, then (as I > indicated in my initial post) rollback is called and the client gets a > "412 Precondition Failed". > > Thanks > -John > > > > > Oliver Zeigermann wrote: > > OK, then just throw the ObjectNotFoundException if the object is not > > there as indicated in the last post. > > > > Concerning the occurennce of the method calls, they are just needed by > > the Slide core... > > > > Oliver > > > > On Mon, 06 Dec 2004 10:51:18 -0500, John Rousseau > > <[EMAIL PROTECTED]> wrote: > > > >>H. That's just not what I am seeing. I have a printout in each of my > >>BasicWebdavStore implementation methods. > >> > >>Here's what I see when I use the slide webdav client to "put > >>/etc/resolv.conf" into "/music" in my system. > >> > >>%% WebdavStoreImpl: begin > >>%% objectExists: /music/resolv.conf > >>%% objectExists: / > >>%% getChildrenNames: / > >>%% objectExists: /music > >>%% getChildrenNames: /music > >>%% objectExists: /music/resolv.conf > >>%% objectExists: /music/resolv.conf > >>%% objectExists: /music/resolv.conf > >>%% objectExists: /music/resolv.conf > >>%% objectExists: /music/resolv.conf > >>%% objectExists: /music > >>%% objectExists: /music > >>%% objectExists: /music > >>%% objectExists: /music/resolv.conf > >>%% setResourceContent: /music/resolv.conf > >>%% createResource: /music/resolv.conf > >>%% WebdavStoreImpl: commit > >> > >>Note the order of the setResourceContent and createResource calls. > >> > >>Here's the trace for setResourceContent: > >>java.lang.Exception: Stack trace > >>at java.lang.Thread.dumpStack(Thread.java:1064) > >>at > >> com.ris.manager.gateway.http.WebdavStoreImpl.setResourceContent(WebdavStoreImpl.java:195) > >>at > >> org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionContent(WebdavStoreAdapter.java:520) > >>at > >> org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionContent(WebdavStoreAdapter.java:159) > >>at > >> org.apache.slide.store.AbstractStore.storeRevisionContent(AbstractStore.java:1474) > >>at > >> org.apache.slide.store.ExtendedStore.storeRevisionContent(ExtendedStore.java:546) > >>at org.apache.slide.content.ContentImpl.create(ContentImpl.java:593) > >>at > >> org.apache.slide.webdav.method.PutMethod.executeRequest(PutMethod.java:407) > >>at > >> org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod.java:412) > >>at > >> org.apache.slide.webdav.WebdavServlet.service(WebdavServlet.java:151) > >>at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > >>at > >> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:354) > >>at > >> org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:342) > >>at > >> org.apache.slide.webdav.filter.LogFilter.doFilter(LogFilter.java:141) > >>at > >> org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) > >>at > >> com.ris.manager.gateway.http.IPAddressRestriction.doFilter(IPAddressRestriction.java:248) > >>at > >> org.mortbay.jetty.servlet.WebApplicationHandler$Chain.doFilter(WebApplicationHandler.java:334) > >>at > >> org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:286) > >>at > >> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567) > >>at org.mortbay.http.HttpContext.handle(HttpContext.java:1808) > >>at > >> org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:525) > >>at org.mortbay.http.HttpContext.handle(HttpContext.java:1758) > >>at org.mortbay.http.HttpServer.service(HttpServer.java:879) > >>at org.mortbay.http.HttpConnection.service(HttpConnection.java:790) > >>at > >> org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:952) > >>at org.mortbay.http.HttpConnection.handle(HttpConnection.java:807) > >>at > >> org.mortbay.http.SocketListener.handleConnection(SocketListener.java:197) > >>at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:289) > >>at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:501) > >> > >>Here's the trace for createResource: > >>at > >> com.ris.manager.gateway.http.WebdavStoreImpl.createResource(WebdavStoreImpl.java:176) > >>at > >> org.apache.slide.simple.store.WebdavStoreAdapter$TransactionId.storeRevisionDescriptor(WebdavStoreAdapter.java:675) > >>at > >> org.apache.slide.simple.store.WebdavStoreAdapter.storeRevisionDescriptor(WebdavStoreAdapter.java:255) > >>at > >> org.apache.slide.store.AbstractStore.storeRevisionDescriptor(
Re: Exceptions on MySQL 4.1
In that case, should I continue to use the MySqlRDBMSAdapter, or should I use the MySql41RDBMSAdapter? -Mirko On Mon, 2004-12-06 at 16:25, Oliver Zeigermann wrote: > May be true, I did my tests with the 4.0 schema and it worked just > fine. No idea what the original problem is. Anyway, use the 4.0 schema > even for 4.1 and it should work. > > Oliver
Re: AW: version_history table's branch_id column
Thank you very much, Daniel. But could you give me a little more explanation about the "main" branch and the "backup" branch? I'm using webdavclient in most places. But there are one or two places where I need to create folder inside of the other webdav method, for example, I need to create a folder in ACLMethod so that when a folder is assigned to some user, accordingly, a system folder is created at the same time (to server our requirement). This is why we use the slide api directly in this place. I need to know a little more of the slide's logic in handling the versioning and branch, then I can make a decision of what to do in my application. Thanks. regards, Jun Daniel Florey <[EMAIL PROTECTED]> wrote: Do not use the Slide API directly, but use the webdavclient-library instead. You'll run into trouble if you want to use versioning. This is handled in the WebDAV-layer... Cheers, Daniel > -Ursprüngliche Nachricht- > Von: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] > Im Auftrag von Gao Jun > Gesendet: Montag, 6. Dezember 2004 08:44 > An: [EMAIL PROTECTED] > Betreff: version_history table's branch_id column > > Hi, > > I've some problem in using slide. When I use propfind on a folder I > created, I was told that folder doesn't exist. The backend log reads > "02 Dec 2004 02:27:02 5793672 DEBUG [tcpConnection-80-154] httpclient.wire > - << "HTTP/1.1 500 Internal Server Error: No revision descriptor found on > object MY_FOLDER_NAME[\r][\n]"" > > I created that folder with my own code listed below: > > //create the new folder > SubjectNode collection = new SubjectNode(); > structure.create(slideToken, collection, > folderName);//slide's original implement > > NodeRevisionDescriptor revisionDescriptor = new > NodeRevisionDescriptor(0); > // Resource type > revisionDescriptor.setResourceType(""); > > // Creation date > revisionDescriptor.setCreationDate(new Date()); > > // Last modification date > revisionDescriptor.setLastModified(new Date()); > > // Content length name > revisionDescriptor.setContentLength(0); > > // Source > revisionDescriptor.setSource(""); > > // Owner > String creator = > ((SubjectNode)security.getPrincipal(slideToken)).getPath().lastSegment(); > revisionDescriptor.setCreationUser(creator); > revisionDescriptor.setOwner(creator); > > // Added for DeltaV --start-- > if( Configuration.useVersionControl() ) > { > VersioningHelper vHelp = > VersioningHelper.getVersioningHelper( > slideToken, token, req, resp, getConfig() ); > > // Workspace > vHelp.setWorkspaceProperty( userLinkPath, > revisionDescriptor ); > } > // Added for DeltaV --end-- > > if (isMsProprietarySupport()) { > > NodeProperty property = null; > > // Is hidden > property = new NodeProperty("ishidden", "0", > "MICROSOFT"); > revisionDescriptor.setProperty(property); > > // Is collection > property = new NodeProperty("iscollection", "1", > "MICROSOFT"); > revisionDescriptor.setProperty(property); > > // Is read only > property = new NodeProperty("isreadonly", "0", > "MICROSOFT"); > revisionDescriptor.setProperty(property); > > // Last accessed > property = new NodeProperty("lastaccessed", > (new > Date()).toString(), "MICROSOFT"); > revisionDescriptor.setProperty(property); > } > content.create(slideToken, folderName, > revisionDescriptor, null); > ... > > I found the new folder name has been created in URI table. The odd thing I > found is > in the table version_history, the row for this new folder's URI has a > branch_id which > is a "backup" instead of "main" according to table branch. > > I have no idea of what this "backup" and "main" mean. Could anybody help > explain > and could you see what's the cause of my problem? Thanks a lot. > > regards, > > Jun > > > - > Do you Yahoo!? > Yahoo! Mail - You care about security. So do we. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
Re: Exceptions on MySQL 4.1
Nono, use the MySql41RDBMSAdapter. That's what worked for me. Oliver On Mon, 06 Dec 2004 16:37:36 -0800, Mirko Froehlich <[EMAIL PROTECTED]> wrote: > In that case, should I continue to use the MySqlRDBMSAdapter, or should I > use the MySql41RDBMSAdapter? > > -Mirko > > > > > On Mon, 2004-12-06 at 16:25, Oliver Zeigermann wrote: > May be true, I did my tests with the 4.0 schema and it worked just fine. No > idea what the original problem is. Anyway, use the 4.0 schema even for 4.1 > and it should work. Oliver > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Exceptions on MySQL 4.1
In that case, I don't think this will solve my issue. Slide actually started up fine with MySQL 4.1 for the first time, using the MySql41RDBMSAdapter and the new schema. I ran my concurrency test, which again failed after less than a minute. Only subsequent startups failed due to the schema issues, for some reason. -Mirko On Mon, 2004-12-06 at 16:47, Oliver Zeigermann wrote: > Nono, use the MySql41RDBMSAdapter. That's what worked for me. > > Oliver > > > On Mon, 06 Dec 2004 16:37:36 -0800, Mirko Froehlich > <[EMAIL PROTECTED]> wrote: > > In that case, should I continue to use the MySqlRDBMSAdapter, or should I > > use the MySql41RDBMSAdapter? > > > > -Mirko > > > > > > > > > > On Mon, 2004-12-06 at 16:25, Oliver Zeigermann wrote: > > May be true, I did my tests with the 4.0 schema and it worked just fine. No > > idea what the original problem is. Anyway, use the 4.0 schema even for 4.1 > > and it should work. Oliver > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] >