[Jenkins] Sling » Modules » sling-org-apache-sling-launchpad-testing » master #409 is BROKEN

2021-04-01 Thread Apache Jenkins Server
Please see 
https://ci-builds.apache.org/job/Sling/job/modules/job/sling-org-apache-sling-launchpad-testing/job/master/409/
 for details.

No further emails will be sent until the status of the build is changed.
Build log follows below:

[...truncated 966 lines...]
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.JavascriptWrappersTest
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.178 s 
- in org.apache.sling.launchpad.webapp.integrationtest.JavascriptWrappersTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.teleporter.EmbeddedDependenciesTeleporterTest
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.395 s 
- in 
org.apache.sling.launchpad.webapp.integrationtest.teleporter.EmbeddedDependenciesTeleporterTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.NodeTypeBasedRenderingTest
[INFO] Tests run: 7, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.063 s 
- in 
org.apache.sling.launchpad.webapp.integrationtest.NodeTypeBasedRenderingTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.WebDavDoubleSlashTest
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.173 s 
- in org.apache.sling.launchpad.webapp.integrationtest.WebDavDoubleSlashTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.resourceresolver.ResourceResolverGeneralTest
ERROR: Bundle org.apache.sling.scripting.jsp [194] EventDispatcher: Error 
during dispatch. (java.lang.NullPointerException)
ERROR: Bundle org.apache.felix.healthcheck.generalchecks [57] EventDispatcher: 
Error during dispatch. (java.lang.IllegalStateException: The bundle is 
uninstalled.)
ERROR: Bundle org.apache.sling.scripting.core [189] EventDispatcher: Error 
during dispatch. (java.lang.IllegalStateException: The bundle is uninstalled.)
[INFO] Tests run: 62, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 43.231 
s - in 
org.apache.sling.launchpad.webapp.integrationtest.resourceresolver.ResourceResolverGeneralTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.scripting.StandaloneScriptExecutionTest
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.07 s - 
in 
org.apache.sling.launchpad.webapp.integrationtest.scripting.StandaloneScriptExecutionTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.servlets.post.SlingPostProcessorTest
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.02 s - 
in 
org.apache.sling.launchpad.webapp.integrationtest.servlets.post.SlingPostProcessorTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.servlets.post.PostServletOutputContentTypeTest
[INFO] Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.063 s 
- in 
org.apache.sling.launchpad.webapp.integrationtest.servlets.post.PostServletOutputContentTypeTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.issues.SLING2522Test
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.013 s 
- in org.apache.sling.launchpad.webapp.integrationtest.issues.SLING2522Test
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.SlingWebDavServletTest
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.157 s 
- in org.apache.sling.launchpad.webapp.integrationtest.SlingWebDavServletTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.StaticContentTest
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.008 s 
- in org.apache.sling.launchpad.webapp.integrationtest.StaticContentTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.WebdavOptionsTest
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.007 s 
- in org.apache.sling.launchpad.webapp.integrationtest.WebdavOptionsTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.teleporter.TeleportedResourcesFolderTest
[INFO] Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.339 s 
- in 
org.apache.sling.launchpad.webapp.integrationtest.teleporter.TeleportedResourcesFolderTest
[INFO] Running org.apache.sling.launchpad.webapp.integrationtest.IncludeTest
[INFO] Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.594 s 
- in org.apache.sling.launchpad.webapp.integrationtest.IncludeTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.accessManager.ModifyAceTest
[INFO] Tests run: 22, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.15 s 
- in 
org.apache.sling.launchpad.webapp.integrationtest.accessManager.ModifyAceTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.servlets.post.SlingAutoPropertiesTest
[INFO] Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.144 s 
- in 
org.apache.sling.launchpad.webapp.integrationtest.servlets.post.SlingAutoPropertiesTest
[INFO] Running 
org.apache.sling.launchpad.webapp.integrationtest.ServerSideScriptsTest
[IN

[jira] [Comment Edited] (SLING-10186) Enhance cli parsing on sling-feature-launcher

2021-04-01 Thread Eric Norman (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10186?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313403#comment-17313403
 ] 

Eric Norman edited comment on SLING-10186 at 4/1/21, 9:48 PM:
--

These changes seem to contain a regression that now defaults to "debug" log 
level (when no -v arg is present) instead of "info" which results in a 
significant amount of additional debug logging that should only be present when 
the verbose "-v" flag is supplied on the command line.
  
 In other words, this command should log at info level instead of debug level.
{code:java}
 java -jar target/dependency/org.apache.sling.feature.launcher.jar -f 
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far{code}
 

It looks like the handling of the framework properties is incompatible with the 
previous version as well.   For example, using the 
feature-launcher-maven-plugin to override the http.port with a featureProperty 
launcher argument doesn't work with the 1.1.18 version of the feature launcher 
anymore.

In version 1.1.16 of the feature launcher, a space is expected between the "-D" 
and the arg  like this (this is how the feature-launcher-maven-plugin does it) :
{code:java}
-D org.osgi.service.http.port=8081
{code}
But in version 1.1.18 the feature launcher only works without any space between 
the "-D" and the arg like this:
{code:java}
-Dorg.osgi.service.http.port=8081{code}


was (Author: enorman):
These changes seem to contain a regression that now defaults to "debug" log 
level (when no -v arg is present) instead of "info" which results in a 
significant amount of additional debug logging that should only be present when 
the verbose "-v" flag is supplied on the command line.
  
 In other words, this command should log at info level instead of debug level.
{code:java}
 java -jar target/dependency/org.apache.sling.feature.launcher.jar -f 
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far{code}
 

It looks like the handling of the framework properties is incompatible with the 
previous version as well.   For example, using the 
feature-launcher-maven-plugin to override the http.port with a featureProperty 
launcher argument doesn't work with the 1.1.18 version of the feature launcher 
anymore.

In version 1.1.16 of the feature launcher, a space is expected between the "-D" 
and the arg  like this (this is how the feature-launcher-maven-plugin does it) :

 
{code:java}
-D org.osgi.service.http.port=8081
{code}
But in version 1.1.18 the feature launcher only works without any space between 
the "-D" and the arg like this:
{code:java}
-Dorg.osgi.service.http.port=8081{code}

> Enhance cli parsing on sling-feature-launcher
> -
>
> Key: SLING-10186
> URL: https://issues.apache.org/jira/browse/SLING-10186
> Project: Sling
>  Issue Type: Improvement
>Reporter: Stefan Bischof
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Feature Model Launcher 1.1.18
>
>
> extract opts as Constants
>  add longOpt to Options
>  fix plural in description
>  use Builder-pattern to build Options
>  set numberOfArgs , valueSeparator(',')
>  accept (but ignore) empty options without ParsingExceptions
>  using .optionalArg(true) and Optionals
>  option to set loglevel on verbose Option
>  update common-cli version
>  use DefaultParser not deprecated BasicParser
> https://github.com/apache/sling-org-apache-sling-feature-launcher/pull/16



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Comment Edited] (SLING-10186) Enhance cli parsing on sling-feature-launcher

2021-04-01 Thread Eric Norman (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10186?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313403#comment-17313403
 ] 

Eric Norman edited comment on SLING-10186 at 4/1/21, 9:47 PM:
--

These changes seem to contain a regression that now defaults to "debug" log 
level (when no -v arg is present) instead of "info" which results in a 
significant amount of additional debug logging that should only be present when 
the verbose "-v" flag is supplied on the command line.
  
 In other words, this command should log at info level instead of debug level.
{code:java}
 java -jar target/dependency/org.apache.sling.feature.launcher.jar -f 
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far{code}
 

It looks like the handling of the framework properties is incompatible with the 
previous version as well.   For example, using the 
feature-launcher-maven-plugin to override the http.port with a featureProperty 
launcher argument doesn't work with the 1.1.18 version of the feature launcher 
anymore.

In version 1.1.16 of the feature launcher, a space is expected between the "-D" 
and the arg  like this (this is how the feature-launcher-maven-plugin does it) :

 
{code:java}
-D org.osgi.service.http.port=8081
{code}
But in version 1.1.18 the feature launcher only works without any space between 
the "-D" and the arg like this:
{code:java}
-Dorg.osgi.service.http.port=8081{code}


was (Author: enorman):
These changes seem to contain a regression that now defaults to "debug" log 
level (when no -v arg is present) instead of "info" which results in a 
significant amount of additional debug logging that should only be present when 
the verbose "-v" flag is supplied on the command line.
  
 In other words, this command should log at info level instead of debug level.
{code:java}
 java -jar target/dependency/org.apache.sling.feature.launcher.jar -f 
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far{code}

> Enhance cli parsing on sling-feature-launcher
> -
>
> Key: SLING-10186
> URL: https://issues.apache.org/jira/browse/SLING-10186
> Project: Sling
>  Issue Type: Improvement
>Reporter: Stefan Bischof
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Feature Model Launcher 1.1.18
>
>
> extract opts as Constants
>  add longOpt to Options
>  fix plural in description
>  use Builder-pattern to build Options
>  set numberOfArgs , valueSeparator(',')
>  accept (but ignore) empty options without ParsingExceptions
>  using .optionalArg(true) and Optionals
>  option to set loglevel on verbose Option
>  update common-cli version
>  use DefaultParser not deprecated BasicParser
> https://github.com/apache/sling-org-apache-sling-feature-launcher/pull/16



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Comment Edited] (SLING-10186) Enhance cli parsing on sling-feature-launcher

2021-04-01 Thread Eric Norman (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10186?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313403#comment-17313403
 ] 

Eric Norman edited comment on SLING-10186 at 4/1/21, 7:56 PM:
--

These changes seem to contain a regression that now defaults to "debug" log 
level (when no -v arg is present) instead of "info" which results in a 
significant amount of additional debug logging that should only be present when 
the verbose "-v" flag is supplied on the command line.
  
 In other words, this command should log at info level instead of debug level.
{code:java}
 java -jar target/dependency/org.apache.sling.feature.launcher.jar -f 
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far{code}


was (Author: enorman):
These changes seem to contain a regression that now defaults to "debug" log 
level instead of "info" which results in a significant amount of additional 
debug logging that should only be present when the verbose "-v" flag is 
supplied on the command line.
 
In other words, this command should log at info level instead of debug level.
{code:java}
 java -jar target/dependency/org.apache.sling.feature.launcher.jar -f 
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far{code}

> Enhance cli parsing on sling-feature-launcher
> -
>
> Key: SLING-10186
> URL: https://issues.apache.org/jira/browse/SLING-10186
> Project: Sling
>  Issue Type: Improvement
>Reporter: Stefan Bischof
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Feature Model Launcher 1.1.18
>
>
> extract opts as Constants
>  add longOpt to Options
>  fix plural in description
>  use Builder-pattern to build Options
>  set numberOfArgs , valueSeparator(',')
>  accept (but ignore) empty options without ParsingExceptions
>  using .optionalArg(true) and Optionals
>  option to set loglevel on verbose Option
>  update common-cli version
>  use DefaultParser not deprecated BasicParser
> https://github.com/apache/sling-org-apache-sling-feature-launcher/pull/16



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (SLING-8742) Allow overriding the extension when using the RequestDispatcher

2021-04-01 Thread Joerg Hoh (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-8742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313407#comment-17313407
 ] 

Joerg Hoh commented on SLING-8742:
--

We have also the next release of oas.servlets.post depending on a new API 
release. Any preference how to deal with this one?

> Allow overriding the extension when using the RequestDispatcher
> ---
>
> Key: SLING-8742
> URL: https://issues.apache.org/jira/browse/SLING-8742
> Project: Sling
>  Issue Type: Improvement
>  Components: API
>Reporter: Robert Munteanu
>Priority: Major
> Fix For: API 2.23.4
>
>
> It is sometimes useful to be able to include another resource and override 
> the extension at the same time.
> My scenario is that I am routing all requests through an entry point 
> {{/content/maven.html}} and then serving resources based on the suffix.
> If I a binary file is requested, it should be downloaded ( by forcing the 
> extension to be null ), but instead the html extension is used, which means 
> the HTML Renderer kicks in.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Resolved] (SLING-10087) Converting more PersistenceExceptions

2021-04-01 Thread Joerg Hoh (Jira)


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

Joerg Hoh resolved SLING-10087.
---
  Assignee: Joerg Hoh
Resolution: Fixed

> Converting more PersistenceExceptions
> -
>
> Key: SLING-10087
> URL: https://issues.apache.org/jira/browse/SLING-10087
> Project: Sling
>  Issue Type: Improvement
>  Components: Servlets
>Affects Versions: Servlets POST 2.4.2
>Reporter: Joerg Hoh
>Assignee: Joerg Hoh
>Priority: Major
> Fix For: Servlets POST 2.4.4
>
>  Time Spent: 3.5h
>  Remaining Estimate: 0h
>
> In SLING-9896 I missed an important case of converting PersistenceExceptions 
> into more specific exceptions.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (SLING-10087) Converting more PersistenceExceptions

2021-04-01 Thread Joerg Hoh (Jira)


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

Joerg Hoh updated SLING-10087:
--
Fix Version/s: Servlets POST 2.4.4

> Converting more PersistenceExceptions
> -
>
> Key: SLING-10087
> URL: https://issues.apache.org/jira/browse/SLING-10087
> Project: Sling
>  Issue Type: Improvement
>  Components: Servlets
>Affects Versions: Servlets POST 2.4.2
>Reporter: Joerg Hoh
>Priority: Major
> Fix For: Servlets POST 2.4.4
>
>  Time Spent: 3.5h
>  Remaining Estimate: 0h
>
> In SLING-9896 I missed an important case of converting PersistenceExceptions 
> into more specific exceptions.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-servlets-resolver] sonarcloud[bot] commented on pull request #7: [SLING-9230] - Servlet should not be allowed to register with invalid…

2021-04-01 Thread GitBox


sonarcloud[bot] commented on pull request #7:
URL: 
https://github.com/apache/sling-org-apache-sling-servlets-resolver/pull/7#issuecomment-812123958


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_coverage&view=list)
 [70.0% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SLING-10186) Enhance cli parsing on sling-feature-launcher

2021-04-01 Thread Eric Norman (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10186?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313403#comment-17313403
 ] 

Eric Norman commented on SLING-10186:
-

These changes seem to contain a regression that now defaults to "debug" log 
level instead of "info" which results in a significant amount of additional 
debug logging that should only be present when the verbose "-v" flag is 
supplied on the command line.
 
In other words, this command should log at info level instead of debug level.
{code:java}
 java -jar target/dependency/org.apache.sling.feature.launcher.jar -f 
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far{code}

> Enhance cli parsing on sling-feature-launcher
> -
>
> Key: SLING-10186
> URL: https://issues.apache.org/jira/browse/SLING-10186
> Project: Sling
>  Issue Type: Improvement
>Reporter: Stefan Bischof
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Feature Model Launcher 1.1.18
>
>
> extract opts as Constants
>  add longOpt to Options
>  fix plural in description
>  use Builder-pattern to build Options
>  set numberOfArgs , valueSeparator(',')
>  accept (but ignore) empty options without ParsingExceptions
>  using .optionalArg(true) and Optionals
>  option to set loglevel on verbose Option
>  update common-cli version
>  use DefaultParser not deprecated BasicParser
> https://github.com/apache/sling-org-apache-sling-feature-launcher/pull/16



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-servlets-resolver] sonarcloud[bot] removed a comment on pull request #7: [SLING-9230] - Servlet should not be allowed to register with invalid…

2021-04-01 Thread GitBox


sonarcloud[bot] removed a comment on pull request #7:
URL: 
https://github.com/apache/sling-org-apache-sling-servlets-resolver/pull/7#issuecomment-811053628


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_coverage&view=list)
 [70.0% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver&pullRequest=7&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




Re: Release of Servlets Resolver and Scripting bundles

2021-04-01 Thread Oliver Lietz
On Tuesday, 30 March 2021 09:12:43 CEST Konrad Windszus wrote:
> Hi,

Hi Konrad,

> It seems that the big changes for
> https://issues.apache.org/jira/browse/SLING-
>  are done now.
> 
> Also currently no issues are open for
> https://issues.apache.org/jira/issues/?jql=project%20%3D%20SLING%20AND%20fi
> xVersion%20%3D%20%22Scripting%20HTL%20Engine%201.4.8-1.4.0%22
>  Version%20=%20%22Scripting%20HTL%20Engine%201.4.8-1.4.0%22> nor for
> https://issues.apache.org/jira/issues/?jql=project%20%3D%20SLING%20AND%20fi
> xVersion%20%3D%20%22Servlets%20Resolver%202.7.14%22
>  Version%20=%20%22Servlets%20Resolver%202.7.14%22>
> 
> As a lot of bundles are affected I am not sure if all bundles should be
> released/voted on at the same time, or we do it in phases.
> 
> Affected bundles are
> 
> 1. Sling Scripting SPI
> 2. Sling Servlets Resolver (depends on 1)
> 3. Sling Scripting Core (depends on 1)
> 4. Sling Scripting JSP (depends on 1)
> 5. Sling Scripting HTL (depends on 1)
> 6. Sling Scripting Bundle Maven Plugin (depends on 1)
> 
> Any opinions or plans for a release yet?

I have a use case for ResourceType not related to Scripting and would like to 
see it in Sling API (see SLING- for reasons) where it fits well.

https://github.com/apache/sling-org-apache-sling-scripting-spi/blob/master/
src/main/java/org/apache/sling/scripting/spi/bundle/ResourceType.java

WDYT?

Other than that +1 for doing releases in phases.

Regards,
O.


> I am particularly interested in
> https://issues.apache.org/jira/browse/SLING-10012
>  and 
> https://issues.apache.org/jira/browse/SLING-9983
> 
> 
> Konrad






Re: [VOTE] Release Apache Sling Feature Mode, API Extension, Launcher and slingfeature maven plugin

2021-04-01 Thread Eric Norman
+1 for all of them except the Sling Feature Model Launcher 1.1.18

-1 for Sling Feature Model Launcher 1.1.18 since it seems to contain a
regression that now defaults to "debug" log level instead of "info" which
results in a significant amount of additional debug logging that should
only be present when the verbose "-v" flag is supplied on the command line.

In other words, this command should log at info level instead of debug
level.

java -jar target/dependency/org.apache.sling.feature.launcher.jar -f
target/org.apache.sling.starter-12-SNAPSHOT-oak_tar_far.far


Regards,
Eric

On Tue, Mar 30, 2021 at 3:16 AM Carsten Ziegeler 
wrote:

> Hi,
>
> We solved 1 issue for Sling Feature Model 1.2.22
> https://issues.apache.org/jira/projects/SLING/versions/12349671
>
> We solved 3 issues for Sling Feature Model Launcher 1.1.18
> https://issues.apache.org/jira/projects/SLING/versions/12349675
>
> We solved 4 issues for Sling Feature Model API Regions Extension 1.2.0
> https://issues.apache.org/jira/projects/SLING/versions/12349676
>
> We solved 4 issues for slingfeature-maven-plugin 1.5.0
> https://issues.apache.org/jira/projects/SLING/versions/12349677
>
> Staging repositories:
> https://repository.apache.org/content/repositories/orgapachesling-2422
> and
> https://repository.apache.org/content/repositories/orgapachesling-2423
>
>
> You can use this UNIX script to download the release and verify the
> signatures:
>
> https://gitbox.apache.org/repos/asf?p=sling-tooling-release.git;a=blob;f=check_staged_release.sh;hb=HEAD
>
> Usage:
> sh check_staged_release.sh 2422 /tmp/sling-staging
> sh check_staged_release.sh 2423 /tmp/sling-staging
>
> Please vote to approve this release:
>
>   [ ] +1 Approve the release
>   [ ]  0 Don't care
>   [ ] -1 Don't release, because ...
>
> This majority vote is open for at least 72 hours.
>
> Regards
> Carsten
> --
> Carsten Ziegeler
> Adobe Research Switzerland
> cziege...@apache.org
>


Query with Sling Context Loaded Resources

2021-04-01 Thread Andreas Schaefer
Hi

In the sub project org.apache.sling.ddr’s core in the sling-whiteboard I tried 
to use Sling Context to run the Unit Test for 
DeclarativeDynamicResourceManagerServiceTest. 

In there I register a new Node Type:

@Rule
public SlingContext context = new SlingContext(ResourceResolverType.JCR_OAK);

try {

NodeTypeDefinitionScanner.get().register(context.resourceResolver().adaptTo(Session.class),
ImmutableList.of("SLING-CONTENT/nodetypes/ddr.cnd"),
ResourceResolverType.JCR_OAK.getNodeTypeMode());
}
catch (RepositoryException ex) {
throw new RuntimeException("Unable to register namespaces.", ex);
}

 then use the context to load my test resources into /conf:

context.load().json("/ddr-sources/ddr-conf-settings.json", "/conf”);

. The resource /conf/test/settings/dynamic has these properties (Resource 
sourceRoot = resourceResolver.getResource("/conf/test/settings/dynamic”): 

JcrNodeResource, type=sling:DDR, superType=null, 
path=/conf/test/settings/dynamic

Then I do a query:

Iterator i = resourceResolver.findResources(
"SELECT * FROM [" + DDR_NODE_TYPE + "]",
Query.JCR_SQL2
);

But the iterator is empty. 

Is that not supported or did I do something wrong here.

Thanks - Andy

Re: Releasing new Sling API?

2021-04-01 Thread Bertrand Delacretaz
Hi Joerg,

On Thu, Apr 1, 2021 at 6:52 PM Jörg Hoh  wrote:
> ...Are there any pending changes, which should go into it,...

FWIW, https://issues.apache.org/jira/projects/SLING/versions/12349583
lists some open issues

I'm not planning to work on any of those at the moment but I see that
https://issues.apache.org/jira/browse/SLING-8742 has an unanswered
question.

-Bertrand


Releasing new Sling API?

2021-04-01 Thread Jörg Hoh
Hi,

In order to cut a release of the Sling Post Servlet, we need to get a
release of Sling API out of the door first.

Are there any pending changes, which should go into it, or would it be
possible to cut a release within the next days/weeks for it?
(And that also does not mean, that I volunteer to make that API release as
my very first release here at Sling ... :-)

Jörg

-- 
Cheers,
Jörg Hoh,

http://cqdump.wordpress.com
Twitter: @joerghoh


[jira] [Commented] (SLING-10087) Converting more PersistenceExceptions

2021-04-01 Thread Joerg Hoh (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10087?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313305#comment-17313305
 ] 

Joerg Hoh commented on SLING-10087:
---

[https://github.com/apache/sling-org-apache-sling-servlets-post/pull/11] merged

> Converting more PersistenceExceptions
> -
>
> Key: SLING-10087
> URL: https://issues.apache.org/jira/browse/SLING-10087
> Project: Sling
>  Issue Type: Improvement
>  Components: Servlets
>Affects Versions: Servlets POST 2.4.2
>Reporter: Joerg Hoh
>Priority: Major
>  Time Spent: 3.5h
>  Remaining Estimate: 0h
>
> In SLING-9896 I missed an important case of converting PersistenceExceptions 
> into more specific exceptions.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-servlets-post] joerghoh merged pull request #11: SLING-10087 convert more persistenceexceptions

2021-04-01 Thread GitBox


joerghoh merged pull request #11:
URL: https://github.com/apache/sling-org-apache-sling-servlets-post/pull/11


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SLING-8450) JcrPersist: Provide transparent persistence to Sling Models

2021-04-01 Thread Bertrand Delacretaz (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-8450?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313221#comment-17313221
 ] 

Bertrand Delacretaz commented on SLING-8450:


FWIW, that module is now at 
https://github.com/apache/sling-whiteboard/tree/master/SlingModelPersist

> JcrPersist: Provide transparent persistence to Sling Models
> ---
>
> Key: SLING-8450
> URL: https://issues.apache.org/jira/browse/SLING-8450
> Project: Sling
>  Issue Type: New Feature
>  Components: API
>Reporter: Brendan Robert
>Priority: Major
> Attachments: SlingJCRPersist.zip
>
>
> As a developer using sling, I would like my sling models to serve as a core 
> of a MVC coding paradigm; however, it is not possible to do this without 
> writing my own persistence logic to save my sling models back into resources 
> for every project I do this.
> I propose a new module to work in tandem with Sling Models, such that Sling 
> Models serve as a mechanism to load data from JCR and the JcrPersist module 
> provides an OSGi service to save changes to beans back to the JCR via a 
> persist method.
> There are some complex sling model features, such as @via, which will likely 
> not be subject to this feature, and other cases such as transient variables 
> that should not be persisted.  The persist service should provide the 
> developer a sufficient set of features to decide how much or how little is 
> persisted with it.  Like Sling Models, this should rely on annotations so 
> that no additional external configurations are needed.
>  
> PS: Here's the implementation with ~90% unit test coverage.  See attached. :)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Resolved] (SLING-10163) Improve test coverage with sling.auth.core

2021-04-01 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler resolved SLING-10163.
--
Resolution: Fixed

Though I improved test coverage, the core methods are still not covered, 
therefore create SLING-10272 to further track this

> Improve test coverage with sling.auth.core
> --
>
> Key: SLING-10163
> URL: https://issues.apache.org/jira/browse/SLING-10163
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Angela Schreiber
>Assignee: Carsten Ziegeler
>Priority: Critical
> Fix For: Auth Core 1.5.2
>
>
> according to 
> https://sonarcloud.io/dashboard?id=apache_sling-org-apache-sling-auth-core 
> the current code coverage is just 29%. for a bundle as crucial as the sling 
> authentication code base, this should be heavily increased and should in 
> particular provide full coverage for those parts that are critical for the 
> overall stability and performance. afaik there pieces in the 
> {{SlingAuthenticator}} that look wired but cannot be touched without 
> introducing major regressions. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (SLING-10272) Improve test coverage with sling.auth.core

2021-04-01 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler updated SLING-10272:
-
Fix Version/s: (was: Auth Core 1.5.2)

> Improve test coverage with sling.auth.core
> --
>
> Key: SLING-10272
> URL: https://issues.apache.org/jira/browse/SLING-10272
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Angela Schreiber
>Priority: Critical
>
> according to 
> https://sonarcloud.io/dashboard?id=apache_sling-org-apache-sling-auth-core 
> the current code coverage is just 29%. for a bundle as crucial as the sling 
> authentication code base, this should be heavily increased and should in 
> particular provide full coverage for those parts that are critical for the 
> overall stability and performance. afaik there pieces in the 
> {{SlingAuthenticator}} that look wired but cannot be touched without 
> introducing major regressions. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (SLING-10272) Improve test coverage with sling.auth.core

2021-04-01 Thread Carsten Ziegeler (Jira)
Carsten Ziegeler created SLING-10272:


 Summary: Improve test coverage with sling.auth.core
 Key: SLING-10272
 URL: https://issues.apache.org/jira/browse/SLING-10272
 Project: Sling
  Issue Type: Improvement
  Components: Authentication
Reporter: Angela Schreiber
Assignee: Carsten Ziegeler
 Fix For: Auth Core 1.5.2


according to 
https://sonarcloud.io/dashboard?id=apache_sling-org-apache-sling-auth-core the 
current code coverage is just 29%. for a bundle as crucial as the sling 
authentication code base, this should be heavily increased and should in 
particular provide full coverage for those parts that are critical for the 
overall stability and performance. afaik there pieces in the 
{{SlingAuthenticator}} that look wired but cannot be touched without 
introducing major regressions. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Assigned] (SLING-10272) Improve test coverage with sling.auth.core

2021-04-01 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler reassigned SLING-10272:


Assignee: (was: Carsten Ziegeler)

> Improve test coverage with sling.auth.core
> --
>
> Key: SLING-10272
> URL: https://issues.apache.org/jira/browse/SLING-10272
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Angela Schreiber
>Priority: Critical
> Fix For: Auth Core 1.5.2
>
>
> according to 
> https://sonarcloud.io/dashboard?id=apache_sling-org-apache-sling-auth-core 
> the current code coverage is just 29%. for a bundle as crucial as the sling 
> authentication code base, this should be heavily increased and should in 
> particular provide full coverage for those parts that are critical for the 
> overall stability and performance. afaik there pieces in the 
> {{SlingAuthenticator}} that look wired but cannot be touched without 
> introducing major regressions. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-dynamic-include] rombert commented on a change in pull request #19: Extend the IncludeGenerator interface with the Sling Request

2021-04-01 Thread GitBox


rombert commented on a change in pull request #19:
URL: 
https://github.com/apache/sling-org-apache-sling-dynamic-include/pull/19#discussion_r605601669



##
File path: 
src/main/java/org/apache/sling/dynamicinclude/api/IncludeGenerator.java
##
@@ -17,13 +17,15 @@
  * under the License.
  */
 
-package org.apache.sling.dynamicinclude.generator;
+package org.apache.sling.dynamicinclude.api;
+
+import org.apache.sling.api.SlingHttpServletRequest;
 
 /**
  * Include generator interface
  */
 public interface IncludeGenerator {
 String getType();
 
-String getInclude(String url);
+String getInclude(SlingHttpServletRequest request,String url);

Review comment:
   I think that would be ok, granted that we:
   
   - find a better name for it ( normalizedUrl?)
   - add better documentation to the interface and the method, explaining why 
we pass in an apparently redundant parameter




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [sling-org-apache-sling-dynamic-include] rombert commented on a change in pull request #19: Extend the IncludeGenerator interface with the Sling Request

2021-04-01 Thread GitBox


rombert commented on a change in pull request #19:
URL: 
https://github.com/apache/sling-org-apache-sling-dynamic-include/pull/19#discussion_r605591995



##
File path: src/main/java/org/apache/sling/dynamicinclude/Configuration.java
##
@@ -66,11 +65,7 @@
   @AttributeDefinition(name="Resource types", description="Filter will 
replace components with selected resource types", cardinality = 
Integer.MAX_VALUE)
   String include$_$filter_config_resource$_$types() default "";
   
-  @AttributeDefinition(name = "Include type", description = "Type of 
generated include tags", options = {
-  @Option(label = "Apache SSI", value = "SSI"),
-  @Option(label = "ESI", value = "ESI"),
-  @Option(label = "Javascript", value = "JSI")
-  })
+  @AttributeDefinition(name = "Include type", description = "Type of 
generated include tags")

Review comment:
   Makes sense. It might help if we listed the built-in implementations.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SLING-10269) cache results of isResourceType()

2021-04-01 Thread Joerg Hoh (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10269?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313107#comment-17313107
 ] 

Joerg Hoh commented on SLING-10269:
---

In https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/43 
[~rombert] mentioned the aspect "write operations", which is currently not 
properly reflected. The new cache is invalidated when the resourceresolver is 
refreshed and on commit, but it cannot detect this case:

{code}
ResourceResolver rr = ...;
Session session = rr.adaptTo(Session.class);
...
session.save();
{code}

If during this operation relevant resources/nodes are modified, which influence 
the {{resourceType}}/{{resourceSuperType}} handling, these updates are ignored.
On the other hand side, the 
[JcrValueMap|https://github.com/apache/sling-org-apache-sling-jcr-resource/blob/master/src/main/java/org/apache/sling/jcr/resource/internal/JcrValueMap.java]
 handles it the same way.

How should we proceed with that? From a strict compatibility point of view we 
are breaking it (it worked before this change), but I am not sure about the 
severity of this issue, especially given that the JcrValueMap behavior has most 
likely a larger impact as this one.



> cache results of isResourceType()
> -
>
> Key: SLING-10269
> URL: https://issues.apache.org/jira/browse/SLING-10269
> Project: Sling
>  Issue Type: Improvement
>  Components: ResourceResolver
>Affects Versions: Resource Resolver 1.7.2
>Reporter: Joerg Hoh
>Assignee: Joerg Hoh
>Priority: Major
>  Time Spent: 3h 20m
>  Remaining Estimate: 0h
>
> I have code, which uses {noformat}resourceResolver.isResourceType(Resource, 
> String){noformat} very often to determine type information. I also observed, 
> that the execution time of this method contributes a lot to the overall 
> execution time.
> Also the number of unique resourcetypes which are going to be checked 
> (resource.getResourceType, 1st parameter) is typically quite low; the same 
> applies for the number of resourcetypes it is compared against. So it makes 
> sense to cache the result of that method call in map which shares the 
> lifetime of the ResourceResolver, as the result will never change during this 
> lifetime. But during a refresh() this map can be cleared, so any changes in 
> the RT hierarchy which might have happened will get effective.
> I have tested this approach already and it gives a significant speedup to my 
> code (reduced execution time by 50%); of course this cannot be expected 
> universally, as this is an extreme case, but it shows that there is indeed a 
> bit of overhead.
> https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/43



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-resourceresolver] rombert commented on pull request #43: SLING-10269 cache the result of isResourceType()

2021-04-01 Thread GitBox


rombert commented on pull request #43:
URL: 
https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/43#issuecomment-811850831


   @joerghoh - all good know from my POV. Please make sure to _Squash and 
merge_ when done to keep a single commit for this atomic change.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[Jenkins] Sling » Modules » sling-org-apache-sling-launchpad-testing » master #408 is FIXED

2021-04-01 Thread Apache Jenkins Server
Please see 
https://ci-builds.apache.org/job/Sling/job/modules/job/sling-org-apache-sling-launchpad-testing/job/master/408/
 for details.

No further emails will be sent until the status of the build is changed.

[jira] [Commented] (SLING-10011) Use javax.jcr.Item.getParent() when resolving parent JCR node in JcrResourceProvider#getParent

2021-04-01 Thread Miroslav Smiljanic (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10011?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313059#comment-17313059
 ] 

Miroslav Smiljanic commented on SLING-10011:


[~cziegeler] the essence of the proposed change is captured in the PR:
[https://github.com/apache/sling-org-apache-sling-jcr-resource/pull/11/files]

 

> Use javax.jcr.Item.getParent() when resolving parent JCR node in 
> JcrResourceProvider#getParent
> --
>
> Key: SLING-10011
> URL: https://issues.apache.org/jira/browse/SLING-10011
> Project: Sling
>  Issue Type: Improvement
>  Components: JCR
>Affects Versions: JCR Resource 3.0.22
>Reporter: Miroslav Smiljanic
>Priority: Minor
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Currently 
> [JcrResourceProvider.getParent|https://github.com/apache/sling-org-apache-sling-jcr-resource/blob/org.apache.sling.jcr.resource-3.0.22/src/main/java/org/apache/sling/jcr/resource/internal/helper/jcr/JcrResourceProvider.java#L361]
>  is using JcrItemResourceFactory.getItemOrNull(String path), which eventually 
> is using JCR session to retrieve parent node using absolute path.
> I propose using javax.jcr.Item.getParent() instead.
> Reasoning wold be to utilise potential improvements in JCR implementation 
> that would for a given node retrieve the whole subtree. That can be 
> configured for example by using particular node type or node path.
> {noformat}
> root
>  |
>  a 
>/   \
>   b c
> {noformat}
> If node 'a' in picture above, is matching desired configuration, then code 
> below would return the whole subtree.
> {code:java}
> Node a = jcrSession.getNode("a");
> {code}
> That further means retrieved subtree can be traversed in memory, without the 
> need to communicate with the JCR repository storage.
> (!)That is particularly important when remote (cloud) storage is used for 
> repository in JCR implementation, and tree traversal can be done without 
> doing additional network roundtrips.
> {code:java}
> //JCR tree traversal happens in memory
> Node b = a.getNode("b");
> Node c = a.getNode("c");
> {code}
> Also going from child to parent, is resolved in memory as well (proposal 
> relates to this fact)
> {code:java}
> //JCR tree traversal happens in memory
> assert b.getParent() == c.getParent();
> {code}
> Jackrabbit Oak, for document node store is supporting node bundling for 
> configured node type
>  [http://jackrabbit.apache.org/oak/docs/nodestore/document/node-bundling.html]
> Currently I am also doing some experiments to support node 
> bundling/aggregation for arbitrary node store 
> ([NodeDelegateFullyLoaded|https://github.com/smiroslav/jackrabbit-oak/blob/ppnextgen_newstore/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/delegate/NodeDelegateFullyLoaded.java],
>  
> [FullyLoadedTree|https://github.com/smiroslav/jackrabbit-oak/blob/ppnextgen_newstore/oak-core/src/main/java/org/apache/jackrabbit/oak/core/FullyLoadedTree.java]).



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-feature-cpconverter] sonarcloud[bot] commented on pull request #68: SLING-10268 : Use Operation.asRepoInitString instead of hardcoding repo-init statements

2021-04-01 Thread GitBox


sonarcloud[bot] commented on pull request #68:
URL: 
https://github.com/apache/sling-org-apache-sling-feature-cpconverter/pull/68#issuecomment-811797196


   Kudos, SonarCloud Quality Gate passed!
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
 [92.5% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SLING-10119) Repoinit parser fails on "set property end to..."

2021-04-01 Thread Bertrand Delacretaz (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10119?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313057#comment-17313057
 ] 

Bertrand Delacretaz commented on SLING-10119:
-

This is the grammar of the related parser productions, I'm not sure why "set 
end" causes it to "jump" to the final  token.

{code}
void propertyLine(List lines) :
{
Token name = null;
Token type = null;
List values;
Token t = null;
boolean isDefault = false;
}
{
(t =  | t =  {isDefault = true;} )
( name =  | name = )
(  ( type =  )  )?
 ( values = propertyValuesList() )

{
lines.add(new PropertyLine(name.image, type == null ? null : 
type.image, values, isDefault));
}
}

void setPropertiesStatement(List result) :
{
List lines = new ArrayList();
List paths;
}
{
( paths  = pathsList() ) 
( propertyLine(lines) | blankLine() ) +

(  |  )
{
result.add(new SetProperties(paths, lines));
}
}
{code}

> Repoinit parser fails on "set property end to..."
> -
>
> Key: SLING-10119
> URL: https://issues.apache.org/jira/browse/SLING-10119
> Project: Sling
>  Issue Type: Improvement
>  Components: Repoinit
>Affects Versions: Repoinit Parser 1.6.2
>Reporter: Bertrand Delacretaz
>Assignee: Bertrand Delacretaz
>Priority: Minor
>
> Using "end" instead of "endS" in the below test causes parsing to fail:
>  
> {code}
> set properties on /endkeyword
>   # using "end" instead of "endS" below causes parsing to fail
>   set endS to one
>   set two to endS
> end
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-feature-cpconverter] sonarcloud[bot] removed a comment on pull request #68: SLING-10268 : Use Operation.asRepoInitString instead of hardcoding repo-init statements

2021-04-01 Thread GitBox


sonarcloud[bot] removed a comment on pull request #68:
URL: 
https://github.com/apache/sling-org-apache-sling-feature-cpconverter/pull/68#issuecomment-811766956


   Kudos, SonarCloud Quality Gate passed!
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
 [92.5% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SLING-10215) repoinit analyser fails if there is no repoinit section

2021-04-01 Thread Bertrand Delacretaz (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10215?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313039#comment-17313039
 ] 

Bertrand Delacretaz commented on SLING-10215:
-

FYI, I have created SLING-10271 to make the streaming reader issue specific to 
the parser.

> repoinit analyser fails if there is no repoinit section
> ---
>
> Key: SLING-10215
> URL: https://issues.apache.org/jira/browse/SLING-10215
> Project: Sling
>  Issue Type: Bug
>  Components: Feature Model Analyser
>Affects Versions: Feature Model Analyser 1.3.22
>Reporter: A. J. David Bosschaert
>Priority: Major
> Fix For: Feature Model Analyser 1.3.24, Repoinit Parser 1.6.8
>
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> As reported by [~joerghoh]:
> the analyzer complains about an invalid repoinit, but the created test 
> project does not contain any repoinit statement.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Resolved] (SLING-10271) Use a streaming filter in RepoInitParserService

2021-04-01 Thread Bertrand Delacretaz (Jira)


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

Bertrand Delacretaz resolved SLING-10271.
-
Resolution: Fixed

Resolving as the corresponding fix has been done a while ago.

> Use a streaming filter in RepoInitParserService
> ---
>
> Key: SLING-10271
> URL: https://issues.apache.org/jira/browse/SLING-10271
> Project: Sling
>  Issue Type: Improvement
>  Components: Repoinit
>Affects Versions: Repoinit Parser 1.6.6
>Reporter: Bertrand Delacretaz
>Assignee: Konrad Windszus
>Priority: Minor
> Fix For: Repoinit Parser 1.6.8
>
>
> The change of [commit 
> 05cae0cce|https://github.com/apache/sling-org-apache-sling-repoinit-parser/commit/05cae0cce036f83494f3722a6b693abbc6e182ca],
>  which uses a streaming {{Reader}} to add the ending newline before parsing, 
> was handled in SLING-10215 but really belongs to the repoinit parser module.
> I'm creating this ticket so that SLING-10215, which is not resolved yet, does 
> not block the next repoinit parser release.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (SLING-10271) Use a streaming filter in RepoInitParserService

2021-04-01 Thread Bertrand Delacretaz (Jira)
Bertrand Delacretaz created SLING-10271:
---

 Summary: Use a streaming filter in RepoInitParserService
 Key: SLING-10271
 URL: https://issues.apache.org/jira/browse/SLING-10271
 Project: Sling
  Issue Type: Improvement
  Components: Repoinit
Affects Versions: Repoinit Parser 1.6.6
Reporter: Bertrand Delacretaz
Assignee: Konrad Windszus
 Fix For: Repoinit Parser 1.6.8


The change of [commit 
05cae0cce|https://github.com/apache/sling-org-apache-sling-repoinit-parser/commit/05cae0cce036f83494f3722a6b693abbc6e182ca],
 which uses a streaming {{Reader}} to add the ending newline before parsing, 
was handled in SLING-10215 but really belongs to the repoinit parser module.

I'm creating this ticket so that SLING-10215, which is not resolved yet, does 
not block the next repoinit parser release.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Resolved] (SLING-10270) Disabling service users sets incorrect "reason"

2021-04-01 Thread Bertrand Delacretaz (Jira)


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

Bertrand Delacretaz resolved SLING-10270.
-
Resolution: Fixed

Fixed in [commit 
5dd19a2|https://github.com/apache/sling-org-apache-sling-jcr-repoinit/commit/5dd19a27f099bb44af1c366fdeceaa6f45b10eb6]

> Disabling service users sets incorrect "reason" 
> 
>
> Key: SLING-10270
> URL: https://issues.apache.org/jira/browse/SLING-10270
> Project: Sling
>  Issue Type: Bug
>  Components: Repoinit
>Affects Versions: Repoinit JCR 1.1.34
>Reporter: Bertrand Delacretaz
>Assignee: Bertrand Delacretaz
>Priority: Minor
> Fix For: Repoinit JCR 1.1.36
>
>
> The {{UserVisitor}} currently uses 
> {{DisableServiceUser.getParametersDescription()}} for the value of the 
> "disable reason" string.
> That includes additional information besides the reason defined by the 
> repoinit statement.
> The new {{getReason()}} method introduced by SLING-10235 allows for getting 
> just the reason string, it should be used instead.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-feature-cpconverter] sonarcloud[bot] commented on pull request #68: SLING-10268 : Use Operation.asRepoInitString instead of hardcoding repo-init statements

2021-04-01 Thread GitBox


sonarcloud[bot] commented on pull request #68:
URL: 
https://github.com/apache/sling-org-apache-sling-feature-cpconverter/pull/68#issuecomment-811766956


   Kudos, SonarCloud Quality Gate passed!
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
 [92.5% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [sling-org-apache-sling-feature-cpconverter] sonarcloud[bot] removed a comment on pull request #68: SLING-10268 : Use Operation.asRepoInitString instead of hardcoding repo-init statements

2021-04-01 Thread GitBox


sonarcloud[bot] removed a comment on pull request #68:
URL: 
https://github.com/apache/sling-org-apache-sling-feature-cpconverter/pull/68#issuecomment-811022520


   Kudos, SonarCloud Quality Gate passed!
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
 [92.5% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter&pullRequest=68&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SLING-10235) DisableServiceUser does not allow to retrieve original disable-reason

2021-04-01 Thread Bertrand Delacretaz (Jira)


[ 
https://issues.apache.org/jira/browse/SLING-10235?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17313020#comment-17313020
 ] 

Bertrand Delacretaz commented on SLING-10235:
-

I have created SLING-10270 for the {{UserVisitor}} fix in the jcr-repoinit 
module.

> DisableServiceUser does not allow to retrieve original disable-reason
> -
>
> Key: SLING-10235
> URL: https://issues.apache.org/jira/browse/SLING-10235
> Project: Sling
>  Issue Type: Bug
>  Components: Repoinit
>Affects Versions: Repoinit Parser 1.6.6
>Reporter: Angela Schreiber
>Assignee: Bertrand Delacretaz
>Priority: Major
> Fix For: Repoinit Parser 1.6.8
>
>
> [~bdelacretaz], during preliminary investigation into SLING-10219 i noticed 
> that there is no way to obtain the original disable reason from 
> {{DisableServiceUser}} operation.
> for the documented example:
> {code}
> disable service user deprecated_service_user : "Disabled user to make an 
> example"
> {code}
> the jcr-repoinit {{UserVisitor.visitDisableServiceUser}} will do the 
> following:
> {code}
> public void visitDisableServiceUser(DisableServiceUser dsu) {
> final String username = dsu.getUsername();
> final String reason = dsu.getParametersDescription();
> [...]
> }
> {code}
> however, {{DisableServiceUser.getParametersDescription}} looks as follows:
> {code}
> public String getParametersDescription() {
> StringBuilder sb = new StringBuilder();
> sb.append(super.getParametersDescription());
> if (this.reason != null) {
> sb.append(" : ");
> sb.append(this.reason);
> }
> return sb.toString();
> }
> {code}
> where {{super.getParametersDescription())}} returns the {{userName}}.
> so, the resulting disable reason stored in the repository will be:
> "deprecated_service_user : Disabled user to make an example"
> instead of
> "Disabled user to make an example"
> note, that there is no other way to retrieve the original reason (e.g. 
> {{DisableServiceUser.getReason()}} which means for SLING-10219 that the 
> param-description needs to be parsed again i.e. relying on implementation 
> detail, which looks quite wrong.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Resolved] (SLING-10235) DisableServiceUser does not allow to retrieve original disable-reason

2021-04-01 Thread Bertrand Delacretaz (Jira)


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

Bertrand Delacretaz resolved SLING-10235.
-
Resolution: Fixed

> DisableServiceUser does not allow to retrieve original disable-reason
> -
>
> Key: SLING-10235
> URL: https://issues.apache.org/jira/browse/SLING-10235
> Project: Sling
>  Issue Type: Bug
>  Components: Repoinit
>Affects Versions: Repoinit Parser 1.6.6
>Reporter: Angela Schreiber
>Assignee: Bertrand Delacretaz
>Priority: Major
> Fix For: Repoinit Parser 1.6.8
>
>
> [~bdelacretaz], during preliminary investigation into SLING-10219 i noticed 
> that there is no way to obtain the original disable reason from 
> {{DisableServiceUser}} operation.
> for the documented example:
> {code}
> disable service user deprecated_service_user : "Disabled user to make an 
> example"
> {code}
> the jcr-repoinit {{UserVisitor.visitDisableServiceUser}} will do the 
> following:
> {code}
> public void visitDisableServiceUser(DisableServiceUser dsu) {
> final String username = dsu.getUsername();
> final String reason = dsu.getParametersDescription();
> [...]
> }
> {code}
> however, {{DisableServiceUser.getParametersDescription}} looks as follows:
> {code}
> public String getParametersDescription() {
> StringBuilder sb = new StringBuilder();
> sb.append(super.getParametersDescription());
> if (this.reason != null) {
> sb.append(" : ");
> sb.append(this.reason);
> }
> return sb.toString();
> }
> {code}
> where {{super.getParametersDescription())}} returns the {{userName}}.
> so, the resulting disable reason stored in the repository will be:
> "deprecated_service_user : Disabled user to make an example"
> instead of
> "Disabled user to make an example"
> note, that there is no other way to retrieve the original reason (e.g. 
> {{DisableServiceUser.getReason()}} which means for SLING-10219 that the 
> param-description needs to be parsed again i.e. relying on implementation 
> detail, which looks quite wrong.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (SLING-10270) Disabling service users sets incorrect "reason"

2021-04-01 Thread Bertrand Delacretaz (Jira)
Bertrand Delacretaz created SLING-10270:
---

 Summary: Disabling service users sets incorrect "reason" 
 Key: SLING-10270
 URL: https://issues.apache.org/jira/browse/SLING-10270
 Project: Sling
  Issue Type: Bug
  Components: Repoinit
Affects Versions: Repoinit JCR 1.1.34
Reporter: Bertrand Delacretaz
Assignee: Bertrand Delacretaz
 Fix For: Repoinit JCR 1.1.36


The {{UserVisitor}} currently uses 
{{DisableServiceUser.getParametersDescription()}} for the value of the "disable 
reason" string.

That includes additional information besides the reason defined by the repoinit 
statement.

The new {{getReason()}} method introduced by SLING-10235 allows for getting 
just the reason string, it should be used instead.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [sling-org-apache-sling-resourceresolver] sonarcloud[bot] commented on pull request #43: SLING-10269 cache the result of isResourceType()

2021-04-01 Thread GitBox


sonarcloud[bot] commented on pull request #43:
URL: 
https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/43#issuecomment-811713562


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=CODE_SMELL)
 [4 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_coverage&view=list)
 [71.1% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [sling-org-apache-sling-resourceresolver] sonarcloud[bot] removed a comment on pull request #43: SLING-10269 cache the result of isResourceType()

2021-04-01 Thread GitBox


sonarcloud[bot] removed a comment on pull request #43:
URL: 
https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/43#issuecomment-811072292


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=CODE_SMELL)
 [4 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&resolved=false&types=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_coverage&view=list)
 [62.4% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_coverage&view=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_duplicated_lines_density&view=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-resourceresolver&pullRequest=43&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [sling-org-apache-sling-resourceresolver] joerghoh commented on pull request #43: SLING-10269 cache the result of isResourceType()

2021-04-01 Thread GitBox


joerghoh commented on pull request #43:
URL: 
https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/43#issuecomment-811712792


   @rombert: Thanks for your feedback, I adjusted the implementation for 
`hashcode` as requested (and I wonder why Eclipse needs to be told explicitly 
to make it right).
   I also switched to a ConcurrentHashMap, and the use `computeIfAbsent` makes 
the code indeed much more expressive (and shorter).


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org