Concurrent Updates

2011-07-13 Thread Ben Short
Hi, How would the following scenario be best handled with JackRabbit? I have a product node that has a stock level property. As part of a checkout process I want to decrement the stock level property based on the number of products the user has in their basket. If I where using JDBC I would

Re: Users and Groups

2010-04-15 Thread Ben Short
Thanks Angela for getting back to me about this. On 14 April 2010 10:05, Angela Schreiber anch...@day.com wrote: hi ben Ben Short wrote: Session mccSession = repository.login(mccUser.getCredentials()); that's the problem. UserImpl.getCredentials() doesn't return

Users and Groups

2010-03-31 Thread Ben Short
it work. Has anyone got any ideas? Regards Ben Short

Re: hello

2010-02-26 Thread Ben Short
http://repo2.maven.org/maven2/javax/jcr/jcr/2.0/ On 26 February 2010 04:44, Richa richasharma...@gmail.com wrote: thanx rakesh for the imformation..but iam really not able to find jcr-2.0.jar anywhere on internet,can u suggest some link from where i can download this jar file.. Thanks in

Jackrabbit and ha-jdbc

2010-02-19 Thread Ben Short
Hi, Has anyone ever tried using jackrabbit with ha-jdbc? Ben [1] http://ha-jdbc.sourceforge.net/

Re: repo browser

2010-02-08 Thread Ben Short
There are some listed here [1] and here [2] [1] http://wiki.apache.org/jackrabbit/JcrLinks#Open_Source_Tools_and_Libraries [1] http://dev.day.com/microsling/content/blogs/main/jcrtools.html On 8 February 2010 17:54, ChadDavis chadmichaelda...@gmail.com wrote: Is there a repo browser that can

Re: Jackrabbit Observation with Spring

2010-02-04 Thread Ben Short
Hi, Looking at the documentation [1] you have to add the Event Listener to the JcrSessionFactory bean. bean id=sessionFactory class=org.springmodules.jcr.JcrSessionFactory ... property name=eventListeners list bean class=org.springmodules.jcr.EventListenerDefinition property

Re: Jackrabbit Observation with Spring

2010-02-04 Thread Ben Short
Sorry that should of been 'can add the event listener' You could pass the JcrSessionFactory into your ListenerRegistrar and in the init method get a session and add the listeners via it. Make sure you implement a destroy method that logs out the session. On 4 February 2010 15:05, Ben Short b

Re: Jackrabbit Observation with Spring

2010-02-04 Thread Ben Short
Maybe have a look at the jcrsessionfactory source code and see how it registers the listeners. On 2/4/10, aelsher...@idc.com aelsher...@idc.com wrote: Ben, that's really wonderful I got it working finally as I added the stuff you sent to the applicationContext.xml and removed the

Re: Jackrabbit Observation with Spring

2010-02-04 Thread Ben Short
Here is the code. /** * @see org.springmodules.jcr.SessionFactory#getSession() */ public Session getSession() throws RepositoryException { return addListeners(repository.login(credentials, workspaceName)); } /** * Hook for adding listeners to the newly returned session. We have to treat

Re: ACL and jackrabbit security configuration

2010-02-03 Thread Ben Short
You need to configure Jackrabbit to use the DefaultAccessManager, DefaultLoginModule and DefaultSecurityManager 2010/2/3 Jan Michalica jan.michal...@centire.com Hello, I am trying to use the new ACL (AccessControlList) API in Jackrabbit 2.0 to manage permissions for documents stored in

Re: ACL and jackrabbit security configuration

2010-02-03 Thread Ben Short
Michalica jan.michal...@centire.com wrote: Hi, I have tried to do so, but now no one (except admin and anonymous) is able to log in to repository. How do I configure DefaultLoginModule so that anyone can log in? Dne středa 03 února 2010 16:07:28 Ben Short napsal(a): You need to configure

Re: MIME Type Problem

2010-01-25 Thread Ben Short
How did you add the wav file to jackrabbit? 2010/1/25 Odie1001 gavin.w...@htk.co.uk Hi , Sorry for being a complete newbie, but the only place I could find a reference to jcr:content/jcr:mimeType was in populate.jsp? I added .wav as mime type and change the else statment to use audio-xwav

Re: MIME Type Problem

2010-01-25 Thread Ben Short
OK, I'm not an expert but I would take a guess that the jackrabbit webdav code is not setting the mime type correctly on the file node that it will create when you upload the file. Its going tobe doing something like the code you can see here [1]. [1]

Re: MIME Type Problem

2010-01-25 Thread Ben Short
as expected. [1] http://www.jcr-explorer.org/ http://www.jcr-explorer.org/[2] http://sourceforge.net/projects/jcrbrowser/ 2010/1/25 Ben Short b...@benshort.co.uk OK, I'm not an expert but I would take a guess that the jackrabbit webdav code is not setting the mime type correctly on the file node

Re: Finding the existing nodes

2010-01-05 Thread Ben Short
session.getRootNode().hasNode(node_name); You'll probably want to look at the javadocs [1] for the JCR api [1] http://www.day.com/maven/jsr170/javadocs/jcr-1.0/ 2010/1/5 test123456 sajith...@thinkcoretech.com: After getting the root node from the session object. I want to know a particular

Re: Derby

2009-12-17 Thread Ben Short
Simer, Configure the repository to use the previously stated classes and then just call the method. Ben 2009/12/17 anand simer.anan...@gmail.com: Hello Ben, Ben Short wrote: Jackrabbit 2 has all this done for you already. configure your repository to use the following classes

Re: list of jars needed for jackrabbit 2.0

2009-12-17 Thread Ben Short
Hi, Using the maven dependancy tool I see that Jackrabbit requires the following.. [INFO] +- org.apache.jackrabbit:jackrabbit-core:jar:2.0-beta4:compile [INFO] | +- concurrent:concurrent:jar:1.3.4:compile [INFO] | +- commons-collections:commons-collections:jar:3.2.1:compile [INFO] | +-

Re: list of jars needed for jackrabbit 2.0

2009-12-17 Thread Ben Short
Is it a blank install of tomcat or have you been adding jars to the libs dir? 2009/12/17 simer anand simer.anan...@gmail.com: after starting the jackrabbit through tomcat when i move to //localhost:8080/jackrabbit-webapp-2.0-beta3/ then comes Some error occurred during setup. See the log files

Re: list of jars needed for jackrabbit 2.0

2009-12-17 Thread Ben Short
As Jukka says the war file has everything you need. 1. Remove everything you have added to tomcat/lib 2. Put the jcr-2.0.jar in tomcat/libs And all should work. Ben 2009/12/17 Jukka Zitting jukka.zitt...@gmail.com: Hi, On Thu, Dec 17, 2009 at 11:32 AM, simer anand simer.anan...@gmail.com

Re: Jackrabbit 2 Binary

2009-12-17 Thread Ben Short
Thanks for this info guys. 2009/12/16 Stefan Guggisberg stefan.guggisb...@gmail.com: On Wed, Dec 16, 2009 at 11:36 AM, Guo Du mrdu...@gmail.com wrote: On Wed, Dec 16, 2009 at 9:11 AM, Ben Short b...@benshort.co.uk wrote: Its a very handy undocumented feature. Since its undocumented

Re: list of jars needed for jackrabbit 2.0

2009-12-17 Thread Ben Short
17, 2009 at 4:20 PM, Ben Short b...@benshort.co.uk wrote: As Jukka says the war file has everything you need. 1. Remove everything you have added to tomcat/lib 2. Put the jcr-2.0.jar in tomcat/libs And all should work. Ben 2009/12/17 Jukka Zitting jukka.zitt...@gmail.com: Hi

Re: session.save() taking too much of time when called by more than one thread.

2009-12-17 Thread Ben Short
Are you using the same session across multiple threads? 2009/12/17 sunild sunil.dh...@coreobjects.com: Hi, In my application, there are multiple threads going to access repository simultaneosly. I have tried using node.lock() and unlock() but faced few problems. --session have pending

Re: Jackrabbit 2 Binary

2009-12-16 Thread Ben Short
Its a very handy undocumented feature. Since its undocumented is it safe to assume that it might change without notice? 2009/12/16 Thomas Müller thomas.muel...@day.com: Hi, Yes, unless you want to rely on an undocumented feature. Regard, Thomas

Jackrabbit 2 Binary

2009-12-15 Thread Ben Short
Hi, Do I need to keep the session open when reading data from a binary property? Regards Ben Short

Versioning

2009-12-14 Thread Ben Short
? Ben Short

Re: Versioning

2009-12-14 Thread Ben Short
(); System.out.println(node.getProperty(name).getString() + + node.getProperty(published).getString()); } } Why do I need to skip passed the first version? 2009/12/14 Ben Short b...@benshort.co.uk: Hi, I'm using Jackrabbit 2. Is the following scenario

Re: FreeBSD indexing and lock file issues

2009-12-11 Thread Ben Short
) ((JackrabbitRepository) repository).shutdown(); } The destroy will be called by spring when you undeploy or shutdown your webapp and there for the repository should be shut down. Ben 2009/12/11 Sergey Podatelev brightnesslev...@gmail.com: On Fri, Dec 11, 2009 at 1:11 PM, Ben Short b

Re: Critique and Comments

2009-12-11 Thread Ben Short
= washingUpLiquid.getNodes(); while (sizeIterator.hasNext()) {    System.out.println(washingUpLiquid.getName() + : Option - + sizeIterator.nextNode().getName()); } or something like that... Nothing wrong with your way, but just another take on it. Simon. Ben Short wrote: Could anyone provide

Re: Derby

2009-12-10 Thread Ben Short
Jackrabbit 2 has all this done for you already. configure your repository to use the following classes org.apache.jackrabbit.core.security.DefaultAccessManager org.apache.jackrabbit.core.security.authentication.DefaultLoginModule org.apache.jackrabbit.core.DefaultSecurityManager Then

Critique and Comments

2009-12-09 Thread Ben Short
Could anyone provide any comments or see any problems that might occur with the following repository structure? Node option = session.getRootNode().addNode(/product/options/size); option.addMixin(mix:referenceable); option.setProperty(name, size);

Re: Using the AccessControlManager to set a policy

2009-12-04 Thread Ben Short
Ben 2009/11/27 Ben Short b...@benshort.co.uk Hi, I'm trying to use the AccessControlManager to allow a user to have write permissions to a node. But I can't see how to create a policy. Can anyone give me any pointers? Regards Ben Short

Re: Using the AccessControlManager to set a policy

2009-12-04 Thread Ben Short
to AbstractACLTemplate inorder, which is JackRabbit specific to add a new entry. I wonder what the JCR 2 api dose not define an interface? Regards Ben Short 2009/12/4 Angela Schreiber anch...@day.com please take a look at the API. AccessControlManager#getApplicablePolicies - for policies that can

Re: Using the AccessControlManager to set a policy

2009-12-04 Thread Ben Short
); adminAcm.setPolicy(testRootNode.getPath(), acp); } superuser.save(); Regards Ben Short 2009/12/4 Angela Schreiber anch...@day.com please take a look at the API and the specification. - JCR 2.0 provides AccessControlList - Jackrabbit API 2.0 in addition provides

Using the AccessControlManager to set a policy

2009-11-27 Thread Ben Short
Hi, I'm trying to use the AccessControlManager to allow a user to have write permissions to a node. But I can't see how to create a policy. Can anyone give me any pointers? Regards Ben Short

JackRabbit + JSP/JSTL

2009-11-23 Thread Ben Short
=%=fieldName% size=30 maxlength=%=fieldNode.getProperty(maxLength).getLong()% value=%=request.getParameter(fieldName)%/ /label % Regards Ben Short

Re: JackRabbit + JSP/JSTL

2009-11-23 Thread Ben Short
thanks for the replies. some kind of taglib would be use full. Ben 2009/11/23 Rakesh Vidyadharan rak...@sptci.com On 23 Nov 2009, at 05:23, Torgeir Veimo wrote: 2009/11/23 Ben Short b...@benshort.co.uk: Is there any way to access the jcr api in a jsp file in a cleaner way or via jstl

Calling session.save()

2009-11-21 Thread Ben Short
Hi, Is it costly to call session.save() if the session has only been used for reading? Regards Ben Short

Re: OCM

2009-10-27 Thread Ben Short
reference by path . Christophe 2009/10/23 Ben Short b...@benshort.co.uk: Hi, JCROM supports weak references as show in the following classes public class Person {       �...@jcrpath        private String path;       �...@jcrname        private String name;       �...@jcrreference

OCM

2009-10-23 Thread Ben Short
{ @JcrPath private String path; @JcrName private String name; } This will result in a property on person node which contains a list of paths to the pet nodes. Does jackrabbit-ocm support this? Regards Ben Short

OCM

2009-10-23 Thread Ben Short
} Person p = new Person(); p.setPath(/contacts/work/person1); ocm.insert(p); ocm.save(); Regards Ben Short

jcr:data inputstream.close()

2009-10-10 Thread Ben Short
Hi, Should I close the inputstream obtained to read the data from a jcr:data property? Regards Ben

Jackrabbit 2 in maven repo

2009-10-09 Thread Ben Short
it myself would defiantly help me to try it out. What do you think? Regards Ben Short [1] http://repo2.maven.org/maven2/org/codehaus/groovy/groovy-all/

Re: Jackrabbit 2 in maven repo

2009-10-09 Thread Ben Short
Sounds great. Thanks 2009/10/9 Alexander Klimetschek aklim...@day.com: On Fri, Oct 9, 2009 at 16:05, Ben Short b...@benshort.co.uk wrote: Have you considered deloying jackrabbit 2 to the main maven repository? Will be done for the next alpha release: http://markmail.org/message

Repository Content Diagram

2009-10-05 Thread Ben Short
Hi, Is the a standard or preferred way to define the layout of content in jackrabbit while designing an application? I'm not talking about defining custom node types. I mean the equivalent to a relational database diagram or an xml schema. Regards Ben Short

XPath help

2009-10-05 Thread Ben Short
Hi, I have 2 nodes: /catalog/products/wooly_hat /catalog/products/top_hat both nodes have a title property. I can't figure out how to write a XPATH query that will return nodes that have a supplied value as there title. An SQL equivalent would be something like select * from products where

Re: XPath help

2009-10-05 Thread Ben Short
Thanks. I have clicked now :) 2009/10/5 Alexander Klimetschek aklim...@day.com On Mon, Oct 5, 2009 at 14:34, Ben Short b...@benshort.co.uk wrote: I have 2 nodes: /catalog/products/wooly_hat /catalog/products/top_hat both nodes have a title property. I can't figure out how

Re: quick survey on schema less database usage

2009-09-11 Thread Ben Short
How come you are sending this to the JackRabbit userlist but don't have JackRabbit in the list for questions 5 and 6? 2009/9/11 rr04 reach_reddy...@yahoo.com I am a MIT student doing a project on schema-less database usage and would greatly appreciate if you guys can fill out a quick survey

Documentation Error

2009-09-09 Thread Ben Short
/dependency !-- You can select the logging tool you want, let's use Log4J here -- dependency groupIdorg.slf4j/groupId artifactIdslf4j-log4j12/artifactId version1.5.3/version /dependency Regards Ben Short

OCM support for JackRabbit 1.6

2009-09-09 Thread Ben Short
Hi, Has the OCM support been dropped from JackRabbit version 1.6? I can see it in the 1.5 svn branch but not the 1.6 svn branch. Regards Ben Short

Re: Using the Web Application Demo

2008-01-09 Thread ben short
Although having said that, in tomcats std out log there is information about the rmi and jndi configuration. Here is what i see for the rmi config.. rmiName: jackrabbit.repository rmiUri //localhost:1099/jackrabbit.repository rmiPort 1099 rmiHost localhost On Jan 9, 2008 8:42 AM, ben short

Re: Using the Web Application Demo

2008-01-09 Thread ben short
Hi, Im not an expert, but it seems that the webapp provides a JCR server via the WebDAV protocol, so you will need a WebDAV client to access it. I can't see that It provides anyother access method. Ben On Jan 9, 2008 7:12 AM, [EMAIL PROTECTED] wrote: Hello folks, I'm really in a bad

Re: Using the Web Application Demo

2008-01-09 Thread ben short
Have a peek at the wiki page [1] theres lots of resources, something on there might be of help. [1] http://wiki.apache.org/jackrabbit/JcrLinks On Jan 9, 2008 9:19 AM, [EMAIL PROTECTED] wrote: This is already a huge step forward! I'm able to use JCR controller to visualize the repository. It

Re: Shared session pool

2008-01-09 Thread ben short
You might want to look at the apache commons pool [1] instead of rolling your own. [1] http://commons.apache.org/pool/ On Jan 9, 2008 9:59 AM, Andrea K. [EMAIL PROTECTED] wrote: Hi Alex, I attached the code. As you can see is not complex. Logout are never done for readonly sessions, but