[jira] Reopened: (JCR-2655) initVersions crashes with NPE

2010-06-15 Thread Tobias Bocanegra (JIRA)

 [ 
https://issues.apache.org/jira/browse/JCR-2655?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tobias Bocanegra reopened JCR-2655:
---


the inconsistent versions that no longer exist in the repository should be 
skipped in initVersions().

 initVersions crashes with NPE
 -

 Key: JCR-2655
 URL: https://issues.apache.org/jira/browse/JCR-2655
 Project: Jackrabbit Content Repository
  Issue Type: Bug
  Components: versioning
Affects Versions: 1.6.2, 2.1.0
Reporter: Juergen Melzer
Priority: Blocker
 Fix For: 2.2.0


 After delete some old versions. I get serious problems accessing the version 
 history.
 This is the stacktrace:
 java.lang.NullPointerException
   at 
 org.apache.jackrabbit.core.version.VersionIteratorImpl.initVersions(VersionIteratorImpl.java:169)
   at 
 org.apache.jackrabbit.core.version.VersionIteratorImpl.init(VersionIteratorImpl.java:87)
   at 
 org.apache.jackrabbit.core.version.VersionIteratorImpl.init(VersionIteratorImpl.java:72)
   at 
 org.apache.jackrabbit.core.version.VersionHistoryImpl.getAllVersions(VersionHistoryImpl.java:92)
 I stepped threw the code and see that the Method 
 currentVersion.getSuccessors() 
 returns an empty Array.
 After all the VersionHistory seems to be corrupt!!

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Created: (JCR-2656) Embedded Derby fails under JBoss because of JMX-related conflicts

2010-06-15 Thread Paco Avila (JIRA)
Embedded Derby fails under JBoss because of JMX-related conflicts
-

 Key: JCR-2656
 URL: https://issues.apache.org/jira/browse/JCR-2656
 Project: Jackrabbit Content Repository
  Issue Type: Bug
  Components: jackrabbit-core
Affects Versions: 1.6.2
 Environment: Linux Ubuntu 10.04 LTS
Reporter: Paco Avila


JBoss fails to start due to a bug in Derby-10.4.2.0. The dependency should be 
agains derby-10.4.2.1 which seems to has this bug fixed. More info at 
https://issues.apache.org/jira/browse/DERBY-3887

Please, include this fix in the upcoming 1.6.3

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



Re: How to use Node and Property DefinitionTemplates to create a NodeTypeTemplate

2010-06-15 Thread Alexander Klimetschek
On Tue, Jun 15, 2010 at 06:47, Subash Chaturanga subash...@gmail.com wrote:
 In the JSR 283 spec , it says when creating  NodeDefinitionTemplate and
 PropertyDefinitionTemplate they can be attached to the NodeTypeTemplate.
 How we should attach those to NodeTypeTemplate? I mean is it the user's
 responsible to set the NodeTypeTemplate after acquiring Node and Property
 DefinitionTemplates ?

NodeTypeTemplate.getNodeDefinitionTemplates() and
getPropertyDefinitionTemplates() return *mutable* lists (see javadoc).
So you simply use list.add() to add the definitions created using
NodeTypeManager.createNodeDefinitionTemplate()  and
createPropertyDefinitionTemplate() (and modified according to your
needs).

Regards,
Alex

-- 
Alexander Klimetschek
alexander.klimetsc...@day.com


Build failed in Hudson: Jackrabbit-trunk #1171

2010-06-15 Thread Apache Hudson Server
See http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/1171/

--
[...truncated 1460 lines...]
[INFO] Retrieving previous metadata from apache.snapshots.https
[INFO] Uploading repository metadata for: 'snapshot 
org.apache.jackrabbit:jackrabbit-webapp:2.2-SNAPSHOT'
[INFO] Retrieving previous build number from apache.snapshots.https
Uploading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/jackrabbit/jackrabbit-webapp/2.2-SNAPSHOT/jackrabbit-webapp-2.2-20100611.152601-58.jar
33K uploaded
[TASKS] Skipping maven reporter: there is already a result available.
[HUDSON] Archiving 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-webapp/pom.xml
 to 
/export/home/hudson/hudson/jobs/Jackrabbit-trunk/modules/org.apache.jackrabbit$jackrabbit-webapp/builds/2010-06-11_15-25-16/archive/org.apache.jackrabbit/jackrabbit-webapp/2.2-SNAPSHOT/pom.xml
[HUDSON] Archiving 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-webapp/target/jackrabbit-webapp-2.2-SNAPSHOT.war
 to 
/export/home/hudson/hudson/jobs/Jackrabbit-trunk/modules/org.apache.jackrabbit$jackrabbit-webapp/builds/2010-06-11_15-25-16/archive/org.apache.jackrabbit/jackrabbit-webapp/2.2-20100611.152601-58/jackrabbit-webapp-2.2-SNAPSHOT.war
[HUDSON] Archiving 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-webapp/target/jackrabbit-webapp-2.2-SNAPSHOT.jar
 to 
/export/home/hudson/hudson/jobs/Jackrabbit-trunk/modules/org.apache.jackrabbit$jackrabbit-webapp/builds/2010-06-11_15-25-16/archive/org.apache.jackrabbit/jackrabbit-webapp/2.2-20100611.152601-58/jackrabbit-webapp-2.2-SNAPSHOT.jar
[INFO] 
[INFO] Building Jackrabbit JCA Resource Adapter
[INFO]task-segment: [clean, deploy]
[INFO] 
[INFO] [clean:clean]
[INFO] Deleting file set: 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/target
 (included: [**], excluded: [])
[TASKS] Scanning folder 
'http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/src/main/java'
 for tasks ... 
[TASKS] Found 0.
[TASKS] Scanning folder 
'http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/src/test/java'
 for tasks ... 
[TASKS] Found 0.
[TASKS] Scanning folder 
'http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/src/main/resources'
 for tasks ... 
[TASKS] Found 0.
[TASKS] Scanning folder 
'http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/src/test/resources'
 for tasks ... 
[TASKS] Found 0.
[INFO] [remote-resources:process {execution: default}]
[TASKS] Skipping maven reporter: there is already a result available.
[INFO] [resources:resources]
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO] Copying 3 resources
[TASKS] Skipping maven reporter: there is already a result available.[INFO] 
[compiler:compile]
[INFO] Compiling 10 source files to 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/target/classes

[TASKS] Skipping maven reporter: there is already a result available.[INFO] 
[resources:testResources]
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO] Copying 3 resources

[INFO] [compiler:testCompile][TASKS] Skipping maven reporter: there is already 
a result available.
[INFO] Compiling 3 source files to 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/target/test-classes

[TASKS] Skipping maven reporter: there is already a result available.[INFO] 
[surefire:test]
[INFO] Surefire report directory: 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/target/surefire-reports

---
 T E S T S
---
Running org.apache.jackrabbit.jca.test.ConnectionFactoryTest

Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 4.979 sec
Running org.apache.jackrabbit.jca.test.ConnectionRequestInfoTest
Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.006 sec

Results :

Tests run: 8, Failures: 0, Errors: 0, Skipped: 0

[TASKS] Skipping maven reporter: there is already a result available.
[HUDSON] Recording test results
[INFO] [jar:jar {execution: package-jca-jar}]
[INFO] Building jar: 
http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/ws/trunk/jackrabbit-jca/target/jackrabbit-jca-2.2-SNAPSHOT.jar
[TASKS] Skipping maven reporter: there is already a result available.
[INFO] [rar:rar]
[INFO] Including generated jar file[jackrabbit-jca-2.2-SNAPSHOT.jar]
[INFO] Copying artifact[org.apache.jackrabbit, 
org.apache.jackrabbit:jackrabbit-core:jar:2.2-SNAPSHOT, compile]
[INFO] Copying 

Re: How to use Node and Property DefinitionTemplates to create a NodeTypeTemplate

2010-06-15 Thread Subash Chaturanga
Thanks for your reply Alex ,

Yes ,but my prob is where should I keep the list.Lists asks from
NodeTypeTemplate .
NodeTypeManager can create any number of NodeTypeTemplates(with or with out
a definition) .
If i maintain a List in   NodeTypeManager then how can i return Definition
List asked from NodeTypeTemplate.getNodeDefinitionTemplates() which should
be specific to that particular NodeTypeTemplate ?

Thank you
Subash


Hudson build is back to normal : Jackrabbit-trunk #1172

2010-06-15 Thread Apache Hudson Server
See http://hudson.zones.apache.org/hudson/job/Jackrabbit-trunk/1172/




[jira] Created: (JCR-2657) DefaultAccessManager#hasPrivileges(String,Set,Privilege[]) doesn't close compiled permissions

2010-06-15 Thread angela (JIRA)
DefaultAccessManager#hasPrivileges(String,Set,Privilege[]) doesn't close 
compiled permissions
-

 Key: JCR-2657
 URL: https://issues.apache.org/jira/browse/JCR-2657
 Project: Jackrabbit Content Repository
  Issue Type: Bug
  Components: jackrabbit-core
Affects Versions: 2.1.0, 2.0.0
Reporter: angela
Assignee: angela
Priority: Trivial
 Fix For: 2.2.0


DefaultAccessManager#hasPrivileges(String,Set,Privilege[]) retrieves the 
compiled permissions for the specified set of principals
from the ac provider but omit the CompiledPermissions#close() call before 
returning.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (JCR-2657) DefaultAccessManager#hasPrivileges(String,Set,Privilege[]) doesn't close compiled permissions

2010-06-15 Thread angela (JIRA)

 [ 
https://issues.apache.org/jira/browse/JCR-2657?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

angela resolved JCR-2657.
-

Resolution: Fixed

 DefaultAccessManager#hasPrivileges(String,Set,Privilege[]) doesn't close 
 compiled permissions
 -

 Key: JCR-2657
 URL: https://issues.apache.org/jira/browse/JCR-2657
 Project: Jackrabbit Content Repository
  Issue Type: Bug
  Components: jackrabbit-core
Affects Versions: 2.0.0, 2.1.0
Reporter: angela
Assignee: angela
Priority: Trivial
 Fix For: 2.2.0


 DefaultAccessManager#hasPrivileges(String,Set,Privilege[]) retrieves the 
 compiled permissions for the specified set of principals
 from the ac provider but omit the CompiledPermissions#close() call before 
 returning.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (JCR-2649) Provide means to display the effective policies for a given set of principals

2010-06-15 Thread angela (JIRA)

 [ 
https://issues.apache.org/jira/browse/JCR-2649?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

angela resolved JCR-2649.
-

Fix Version/s: 2.2.0
   Resolution: Fixed

 Provide means to display the effective policies for a given set of principals
 -

 Key: JCR-2649
 URL: https://issues.apache.org/jira/browse/JCR-2649
 Project: Jackrabbit Content Repository
  Issue Type: New Feature
  Components: jackrabbit-api, jackrabbit-core
Affects Versions: 2.0.0, 2.1.0
Reporter: angela
Assignee: angela
Priority: Minor
 Fix For: 2.2.0


 JSR 283 currently defines AccessControlManager#getEffectivePolicies(String 
 nodePath) that would allow any Permission related UI to
 display what policies contribute to a particular set of privileges. In 
 addition the API defines AccessControlManager#getPrivileges(String nodePath) 
 which
 returns the privileges the editing session has at the specified path.
 In order to have additional flexibility we started to add custom extensions 
 (- JackrabbitAccessControlManager) that allows e.g. to retrieve the 
 privileges any set
 of principals has hat a specified path. I would like to extend this and in 
 addition provide a method that allows to retrieve the effective policies for 
 a set of principals.
 Currently this can only be achieved by relying on a specific access control 
 model and making assumptions about it's implementation, which obviously isn't
 the desired effect.
 I

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (JCR-2646) AccessControlManager#getEffectivePolicies(String) may expose AC content without proper permissions

2010-06-15 Thread angela (JIRA)

 [ 
https://issues.apache.org/jira/browse/JCR-2646?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

angela resolved JCR-2646.
-

Resolution: Fixed

 AccessControlManager#getEffectivePolicies(String) may expose AC content 
 without proper permissions
 --

 Key: JCR-2646
 URL: https://issues.apache.org/jira/browse/JCR-2646
 Project: Jackrabbit Content Repository
  Issue Type: Bug
  Components: jackrabbit-core
Affects Versions: 2.0.0, 2.1.0
Reporter: angela
Assignee: angela
Priority: Minor
 Fix For: 2.2.0


 The implementation of AccessControlManager#getEffectivePolicies(String) in 
 the DefaultAccessManager only checks if the session is allowed
 to read AC content at the specified path. However the result may also include 
 policies effective at absPath that should not be visible to the editing
 session (read_AC permissions denied e.g. at an ancestor node) and could not 
 be read by the editing session be means of #getPolicies().

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



Re: How to use Node and Property DefinitionTemplates to create a NodeTypeTemplate

2010-06-15 Thread Alexander Klimetschek
On Tue, Jun 15, 2010 at 13:27, Subash Chaturanga subash...@gmail.com wrote:
 Yes ,but my prob is where should I keep the list.Lists asks from 
 NodeTypeTemplate .
 NodeTypeManager can create any number of NodeTypeTemplates(with or with out a 
 definition) .
 If i maintain a List in   NodeTypeManager then how can i return Definition 
 List asked from NodeTypeTemplate.getNodeDefinitionTemplates() which should be 
 specific to that particular NodeTypeTemplate ?

Sorry, I don't understand. If you want to define a new custom node
type, this is what you do (beware, untested code):

snip

NodeTypeTemplate nt = nodeTypeManager.createNodeTypeTemplate();
nt.setName(my:nodeType);
nt.set

PropertyDefinitionTemplate prop1 = nodeTypeManager.
createPropertyDefinitionTemplate();
prop1.setName(prop);
prop1.setRequiredType(PropertyType.STRING);
prop1.set...

nt. getPropertyDefinitionTemplates().add(prop1);

nodeTypeManager.registerNodeType(nt, false);

/snap

Regards,
Alex

--
Alexander Klimetschek
alexander.klimetsc...@day.com


Re: How to use Node and Property DefinitionTemplates to create a NodeTypeTemplate

2010-06-15 Thread Subash Chaturanga
Hi ,Thanks Alex
Though i might not able to communicate my problem to you , I was able to
get  exactly what i wanted by the piece of code you gave me .It
worked.Thanks a lot

Regards
/Subash