Problem executing JCR within Alfresco.war

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2006 05:12 AM
Hy I am newly trying to learn on how to use Alfresco Repository via a JCR client,
So I created a servlet based on the SimpleExample.javaof the Alfresco SDK 1.4 JCRSamples project, and I integrated it into the Alfresco application of the Tomcat server, in the webapps/alfresco… (I am using Alfresco Community 1.4 on Windows).
When I am trying to access to my servlet (in order to execute a simple browse of the content of the repository for a user), I obtain this errors:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ftsIndexerTrigger' defined in class path resource [alfresco/scheduled-jobs-context.xml]: Initialization of bean failed; nested exception is org.quartz.ObjectAlreadyExistsException: Unable to store Job with name: 'ftsIndexerJobDetail' and group: 'DEFAULT', because one already exists with this identification.
caused by:
org.quartz.ObjectAlreadyExistsException: Unable to store Job with name: 'ftsIndexerJobDetail' and group: 'DEFAULT', because one already exists with this identification.
## Can I just run an example of the JCR client in the alfresco.war, or I am maybe obliged todo it another from another application!!!!
Can someone explain to me How make use of the build simpleExample of the Alfresco SDK 1.4 JCRSample Project step by step???
Thank you in advance!
ops:
So I created a servlet based on the SimpleExample.javaof the Alfresco SDK 1.4 JCRSamples project, and I integrated it into the Alfresco application of the Tomcat server, in the webapps/alfresco… (I am using Alfresco Community 1.4 on Windows).
When I am trying to access to my servlet (in order to execute a simple browse of the content of the repository for a user), I obtain this errors:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ftsIndexerTrigger' defined in class path resource [alfresco/scheduled-jobs-context.xml]: Initialization of bean failed; nested exception is org.quartz.ObjectAlreadyExistsException: Unable to store Job with name: 'ftsIndexerJobDetail' and group: 'DEFAULT', because one already exists with this identification.
caused by:
org.quartz.ObjectAlreadyExistsException: Unable to store Job with name: 'ftsIndexerJobDetail' and group: 'DEFAULT', because one already exists with this identification.
## Can I just run an example of the JCR client in the alfresco.war, or I am maybe obliged todo it another from another application!!!!
Can someone explain to me How make use of the build simpleExample of the Alfresco SDK 1.4 JCRSample Project step by step???
Thank you in advance!

Labels:
- Labels:
-
Archive
7 REPLIES 7
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2006 05:46 AM

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2006 09:40 AM
Sorry but The example of Alfresco SDK JCRSamples or even the otherone FirstJCRClient isn't clear enough. It is clear that I must copy the configuration files : custom-repository.properties and custom-repository-context.xml to the directory classpath:/alfresco/extension, but how do i execute the class file FirstJCRClient.class???
How do I integrate it to the web application alfresco!!!!! or to another web application????
ops:
How do I integrate it to the web application alfresco!!!!! or to another web application????

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2006 10:09 AM
sdk use an embedded alfresco … that mean you dont need to use any war.
To run example just execute "main" classes in your eclipse. If you have well import sdk in your eclipse that would work fine.
To run example just execute "main" classes in your eclipse. If you have well import sdk in your eclipse that would work fine.

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2006 07:31 AM
I thank you for your advises mister ribz33, but when I execute the any SDK examples, I obtain the error below:
Exception in thread "main" javax.jcr.LoginException: Alfresco Repository failed to authenticate credentials: Bad credentials presented: Bad credentials presented
at org.alfresco.jcr.repository.RepositoryImpl.login(RepositoryImpl.java:213)
at org.alfresco.jcr.repository.RepositoryImpl.login(RepositoryImpl.java:238)
at org.alfresco.sample.jcr.SimpleExample.main(SimpleExample.java:63)
Caused by: org.alfresco.repo.security.authentication.AuthenticationException: Bad credentials presented
at org.alfresco.repo.security.authentication.AuthenticationComponentImpl.authenticate(AuthenticationComponentImpl.java:69)
at org.alfresco.repo.security.authentication.AuthenticationServiceImpl.authenticate(AuthenticationServiceImpl.java:104)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
Why do I get this error???
I did see in this forum that a lot of other persons had the same issues.
Is it a problem due to Serialization????
:wink: anyway thanks again
Exception in thread "main" javax.jcr.LoginException: Alfresco Repository failed to authenticate credentials: Bad credentials presented: Bad credentials presented
at org.alfresco.jcr.repository.RepositoryImpl.login(RepositoryImpl.java:213)
at org.alfresco.jcr.repository.RepositoryImpl.login(RepositoryImpl.java:238)
at org.alfresco.sample.jcr.SimpleExample.main(SimpleExample.java:63)
Caused by: org.alfresco.repo.security.authentication.AuthenticationException: Bad credentials presented
at org.alfresco.repo.security.authentication.AuthenticationComponentImpl.authenticate(AuthenticationComponentImpl.java:69)
at org.alfresco.repo.security.authentication.AuthenticationServiceImpl.authenticate(AuthenticationServiceImpl.java:104)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
Why do I get this error???
I did see in this forum that a lot of other persons had the same issues.
Is it a problem due to Serialization????
:wink: anyway thanks again
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2006 08:20 AM
bad credentials means that alfresco don't succeed to authenticate you. So :
- Look if login/pwd is correct (default: admin/admin)
Or more probably :
- Look if you had give good path for alf_data and well define database access in custom-repository.properties of all examples.
(you need to uncomment db.driver and db.url for your database)
Pierre H.
- Look if login/pwd is correct (default: admin/admin)
Or more probably :
- Look if you had give good path for alf_data and well define database access in custom-repository.properties of all examples.
(you need to uncomment db.driver and db.url for your database)
Pierre H.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-08-2007 06:49 PM
Can you please tell me how did u manage to execute code for acessing repository within alfresco.war?
Thanks
Bindiya
Thanks
Bindiya

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-10-2007 01:31 AM
Can you please tell me how did u manage to execute code for acessing repository within alfresco.war?
Thanks
Bindiya
What have you tried so far?
