jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dominique Pfister" <dominique.pfis...@day.com>
Subject Re: JackrabbitOnJBoss - Problems accessing JCA
Date Thu, 06 Sep 2007 13:46:23 GMT
Hi Stefan,

Do you want to access the datasource remotely, from a distinct Java
VM? There is a section on JBoss wiki called "Configuring a DataSource
for remote usage" on the following page:

http://wiki.jboss.org/wiki/Wiki.jsp?page=ConfigDataSources

It is not recommended, mainly, because the repository/sessions
produced by Jackrabbit's JCA are not serializable and you will
therefore not get useful objects on the client side.

However, registering a Jackrabbit repository in the RMI registry is
something expected to work: the non-JRMP server you see is JBoss's JNP
naming server, so you might use a different port to register your
Jackrabbit repository in RMI.

Kind regards
Dominique


On 05/09/07, stefan81 <stefan.schlappa@process-relations.com> wrote:
>
> Hi,
>
> I want to deploy JackRabbit on JBoss and followed the instructions under
> http://wiki.apache.org/jackrabbit/JackrabbitOnJBoss.
>
> The startup of my JBoss 4.0.5 server together with the deployment of the
> repository seems to be working fine:
>
> 17:43:59,444 INFO  [RepositoryImpl] Starting repository...
> 17:43:59,476 INFO  [LocalFileSystem] LocalFileSystem initialized at path
> \temp\jackrabbit\repository
> 17:43:59,585 INFO  [NodeTypeRegistry] no custom node type definitions found
> 17:43:59,585 INFO  [LocalFileSystem] LocalFileSystem initialized at path
> \temp\jackrabbit\version
> 17:44:01,288 INFO  [LocalFileSystem] LocalFileSystem initialized at path
> \temp\jackrabbit\version\blobs
> 17:44:01,413 INFO  [RepositoryImpl] initializing workspace 'default'...
> 17:44:01,413 INFO  [LocalFileSystem] LocalFileSystem initialized at path
> \temp\jackrabbit\workspaces\default
> 17:44:01,663 INFO  [LocalFileSystem] LocalFileSystem initialized at path
> \temp\jackrabbit\workspaces\default\blobs
> 17:44:01,741 INFO  [RepositoryImpl] workspace 'default' initialized
> 17:44:02,179 INFO  [SearchIndex] Index initialized:
> /temp/jackrabbit/repository/index
> 17:44:02,179 INFO  [SearchIndex] Index initialized:
> \temp\jackrabbit\workspaces\default/index
> 17:44:02,179 INFO  [RepositoryImpl] Repository started
>
>
> I wrote a client program for testing the access to the repository. According
> to JackrabbitOnJBoss I tried a jndi lookup which led to the following
> exception:
>
> Code:
> InitialContext ctx = new InitialContext() ;
> Repository repository = (Repository) ctx.lookup("java:jcr/local") ;
>
> Exception:
> Exception in thread "main" javax.naming.NoInitialContextException: Need to
> specify class name in environment or system property, or as an applet
> parameter, or in an application resource file:  java.naming.factory.initial
>
> After some googling I tried out a lot of other things, for example acessing
> via rmi:
>
> Code:
> ClientRepositoryFactory factory = new ClientRepositoryFactory();
> Repository repository =
> factory.getRepository("rmi://localhost:1099/jcrServer");
> Credentials cred = new SimpleCredentials("user",new char[]{'p','w','d'}) ;
> Session s = repository.login(cred);
>
> Exception:
> Exception in thread "main"
> org.apache.jackrabbit.rmi.client.RemoteRepositoryException: non-JRMP server
> at remote endpoint: non-JRMP server at remote endpoint
>
>
> Can anyone please give me a clue what is going wrong? Why does neither JNDI
> lookup nor RMI access work? Did I do something wrong with the deployment of
> JR?
>
> Thx a lot!
> --
> View this message in context: http://www.nabble.com/JackrabbitOnJBoss---Problems-accessing-JCA-tf4386029.html#a12503786
> Sent from the Jackrabbit - Users mailing list archive at Nabble.com.
>
>

Mime
View raw message