Re: [VOTE] Release Apache Sling Oak-Based Discovery Service 1.2.32

2021-04-21 Thread Eric Norman
-1 for me as switching to this release appears to cause some regressions
related to the changes from SLING-10204

Specifically, I noticed some of my local automated tests started to fail
with what appeared to be a problem with some of my JobConsumer components
no longer getting triggered.  I took a look at the error.log and there are
numerous "java.lang.IllegalStateException: Resource resolver is already
closed." exceptions being reported with various stacktraces related
to OakClusterViewService.

I believe the following is the stack trace related to the JobConsumer
troubles:

21.04.2021 14:24:06.617 *ERROR* [Apache Sling Repository Startup Thread #1]
org.apache.sling.discovery.oak.cluster.OakClusterViewService
getLocalClusterView: repository exception: java.lang.IllegalStateException:
Resource resolver is already closed.
java.lang.IllegalStateException: Resource resolver is already closed.
at
org.apache.sling.resourceresolver.impl.ResourceResolverImpl.checkClosed(ResourceResolverImpl.java:196)
[org.apache.sling.resourceresolver:1.7.4]
at
org.apache.sling.resourceresolver.impl.ResourceResolverImpl.getResource(ResourceResolverImpl.java:447)
[org.apache.sling.resourceresolver:1.7.4]
at
org.apache.sling.api.resource.ResourceUtil.getOrCreateResourceInternal(ResourceUtil.java:644)
[org.apache.sling.api:2.23.1.SNAPSHOT]
at
org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:603)
[org.apache.sling.api:2.23.1.SNAPSHOT]
at
org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:571)
[org.apache.sling.api:2.23.1.SNAPSHOT]
at
org.apache.sling.discovery.commons.providers.util.ResourceHelper.getOrCreateResource(ResourceHelper.java:45)
[org.apache.sling.discovery.commons:1.0.20]
at
org.apache.sling.discovery.commons.providers.spi.base.IdMapService.readIdMap(IdMapService.java:302)
[org.apache.sling.discovery.commons:1.0.20]
at
org.apache.sling.discovery.commons.providers.spi.base.IdMapService.toSlingId(IdMapService.java:280)
[org.apache.sling.discovery.commons:1.0.20]
at
org.apache.sling.discovery.oak.cluster.OakClusterViewService.asClusterView(OakClusterViewService.java:187)
[org.apache.sling.discovery.oak:1.2.32]
at
org.apache.sling.discovery.oak.cluster.OakClusterViewService.getLocalClusterView(OakClusterViewService.java:137)
[org.apache.sling.discovery.oak:1.2.32]
at
org.apache.sling.discovery.base.commons.BaseDiscoveryService.getTopology(BaseDiscoveryService.java:77)
[org.apache.sling.discovery.base:2.0.8]
at
org.apache.sling.discovery.oak.OakDiscoveryService.checkForTopologyChange(OakDiscoveryService.java:678)
[org.apache.sling.discovery.oak:1.2.32]
at
org.apache.sling.discovery.oak.OakDiscoveryService.bindPropertyProviderInteral(OakDiscoveryService.java:414)
[org.apache.sling.discovery.oak:1.2.32]
at
org.apache.sling.discovery.oak.OakDiscoveryService.updatedPropertyProvider(OakDiscoveryService.java:428)
[org.apache.sling.discovery.oak:1.2.32]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at
org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:244)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:685)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.inject.methods.BaseMethod$NotResolved.invoke(BaseMethod.java:639)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:529)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.inject.methods.BindMethod.invoke(BindMethod.java:42)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.manager.DependencyManager.invokeUpdatedMethod(DependencyManager.java:2135)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.manager.SingleComponentManager.invokeUpdatedMethod(SingleComponentManager.java:454)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:374)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:301)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerModified(ServiceTracker.java:1213)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerModified(ServiceTracker.java:1121)
[org.apache.felix.scr:2.1.26]
at
org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:867)
[org.apache.felix.scr:2.1.26]
at

[jira] [Commented] (SLING-10204) Make OakDiscoveryService.updatedPropertyProvider tolerate deactivated repository

2021-04-21 Thread Eric Norman (Jira)


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

Eric Norman commented on SLING-10204:
-

[~stefanegli] Switching to the 1.2.32 release appears to cause some regressions 
related to the changes here.

Specifically, I noticed some of my local automated tests started to fail with 
what appeared to be a problem with some of my JobConsumer components no longer 
getting triggered.  I took a look at the error.log and there are numerous 
"java.lang.IllegalStateException: Resource resolver is already closed." 
exceptions being reported with various stacktraces related to 
OakClusterViewService.   

I believe the following is the stack trace related to the JobConsumer troubles:
{noformat}
21.04.2021 14:24:06.617 *ERROR* [Apache Sling Repository Startup Thread #1] 
org.apache.sling.discovery.oak.cluster.OakClusterViewService 
getLocalClusterView: repository exception: java.lang.IllegalStateException: 
Resource resolver is already closed.
java.lang.IllegalStateException: Resource resolver is already closed.
at 
org.apache.sling.resourceresolver.impl.ResourceResolverImpl.checkClosed(ResourceResolverImpl.java:196)
 [org.apache.sling.resourceresolver:1.7.4]
at 
org.apache.sling.resourceresolver.impl.ResourceResolverImpl.getResource(ResourceResolverImpl.java:447)
 [org.apache.sling.resourceresolver:1.7.4]
at 
org.apache.sling.api.resource.ResourceUtil.getOrCreateResourceInternal(ResourceUtil.java:644)
 [org.apache.sling.api:2.23.1.SNAPSHOT]
at 
org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:603)
 [org.apache.sling.api:2.23.1.SNAPSHOT]
at 
org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:571)
 [org.apache.sling.api:2.23.1.SNAPSHOT]
at 
org.apache.sling.discovery.commons.providers.util.ResourceHelper.getOrCreateResource(ResourceHelper.java:45)
 [org.apache.sling.discovery.commons:1.0.20]
at 
org.apache.sling.discovery.commons.providers.spi.base.IdMapService.readIdMap(IdMapService.java:302)
 [org.apache.sling.discovery.commons:1.0.20]
at 
org.apache.sling.discovery.commons.providers.spi.base.IdMapService.toSlingId(IdMapService.java:280)
 [org.apache.sling.discovery.commons:1.0.20]
at 
org.apache.sling.discovery.oak.cluster.OakClusterViewService.asClusterView(OakClusterViewService.java:187)
 [org.apache.sling.discovery.oak:1.2.32]
at 
org.apache.sling.discovery.oak.cluster.OakClusterViewService.getLocalClusterView(OakClusterViewService.java:137)
 [org.apache.sling.discovery.oak:1.2.32]
at 
org.apache.sling.discovery.base.commons.BaseDiscoveryService.getTopology(BaseDiscoveryService.java:77)
 [org.apache.sling.discovery.base:2.0.8]
at 
org.apache.sling.discovery.oak.OakDiscoveryService.checkForTopologyChange(OakDiscoveryService.java:678)
 [org.apache.sling.discovery.oak:1.2.32]
at 
org.apache.sling.discovery.oak.OakDiscoveryService.bindPropertyProviderInteral(OakDiscoveryService.java:414)
 [org.apache.sling.discovery.oak:1.2.32]
at 
org.apache.sling.discovery.oak.OakDiscoveryService.updatedPropertyProvider(OakDiscoveryService.java:428)
 [org.apache.sling.discovery.oak:1.2.32]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native 
Method)
at 
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at 
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at 
org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:244)
 [org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41)
 [org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:685)
 [org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.inject.methods.BaseMethod$NotResolved.invoke(BaseMethod.java:639)
 [org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:529) 
[org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.inject.methods.BindMethod.invoke(BindMethod.java:42) 
[org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.manager.DependencyManager.invokeUpdatedMethod(DependencyManager.java:2135)
 [org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.manager.SingleComponentManager.invokeUpdatedMethod(SingleComponentManager.java:454)
 [org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:374)
 [org.apache.felix.scr:2.1.26]
at 
org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:301)
 

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

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10163.


> 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] [Closed] (SLING-10242) Register web console plugin using DS

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10242.


> Register web console plugin using DS
> 
>
> Key: SLING-10242
> URL: https://issues.apache.org/jira/browse/SLING-10242
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
>
> The web console plugin is currently registered as part of the 
> SlingAuthenticator activation. Service registrations should be avoided during 
> activation and its better to let DS do the work



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


[jira] [Closed] (SLING-10267) Authentication requirements from SlingAuthenticator config registered twice

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10267.


> Authentication requirements from SlingAuthenticator config registered twice
> ---
>
> Key: SLING-10267
> URL: https://issues.apache.org/jira/browse/SLING-10267
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Affects Versions: Auth Core 1.5.0
>Reporter: Julian Sedding
>Assignee: Carsten Ziegeler
>Priority: Minor
> Fix For: Auth Core 1.5.2
>
>
> I debugged in the {{SlingAuthenticator}} recently and noticed that all 
> {{sling.auth.requirements}} configured for the {{SlingAuthenticator}} are 
> internally registered twice. This is because they get registered once 
> explicitly from the configuration and then again via the {{ServiceListener}} 
> that evaluates the {{sling.auth.requirements}} from any service.
> I think this causes no harm except for a very minor performance overhead when 
> scanning throug all authentication requirements.
> Note: the effect can also be observed in the web console, where entries 
> configured on the {{SlingAuthenticator}} are listed twice.
> cc [~cziegeler] as you have been working on auth core recently. Looking at 
> the latest code, I believe this issue survived your refactoring.



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


[jira] [Closed] (SLING-10249) Remove unused cacheControl from SlingAuthenticator

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10249.


> Remove unused cacheControl from SlingAuthenticator
> --
>
> Key: SLING-10249
> URL: https://issues.apache.org/jira/browse/SLING-10249
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
>
> SlingAuthenticator currently has a boolean cacheControl member which is never 
> set to true. It seems this has been like this from the beginning. Therefore 
> we can safely remove it



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


[jira] [Closed] (SLING-10248) Refactor: Move auth requirements handling into separate component

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10248.


> Refactor: Move auth requirements handling into separate component
> -
>
> Key: SLING-10248
> URL: https://issues.apache.org/jira/browse/SLING-10248
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
>
> The handling of auth requirements is currently split across three classes, 
> the cache (path based holder), Sling Authenticator (for configuration) and 
> SlingAuthenticatorServiceListener (service registrations)
> We should refactor this into a single class - to make the code cleaner but 
> also easier testable



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


[jira] [Closed] (SLING-10255) Refactor: Move auth handlers management into separate component

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10255.


> Refactor: Move auth handlers management into separate component
> ---
>
> Key: SLING-10255
> URL: https://issues.apache.org/jira/browse/SLING-10255
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
>
> The handling of auth handlers is currently split across two classes, the 
> cache (path based holder) and Sling Authenticator (for configuration)
> We should refactor this into a single component - to make the code cleaner 
> but also easier testable



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


[jira] [Closed] (SLING-10293) Sudo cookie - set httpOnly and secure

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10293.


> Sudo cookie - set httpOnly and secure
> -
>
> Key: SLING-10293
> URL: https://issues.apache.org/jira/browse/SLING-10293
> Project: Sling
>  Issue Type: Improvement
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
>
> The sudo cookie is currently set without making it httpOnly or setting the 
> secure flag



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


[jira] [Closed] (SLING-10164) Add basic metrics to SlingAuthenticator

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10164.


> Add basic metrics to SlingAuthenticator
> ---
>
> Key: SLING-10164
> URL: https://issues.apache.org/jira/browse/SLING-10164
> Project: Sling
>  Issue Type: New Feature
>  Components: Authentication
>Reporter: Angela Schreiber
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
> Attachments: SLING-10164.patch
>
>  Time Spent: 4h 20m
>  Remaining Estimate: 0h
>
> IMHO it would be good to capture some basic metrics in {{SlingAuthenticator}} 
> that allow to monitor overall login performance and success/failures.



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


[jira] [Closed] (SLING-10241) Refactor service trackers to service references in SlingAuthenticator

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10241.


> Refactor service trackers to service references in SlingAuthenticator
> -
>
> Key: SLING-10241
> URL: https://issues.apache.org/jira/browse/SLING-10241
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
>
> SlingAuthenticator is using (old style) service trackers for some references. 
> This was required before newer features like constructor injection where 
> added to Declarative Services.
> This can now be cleaned up to let DS do all the tracking of references, 
> simplifying the code in SlingAuthenticator



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


[jira] [Closed] (SLING-10162) Fix javadoc in sling.auth.core

2021-04-21 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler closed SLING-10162.


> Fix javadoc in sling.auth.core
> --
>
> Key: SLING-10162
> URL: https://issues.apache.org/jira/browse/SLING-10162
> Project: Sling
>  Issue Type: Improvement
>  Components: Authentication
>Reporter: Angela Schreiber
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: Auth Core 1.5.2
>
>
> executing mvn javadoc:javadoc for sling.auth.core fails with java 11 and logs 
> warnings with java 8.
> i also noticed a bunch of broken javadoc links in 
> {{org.apache.sling.auth.core.impl.SlingAuthenticator}}.



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


[VOTE RESULT] Release Apache Sling Auth Core 1.5.2

2021-04-21 Thread Carsten Ziegeler
The vote passes with four binding +1 votes. A non binding -1 vote is 
disregarded as it didn't provide blocking technical reasons.


I've also updated the readme for the bundle that new dependencies are 
needed to be installed.


Regards
Carsten
--
Carsten Ziegeler
Adobe Research Switzerland
cziege...@apache.org


Re: [VOTE] Release Apache Sling Oak-Based Discovery Service 1.2.32

2021-04-21 Thread Robert Munteanu
On Wed, 2021-04-21 at 11:19 +0200, Stefan Egli wrote:
> Please vote to approve this release:

+1
Robert



signature.asc
Description: This is a digitally signed message part


Re: Sling Declarative Dynamic Resources

2021-04-21 Thread Ruben Reusser

Dan,

I am in favor of adding the features from ddr to sling-superimposing - 
is that ok for others too?


Ruben

On 4/20/2021 4:14 PM, Daniel Klco wrote:

IMO the biggest difference is how this defines the root of the dynamic
resources, e.g. via creating a resource at that path or providing a
configuration with the source and target. This alone is a major advantage
as it means that ddr configurations can be defined at runtime with a
composite store.

The problem I see here is that we are trying to solve the same problem
multiple ways.

My take on the problem is:

As a developer or superuser, I want to be able to present a virtual tree of
resources generated from a tree of resources and a configuration tree.

Resource merger solves this problem by anchoring a root and then defining
source paths which can be overlayed and configured in order. This works
well in the case where you have only two trees and you want to present a
merged copy of these two trees, but does not work for arbitrary anchor
points.

Superimposing supports creating arbitrary roots but these roots can only be
tied to one source. It also only allows overriding the overlayed resouces
by using a lower level api (such as JCR) because the sling post servlet
will update the source resources.

Generally, I think it's better to have fewer ways of doing the same thing,
do it makes sense to consolidate if possible. Given that resouces merger is
widely used, I can't see how it would be worth the effort to regression
check potential breaking issues. However, given that SuperImposing has not
been significantly updated in years, I would recommend that we:

1. Update SuperImposing to work on Java 11 / OSGi 6 / Sling 12
2. Update SuperImposing to support defining virtual trees by source and
source+target and other DDR features
3. Define a feature model to install the bundle and create an oak index for
the mixin
4. Release this as the 1.0 version of SuperImposing

I've already taken a run at updating SuperImposing and am ~75% there.

What do others think?

-Dan

On Tue, Apr 20, 2021, 5:34 PM Andreas Schaefer 
wrote:


Here is a short recap after trying to compare Superimposing Resource (SIR)
and the Declarative Dynamice Resource (DDR). They are similar in some
respect and different in others:

Feature SIR DDR

Resource Resolver type  Admin RRService RR
Linking fromTarget  Source
Mixin   Supported   Not
Supported
Resource ChangesSupported   Supported
Property ChangesNot Supported   Supported
Configure Parent by
1st Level Child Supported   Not Supported
OverlaysSupported
  Not Supported
2nd Level Redirection   Not Supported   Supported
Filtering (Security)Not Supported   Supported
Java 11 Not Supported   Supported
Sling 12Not Supported
  Supported

Cheers - Andy


On Apr 20, 2021, at 6:13 AM, Stefan Seifert 

wrote:

hello ruben.

use case sounds a bit similar to

https://github.com/apache/sling-org-apache-sling-superimposing (a bit

outdated)

and
https://github.com/apache/sling-org-apache-sling-resourcemerger

can you differentiate what DDR does differently?

stefan


-Original Message-
From: Ruben Reusser 
Sent: Tuesday, April 20, 2021 1:54 PM
To: dev@sling.apache.org
Subject: Re: Sling Declarative Dynamic Resources

totally forgot to add the link to the code base - sorry



https://github.com/apache/sling-whiteboard/tree/master/org.apache.sling.ddr

On 4/19/2021 10:29 AM, Ruben Reusser wrote:

dear sling community

Andreas has been working to create a way to dynamically create
component proxies in Sling based on a configuration. In peregrine-cms
we are planning to use this approach when a new tenant (a new website)
is created by a user. It allows us to proxy the base components into a
new /apps folder for the website. A super user for the site can then
potentially change the title/group of a component and the default
structure that is used when adding a component to a page.

We hope this component may be useful to other sling based content
management systems as well. We'd like to ask to move this module out
of the whiteboard - but of course we welcome any
comments/concerns/things we should consider to make sure everybody can
benefit from this module.

looking forward to your comments!

Ruben




Re: Sling Declarative Dynamic Resources

2021-04-21 Thread Ruben Reusser

Bertrand, Carsten,

On 4/20/2021 10:57 PM, Carsten Ziegeler wrote:
I totally agree that we should try to avoid overlapping solutions and 
as mentioned superimposing and ddr sound pretty similar.


I understand the use cases on a higher level. However - similar to 
Bertrand - I'm a little bit worried. The readme for ddr talks about 
circumventing an immutable repository. If its possible to basically 
make immutable parts mutable, then this is entering dangerous territory.


I understand your concern - that is one of the reasons why we made sure 
we allow blocking of resource types in ddr.


we tried to outline our usecase we need to solve:

- for each website that is created we have to create a corresponding 
/apps folder for rendering purposes
- we also want to give editors a certain control over group names, 
labels and the component variations an editor can pick from when 
creating a page


would love to hear if there is a better alternative for this


Regards
Carsten





Re: [VOTE] Release Apache Sling Oak-Based Discovery Service 1.2.32

2021-04-21 Thread Carsten Ziegeler

+1

Carsten

Am 21.04.2021 um 11:19 schrieb Stefan Egli:

Hi,

We solved 3 issues in this release:
https://issues.apache.org/jira/projects/SLING/versions/12348159

Staging repository:
https://repository.apache.org/content/repositories/orgapachesling-2432/

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 2432 /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.

Cheers,
Stefan


--
--
Carsten Ziegeler
Adobe Research Switzerland
cziege...@apache.org


[GitHub] [sling-org-apache-sling-feature-cpconverter] sonarcloud[bot] commented on pull request #74: SLING-10243 extract Sling-Initial-Content

2021-04-21 Thread GitBox


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


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=SECURITY_HOTSPOT)
 [2 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=CODE_SMELL)
 [8 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_coverage=list)
 [60.2% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_coverage=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_duplicated_lines_density=list)
 [4.2% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_duplicated_lines_density=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 #74: SLING-10243 extract Sling-Initial-Content

2021-04-21 Thread GitBox


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


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=SECURITY_HOTSPOT)
 [2 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=CODE_SMELL)
 [7 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-feature-cpconverter=74=false=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_coverage=list)
 [60.7% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_coverage=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_duplicated_lines_density=list)
 [4.2% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-feature-cpconverter=74=new_duplicated_lines_density=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-servlets-resolver] sonarcloud[bot] commented on pull request #7: [SLING-9230] - Servlet should not be allowed to register with invalid…

2021-04-21 Thread GitBox


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


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver=7=false=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver=7=false=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver=7=false=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_coverage=list)
 [70.0% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_coverage=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_duplicated_lines_density=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_duplicated_lines_density=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-servlets-resolver] sonarcloud[bot] removed a comment on pull request #7: [SLING-9230] - Servlet should not be allowed to register with invalid…

2021-04-21 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-821210076


   SonarCloud Quality Gate failed.
   
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=BUG)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=BUG)
 [0 
Bugs](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=BUG)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=VULNERABILITY)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=VULNERABILITY)
 [0 
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=VULNERABILITY)
  
   [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver=7=false=SECURITY_HOTSPOT)
 [](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver=7=false=SECURITY_HOTSPOT)
 [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_sling-org-apache-sling-servlets-resolver=7=false=SECURITY_HOTSPOT)
  
   [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=CODE_SMELL)
 [](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=CODE_SMELL)
 [0 Code 
Smells](https://sonarcloud.io/project/issues?id=apache_sling-org-apache-sling-servlets-resolver=7=false=CODE_SMELL)
   
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_coverage=list)
 [70.0% 
Coverage](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_coverage=list)
  
   [](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_duplicated_lines_density=list)
 [0.0% 
Duplication](https://sonarcloud.io/component_measures?id=apache_sling-org-apache-sling-servlets-resolver=7=new_duplicated_lines_density=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] [Resolved] (SLING-10325) Update m-release-p to 3.0.0-M4

2021-04-21 Thread Konrad Windszus (Jira)


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

Konrad Windszus resolved SLING-10325.
-
Resolution: Fixed

Fixed in 
https://github.com/apache/sling-parent/commit/17279333c961809c0e15340ca2f2d492a3b45890.

> Update m-release-p to 3.0.0-M4
> --
>
> Key: SLING-10325
> URL: https://issues.apache.org/jira/browse/SLING-10325
> Project: Sling
>  Issue Type: Improvement
>  Components: General
>Reporter: Konrad Windszus
>Assignee: Konrad Windszus
>Priority: Major
> Fix For: Parent 42
>
>




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


[jira] [Created] (SLING-10325) Update m-release-p to 3.0.0-M4

2021-04-21 Thread Konrad Windszus (Jira)
Konrad Windszus created SLING-10325:
---

 Summary: Update m-release-p to 3.0.0-M4
 Key: SLING-10325
 URL: https://issues.apache.org/jira/browse/SLING-10325
 Project: Sling
  Issue Type: Improvement
  Components: General
Reporter: Konrad Windszus
Assignee: Konrad Windszus
 Fix For: Parent 42






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


[jira] [Resolved] (SLING-10199) Manage dependency version of org.osgi.util.tracker

2021-04-21 Thread Konrad Windszus (Jira)


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

Konrad Windszus resolved SLING-10199.
-
Resolution: Fixed

Fixed in 
https://github.com/apache/sling-parent/commit/74934bf09afff8609a49e8ef71fa68ebf9d522ad.

> Manage dependency version of org.osgi.util.tracker
> --
>
> Key: SLING-10199
> URL: https://issues.apache.org/jira/browse/SLING-10199
> Project: Sling
>  Issue Type: Improvement
>  Components: General
>Reporter: Konrad Windszus
>Assignee: Konrad Windszus
>Priority: Major
> Fix For: Bundle Parent 42
>
>
> The dependency 
> {code}
> 
> org.osgi
> org.osgi.util.tracker
> 1.5.2
> 
> {code}
> should be managed in sling-bundle-parent as well. Version 1.5.2 is part of 
> OSGi Core R7.



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


[jira] [Updated] (SLING-10199) Manage dependency version of org.osgi.util.tracker

2021-04-21 Thread Konrad Windszus (Jira)


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

Konrad Windszus updated SLING-10199:

Description: 
The dependency 

{code}

org.osgi
org.osgi.util.tracker
1.5.2

{code}

should be managed in sling-bundle-parent as well. Version 1.5.2 is part of OSGi 
Core R7.

  was:
The dependency 

{code}

org.osgi
org.osgi.util.tracker
1.5.3

{code}

should be managed in sling-bundle-parent as well. Version 1.5 is part of OSGi 
Core since R5 and still the current version.


> Manage dependency version of org.osgi.util.tracker
> --
>
> Key: SLING-10199
> URL: https://issues.apache.org/jira/browse/SLING-10199
> Project: Sling
>  Issue Type: Improvement
>  Components: General
>Reporter: Konrad Windszus
>Assignee: Konrad Windszus
>Priority: Major
> Fix For: Bundle Parent 42
>
>
> The dependency 
> {code}
> 
> org.osgi
> org.osgi.util.tracker
> 1.5.2
> 
> {code}
> should be managed in sling-bundle-parent as well. Version 1.5.2 is part of 
> OSGi Core R7.



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


[GitHub] [sling-site] anchela commented on a change in pull request #58: SLING-10324 : ServiceUserMapper documentation is incomplete

2021-04-21 Thread GitBox


anchela commented on a change in pull request #58:
URL: https://github.com/apache/sling-site/pull/58#discussion_r617433652



##
File path: 
src/main/jbake/content/documentation/the-sling-engine/service-authentication.md
##
@@ -100,15 +100,23 @@ described above consists of three parts:
 The first part is a new OSGi Service `ServiceUserMapper`. The
 `ServiceUserMapper` service allows for mapping *Service IDs* comprised of
 the *Service Names* defined by the providing bundles and optional *Subservice 
Name*
-to ResourceResolver and/or JCR Repository user IDs or principals 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). This mapping 
is configurable
+to ResourceResolver and/or JCR Repository principal names 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)) or 
+user IDs ([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). 
This mapping is configurable
 such that system administrators are in full control of assigning users to 
services.
 
 The `ServiceUserMapper` defines the following API:
 
 #!java
+Iterable getServicePrincipalNames(Bundle bundle, String 
subServiceName);
+ 
+The alternative API (getting service user ID as shown below) has been 
deprecated for security reasons and will be removed
+in future releases. See 
[SLING-6939](https://issues.apache.org/jira/browse/SLING-6963) for details.

Review comment:
   @kwin , well... that's an old mistake introduced with 
https://github.com/apache/sling-site/commit/4db71dd9b92d7c56aaebddee26202974dc4e86d5#diff-737db1251927d7f9c7361f9ef26e2e32ec5b3d10625b5a7552d3889df6503a0c
 :-) but i can fix it as well...




-- 
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-site] anchela commented on a change in pull request #58: SLING-10324 : ServiceUserMapper documentation is incomplete

2021-04-21 Thread GitBox


anchela commented on a change in pull request #58:
URL: https://github.com/apache/sling-site/pull/58#discussion_r617433652



##
File path: 
src/main/jbake/content/documentation/the-sling-engine/service-authentication.md
##
@@ -100,15 +100,23 @@ described above consists of three parts:
 The first part is a new OSGi Service `ServiceUserMapper`. The
 `ServiceUserMapper` service allows for mapping *Service IDs* comprised of
 the *Service Names* defined by the providing bundles and optional *Subservice 
Name*
-to ResourceResolver and/or JCR Repository user IDs or principals 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). This mapping 
is configurable
+to ResourceResolver and/or JCR Repository principal names 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)) or 
+user IDs ([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). 
This mapping is configurable
 such that system administrators are in full control of assigning users to 
services.
 
 The `ServiceUserMapper` defines the following API:
 
 #!java
+Iterable getServicePrincipalNames(Bundle bundle, String 
subServiceName);
+ 
+The alternative API (getting service user ID as shown below) has been 
deprecated for security reasons and will be removed
+in future releases. See 
[SLING-6939](https://issues.apache.org/jira/browse/SLING-6963) for details.

Review comment:
   @kwin , well... that's an old mistake :-) but i can fix it as well...




-- 
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-10265) JUNIT5 Test cases are failing when I use code "new AemContext(ResourceResolverType.JCR_OAK)"

2021-04-21 Thread Csaba Varga (Jira)


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

Csaba Varga commented on SLING-10265:
-

I'm not a Sling developer, but I've run into the exact same issue this week. In 
my case, it was caused by two incompatible sets of Sling API classes being on 
the classpath. One was included via Sling Mocks, the other was embedded into 
the AEM SDK API JAR.

I could fix my issue by explicitly including org.apache.sling.api as a 
dependency before Sling Mocks and specifying a more recent version than what 
Sling Mocks would have pulled. This more recent version, while still 
technically a duplicate, played nicely with the classes coming from the AEM SDK.

I hope this helps.

> JUNIT5 Test cases are failing when I use code "new 
> AemContext(ResourceResolverType.JCR_OAK)"
> 
>
> Key: SLING-10265
> URL: https://issues.apache.org/jira/browse/SLING-10265
> Project: Sling
>  Issue Type: Bug
>  Components: Apache Sling Testing Clients
>Affects Versions: Testing Sling Mock 2.6.0
>Reporter: subramanya
>Priority: Blocker
>
> I am unable to run test cases using JUNIT5 with JCR_OAK repository 
> implementation in the test case code .
> Repository using JCR_MOCK works, the snippet below works
> private final AemContext aemContext = new 
> AemContext(ResourceResolverType.JCR_MOCK);   
> Where as this one throws exception:
> private final AemContext aemContext = new 
> AemContext(ResourceResolverType.JCR_OAK);   
> This is the error I am getting 
> java.lang.RuntimeException: Unable to initialize JCR_OAK resource resolver 
> factory: Unable to invoke method 'activate' for class 
> org.apache.sling.testing.mock.sling.oak.OakMockSlingRepository Caused by: 
> java.lang.NoSuchMethodError: 
> org.apache.jackrabbit.oak.plugins.nodetype.constraint.Constraints.asPredicate(ILjava/lang/String;)Ljava/util/function/Predicate;
>   summary JUNIT5 Test cases are failing when I use new 
> AemContext(ResourceResolverType.JCR_OAK)



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


[GitHub] [sling-site] kwin commented on a change in pull request #58: SLING-10324 : ServiceUserMapper documentation is incomplete

2021-04-21 Thread GitBox


kwin commented on a change in pull request #58:
URL: https://github.com/apache/sling-site/pull/58#discussion_r617418426



##
File path: 
src/main/jbake/content/documentation/the-sling-engine/service-authentication.md
##
@@ -100,15 +100,23 @@ described above consists of three parts:
 The first part is a new OSGi Service `ServiceUserMapper`. The
 `ServiceUserMapper` service allows for mapping *Service IDs* comprised of
 the *Service Names* defined by the providing bundles and optional *Subservice 
Name*
-to ResourceResolver and/or JCR Repository user IDs or principals 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). This mapping 
is configurable
+to ResourceResolver and/or JCR Repository principal names 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)) or 
+user IDs ([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). 
This mapping is configurable
 such that system administrators are in full control of assigning users to 
services.
 
 The `ServiceUserMapper` defines the following API:
 
 #!java
+Iterable getServicePrincipalNames(Bundle bundle, String 
subServiceName);
+ 
+The alternative API (getting service user ID as shown below) has been 
deprecated for security reasons and will be removed
+in future releases. See 
[SLING-6939](https://issues.apache.org/jira/browse/SLING-6963) for details.

Review comment:
   Still the other link title says `SLING-6939` while the link actually 
points to `https://issues.apache.org/jira/browse/SLING-6963`




-- 
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-site] anchela commented on a change in pull request #58: SLING-10324 : ServiceUserMapper documentation is incomplete

2021-04-21 Thread GitBox


anchela commented on a change in pull request #58:
URL: https://github.com/apache/sling-site/pull/58#discussion_r617402384



##
File path: 
src/main/jbake/content/documentation/the-sling-engine/service-authentication.md
##
@@ -100,15 +100,23 @@ described above consists of three parts:
 The first part is a new OSGi Service `ServiceUserMapper`. The
 `ServiceUserMapper` service allows for mapping *Service IDs* comprised of
 the *Service Names* defined by the providing bundles and optional *Subservice 
Name*
-to ResourceResolver and/or JCR Repository user IDs or principals 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). This mapping 
is configurable
+to ResourceResolver and/or JCR Repository principal names 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)) or 
+user IDs ([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). 
This mapping is configurable
 such that system administrators are in full control of assigning users to 
services.
 
 The `ServiceUserMapper` defines the following API:
 
 #!java
+Iterable getServicePrincipalNames(Bundle bundle, String 
subServiceName);
+ 
+The alternative API (getting service user ID as shown below) has been 
deprecated for security reasons and will be removed
+in future releases. See 
[SLING-6939](https://issues.apache.org/jira/browse/SLING-6963) for details.

Review comment:
   oh thanks for spotting... that's obviously an oversight. the 
deprecation is covered with SLING-10321. i will fix it.




-- 
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-site] kwin commented on a change in pull request #58: SLING-10324 : ServiceUserMapper documentation is incomplete

2021-04-21 Thread GitBox


kwin commented on a change in pull request #58:
URL: https://github.com/apache/sling-site/pull/58#discussion_r617396056



##
File path: 
src/main/jbake/content/documentation/the-sling-engine/service-authentication.md
##
@@ -100,15 +100,23 @@ described above consists of three parts:
 The first part is a new OSGi Service `ServiceUserMapper`. The
 `ServiceUserMapper` service allows for mapping *Service IDs* comprised of
 the *Service Names* defined by the providing bundles and optional *Subservice 
Name*
-to ResourceResolver and/or JCR Repository user IDs or principals 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). This mapping 
is configurable
+to ResourceResolver and/or JCR Repository principal names 
([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)) or 
+user IDs ([SLING-6939](https://issues.apache.org/jira/browse/SLING-6963)). 
This mapping is configurable
 such that system administrators are in full control of assigning users to 
services.
 
 The `ServiceUserMapper` defines the following API:
 
 #!java
+Iterable getServicePrincipalNames(Bundle bundle, String 
subServiceName);
+ 
+The alternative API (getting service user ID as shown below) has been 
deprecated for security reasons and will be removed
+in future releases. See 
[SLING-6939](https://issues.apache.org/jira/browse/SLING-6963) for details.

Review comment:
   6939 and link points to 6963. Which ticket tracks the deprecation? 
https://issues.apache.org/jira/browse/SLING-6963 is only about the introduction 
of the new API.




-- 
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-site] anchela opened a new pull request #58: SLING-10324 : ServiceUserMapper documentation is incomplete

2021-04-21 Thread GitBox


anchela opened a new pull request #58:
URL: https://github.com/apache/sling-site/pull/58


   (+ referring to API deprecation with SLING-10321)


-- 
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




[VOTE] Release Apache Sling Oak-Based Discovery Service 1.2.32

2021-04-21 Thread Stefan Egli

Hi,

We solved 3 issues in this release:
https://issues.apache.org/jira/projects/SLING/versions/12348159

Staging repository:
https://repository.apache.org/content/repositories/orgapachesling-2432/

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 2432 /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.

Cheers,
Stefan


[jira] [Updated] (SLING-9625) DiscoveryServiceImpl#doUpdateProperties may fail due to a LoginException

2021-04-21 Thread Stefan Egli (Jira)


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

Stefan Egli updated SLING-9625:
---
Fix Version/s: (was: Discovery Oak 1.2.32)
   Discovery Oak 1.2.34

> DiscoveryServiceImpl#doUpdateProperties may fail due to a LoginException 
> -
>
> Key: SLING-9625
> URL: https://issues.apache.org/jira/browse/SLING-9625
> Project: Sling
>  Issue Type: Improvement
>Affects Versions: Discovery Oak 1.2.30
>Reporter: Konrad Windszus
>Priority: Major
> Fix For: Discovery Oak 1.2.34
>
>
> While stopping the OSGi container (Sling Starter 12 SNAPSHOT) I observed the 
> following error
> {code}
> 03.08.2020 10:30:06.262 *INFO * [Apache Sling Terminator] Stopping Apache 
> Sling
> ERROR: bundle org.apache.sling.discovery.oak:1.2.28 
> (139)[org.apache.sling.discovery.oak.OakDiscoveryService(200)] : The 
> updatedPropertyProvider method has thrown an exception
> java.lang.RuntimeException: Could not log in to repository 
> (org.apache.sling.api.resource.LoginException: Cannot derive user name for 
> bundle org.apache.sling.discovery.oak [139] and sub service null)
>   at 
> org.apache.sling.discovery.oak.OakDiscoveryService.doUpdateProperties(OakDiscoveryService.java:540)
>   at 
> org.apache.sling.discovery.oak.OakDiscoveryService.bindPropertyProviderInteral(OakDiscoveryService.java:406)
>   at 
> org.apache.sling.discovery.oak.OakDiscoveryService.updatedPropertyProvider(OakDiscoveryService.java:421)
>   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:498)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:242)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:678)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod$NotResolved.invoke(BaseMethod.java:633)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:524)
>   at 
> org.apache.felix.scr.impl.inject.methods.BindMethod.invoke(BindMethod.java:42)
>   at 
> org.apache.felix.scr.impl.manager.DependencyManager.invokeUpdatedMethod(DependencyManager.java:1934)
>   at 
> org.apache.felix.scr.impl.manager.SingleComponentManager.invokeUpdatedMethod(SingleComponentManager.java:448)
>   at 
> org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:366)
>   at 
> org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:297)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerModified(ServiceTracker.java:1229)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerModified(ServiceTracker.java:1137)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:883)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:1168)
>   at 
> org.apache.felix.scr.impl.BundleComponentActivator$ListenerInfo.serviceChanged(BundleComponentActivator.java:125)
>   at 
> org.apache.felix.framework.EventDispatcher.invokeServiceListenerCallback(EventDispatcher.java:990)
>   at 
> org.apache.felix.framework.EventDispatcher.fireEventImmediately(EventDispatcher.java:838)
>   at 
> org.apache.felix.framework.EventDispatcher.fireServiceEvent(EventDispatcher.java:545)
>   at org.apache.felix.framework.Felix.fireServiceEvent(Felix.java:4833)
>   at org.apache.felix.framework.Felix.access$000(Felix.java:112)
>   at org.apache.felix.framework.Felix$1.serviceChanged(Felix.java:434)
>   at 
> org.apache.felix.framework.ServiceRegistry.servicePropertiesModified(ServiceRegistry.java:601)
>   at 
> org.apache.felix.framework.ServiceRegistrationImpl.setProperties(ServiceRegistrationImpl.java:132)
>   at 
> org.apache.sling.event.impl.jobs.JobConsumerManager.unbindService(JobConsumerManager.java:354)
>   at 
> org.apache.sling.event.impl.jobs.JobConsumerManager.unbindJobExecutor(JobConsumerManager.java:270)
>   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at 

[jira] [Updated] (SLING-5598) Exclude slow tests by default with assume(sling.slow.tests.enabled)

2021-04-21 Thread Stefan Egli (Jira)


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

Stefan Egli updated SLING-5598:
---
Fix Version/s: (was: Discovery Oak 1.2.32)
   Discovery Oak 1.2.34

> Exclude slow tests by default with assume(sling.slow.tests.enabled) 
> 
>
> Key: SLING-5598
> URL: https://issues.apache.org/jira/browse/SLING-5598
> Project: Sling
>  Issue Type: Task
>  Components: Extensions
>Affects Versions: Discovery Impl 1.2.6, Discovery Base 1.1.2, Discovery 
> Commons 1.0.10, Discovery Oak 1.2.6
>Reporter: Stefan Egli
>Priority: Major
> Fix For: Discovery Commons 1.0.24, Discovery Impl 1.2.14, 
> Discovery Base 2.0.10, Discovery Oak 1.2.34
>
> Attachments: SLING-5598-commons-testing.patch, 
> SLING-5598-discovery.patch
>
>
> As suggested by [~bdelacretaz] on [the 
> list|http://markmail.org/message/yad5awqg53epk3ck] we should improve test 
> duration (ideally 1-2min per bundle max, 10-15min overall). While they are 
> not yet improved however, slow tests should be excluded by default and run 
> only if enabled explicitly. Here's an example {{@Before}} method to achieve 
> that:
> {noformat}
> @Before
> public void checkSlowTests() {
> assumeNotNull(System.getProperty("sling.slow.tests.enabled"));
> }
> {noformat}
> and to enable the slow tests you do: {{mvn -Dsling.slow.tests.enabled=true 
> clean test}}



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


[jira] [Commented] (SLING-9625) DiscoveryServiceImpl#doUpdateProperties may fail due to a LoginException

2021-04-21 Thread Stefan Egli (Jira)


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

Stefan Egli commented on SLING-9625:


Note that this exception itself is now at least caught properly with the 
SLING-10204 fix.

What's remaining to look into is the suggested dependency on ServiceUserMapped. 
Leaving ticket open therefore for now.

> DiscoveryServiceImpl#doUpdateProperties may fail due to a LoginException 
> -
>
> Key: SLING-9625
> URL: https://issues.apache.org/jira/browse/SLING-9625
> Project: Sling
>  Issue Type: Improvement
>Affects Versions: Discovery Oak 1.2.30
>Reporter: Konrad Windszus
>Priority: Major
> Fix For: Discovery Oak 1.2.32
>
>
> While stopping the OSGi container (Sling Starter 12 SNAPSHOT) I observed the 
> following error
> {code}
> 03.08.2020 10:30:06.262 *INFO * [Apache Sling Terminator] Stopping Apache 
> Sling
> ERROR: bundle org.apache.sling.discovery.oak:1.2.28 
> (139)[org.apache.sling.discovery.oak.OakDiscoveryService(200)] : The 
> updatedPropertyProvider method has thrown an exception
> java.lang.RuntimeException: Could not log in to repository 
> (org.apache.sling.api.resource.LoginException: Cannot derive user name for 
> bundle org.apache.sling.discovery.oak [139] and sub service null)
>   at 
> org.apache.sling.discovery.oak.OakDiscoveryService.doUpdateProperties(OakDiscoveryService.java:540)
>   at 
> org.apache.sling.discovery.oak.OakDiscoveryService.bindPropertyProviderInteral(OakDiscoveryService.java:406)
>   at 
> org.apache.sling.discovery.oak.OakDiscoveryService.updatedPropertyProvider(OakDiscoveryService.java:421)
>   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:498)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:242)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:678)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod$NotResolved.invoke(BaseMethod.java:633)
>   at 
> org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:524)
>   at 
> org.apache.felix.scr.impl.inject.methods.BindMethod.invoke(BindMethod.java:42)
>   at 
> org.apache.felix.scr.impl.manager.DependencyManager.invokeUpdatedMethod(DependencyManager.java:1934)
>   at 
> org.apache.felix.scr.impl.manager.SingleComponentManager.invokeUpdatedMethod(SingleComponentManager.java:448)
>   at 
> org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:366)
>   at 
> org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.modifiedService(DependencyManager.java:297)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerModified(ServiceTracker.java:1229)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerModified(ServiceTracker.java:1137)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:883)
>   at 
> org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:1168)
>   at 
> org.apache.felix.scr.impl.BundleComponentActivator$ListenerInfo.serviceChanged(BundleComponentActivator.java:125)
>   at 
> org.apache.felix.framework.EventDispatcher.invokeServiceListenerCallback(EventDispatcher.java:990)
>   at 
> org.apache.felix.framework.EventDispatcher.fireEventImmediately(EventDispatcher.java:838)
>   at 
> org.apache.felix.framework.EventDispatcher.fireServiceEvent(EventDispatcher.java:545)
>   at org.apache.felix.framework.Felix.fireServiceEvent(Felix.java:4833)
>   at org.apache.felix.framework.Felix.access$000(Felix.java:112)
>   at org.apache.felix.framework.Felix$1.serviceChanged(Felix.java:434)
>   at 
> org.apache.felix.framework.ServiceRegistry.servicePropertiesModified(ServiceRegistry.java:601)
>   at 
> org.apache.felix.framework.ServiceRegistrationImpl.setProperties(ServiceRegistrationImpl.java:132)
>   at 
> org.apache.sling.event.impl.jobs.JobConsumerManager.unbindService(JobConsumerManager.java:354)
>   at 
> org.apache.sling.event.impl.jobs.JobConsumerManager.unbindJobExecutor(JobConsumerManager.java:270)
>   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> 

[jira] [Resolved] (SLING-10321) Deprecate service mapping by userID

2021-04-21 Thread Angela Schreiber (Jira)


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

Angela Schreiber resolved SLING-10321.
--
Resolution: Fixed

> Deprecate service mapping by userID
> ---
>
> Key: SLING-10321
> URL: https://issues.apache.org/jira/browse/SLING-10321
> Project: Sling
>  Issue Type: Improvement
>  Components: Service User Mapper
>Affects Versions: Service User Mapper 1.5.2
>Reporter: Angela Schreiber
>Assignee: Angela Schreiber
>Priority: Major
> Fix For: Service User Mapper 1.5.4
>
>  Time Spent: 40m
>  Remaining Estimate: 0h
>
> [~cziegeler], [~kpauls], for security reasons I would like to deprecate the 
> old service user mapping by a single userID in favor of the new format that 
> takes one or multiple principal names.
> The new format allows to keep service permissions limited to service-users as 
> declared in the mapping and doesn't resolve declare or inherited group 
> permissions. This gives full control over the effective permissions granted 
> to each service and doesn't risk unrelated permission changes (e.g. to a base 
> group like 'everyone') impacting service security.



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


[GitHub] [sling-org-apache-sling-serviceusermapper] anchela merged pull request #5: SLING-10321 : Deprecate service mapping by userID

2021-04-21 Thread GitBox


anchela merged pull request #5:
URL: https://github.com/apache/sling-org-apache-sling-serviceusermapper/pull/5


   


-- 
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] [Updated] (SLING-10324) ServiceUserMapper documentation is incomplete

2021-04-21 Thread Angela Schreiber (Jira)


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

Angela Schreiber updated SLING-10324:
-
Description: for SLING-10321 i was looking for the corresponding 
documentation and found that the description of the {{ServiceUserMapper}} at 
https://sling.apache.org/documentation/the-sling-engine/service-authentication.html#serviceusermapper
 doesn't correctly reflect the current status of the {{ServiceUserMapper}}, 
which first resolves mapping by principal names. In addition it doesn't 
describe the validator interfaces and their effect.  (was: for SLING-10321 i 
was looking for the corresponding documentation and found that the description 
of the {{ServiceUserMapper}} at 
https://sling.apache.org/documentation/the-sling-engine/service-authentication.html#serviceusermapper
 doesn't correctly reflect the current status of the {{ServiceUserMapper}}, 
which first resolves mapping by principal names. )

> ServiceUserMapper documentation is incomplete
> -
>
> Key: SLING-10324
> URL: https://issues.apache.org/jira/browse/SLING-10324
> Project: Sling
>  Issue Type: Bug
>  Components: Documentation
>Reporter: Angela Schreiber
>Assignee: Angela Schreiber
>Priority: Major
>
> for SLING-10321 i was looking for the corresponding documentation and found 
> that the description of the {{ServiceUserMapper}} at 
> https://sling.apache.org/documentation/the-sling-engine/service-authentication.html#serviceusermapper
>  doesn't correctly reflect the current status of the {{ServiceUserMapper}}, 
> which first resolves mapping by principal names. In addition it doesn't 
> describe the validator interfaces and their effect.



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


[jira] [Updated] (SLING-10324) ServiceUserMapper documentation is incomplete

2021-04-21 Thread Angela Schreiber (Jira)


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

Angela Schreiber updated SLING-10324:
-
Summary: ServiceUserMapper documentation is incomplete  (was: 
ServiceUserMapper documentation doesn't describe mapping by principal names)

> ServiceUserMapper documentation is incomplete
> -
>
> Key: SLING-10324
> URL: https://issues.apache.org/jira/browse/SLING-10324
> Project: Sling
>  Issue Type: Bug
>  Components: Documentation
>Reporter: Angela Schreiber
>Assignee: Angela Schreiber
>Priority: Major
>
> for SLING-10321 i was looking for the corresponding documentation and found 
> that the description of the {{ServiceUserMapper}} at 
> https://sling.apache.org/documentation/the-sling-engine/service-authentication.html#serviceusermapper
>  doesn't correctly reflect the current status of the {{ServiceUserMapper}}, 
> which first resolves mapping by principal names. 



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


[jira] [Resolved] (SLING-10204) Make OakDiscoveryService.updatedPropertyProvider tolerate deactivated repository

2021-04-21 Thread Stefan Egli (Jira)


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

Stefan Egli resolved SLING-10204.
-
Fix Version/s: Discovery Oak 1.2.32
   Resolution: Fixed

* [PR|https://github.com/apache/sling-org-apache-sling-discovery-oak/pull/2] 
merged, marking issue as resolved
* triggering a new release of discovery.oak next

> Make OakDiscoveryService.updatedPropertyProvider tolerate deactivated 
> repository
> 
>
> Key: SLING-10204
> URL: https://issues.apache.org/jira/browse/SLING-10204
> Project: Sling
>  Issue Type: Task
>  Components: Discovery
>Reporter: Stefan Egli
>Assignee: Stefan Egli
>Priority: Minor
> Fix For: Discovery Oak 1.2.32
>
>  Time Spent: 1h 50m
>  Remaining Estimate: 0h
>
> The following exception has been witnessed during resource resolver factory 
> unregistration:
> {noformat}
> java.lang.IllegalArgumentException: Can't create child on a synthetic root
> at 
> org.apache.sling.resourceresolver.impl.ResourceResolverImpl.create(ResourceResolverImpl.java:979)
>  [org.apache.sling.resourceresolver:1.7.2]
> ...
> at 
> org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:571)
>  [org.apache.sling.api:2.22.0]
> at 
> org.apache.sling.discovery.commons.providers.util.ResourceHelper.getOrCreateResource(ResourceHelper.java:45)
>  [org.apache.sling.discovery.commons:1.0.20]
> at 
> org.apache.sling.discovery.oak.OakDiscoveryService.doUpdateProperties(OakDiscoveryService.java:492)
>  [org.apache.sling.discovery.oak:1.2.30]
> at 
> org.apache.sling.discovery.oak.OakDiscoveryService.bindPropertyProviderInteral(OakDiscoveryService.java:406)
>  [org.apache.sling.discovery.oak:1.2.30]
> at 
> org.apache.sling.discovery.oak.OakDiscoveryService.updatedPropertyProvider(OakDiscoveryService.java:421)
>  [org.apache.sling.discovery.oak:1.2.30]
>   at jdk.internal.reflect.GeneratedMethodAccessor65.invoke(Unknown 
> Source){noformat}
> Under normal circumstances osgi should not invoke any of the 
> updatedPropertyProvider/unbindPropertyProvider methods after the 
> resourceResolverFactory is deactivated - but it has been seen nevertheless.
> What can be done in OakDiscoveryService is to tolerate this and not issue a 
> log.warn instead of throwing an uncaught IllegalArgumentException.
> Edit: more cases with the same root cause:
> {noformat}
> java.lang.Exception: Could not adapt resourceResolver to session: 
> org.apache.sling.resourceresolver.impl.ResourceResolverImpl@3e685b17
>   at 
> org.apache.sling.discovery.commons.providers.spi.base.DiscoveryLiteDescriptor.getDescriptorFrom(DiscoveryLiteDescriptor.java:54)
>  [org.apache.sling.discovery.commons:1.0.20]
>   at 
> org.apache.sling.discovery.oak.cluster.OakClusterViewService.getLocalClusterView(OakClusterViewService.java:113)
>  [org.apache.sling.discovery.oak:1.2.30]
>   at 
> org.apache.sling.discovery.base.commons.BaseDiscoveryService.getTopology(BaseDiscoveryService.java:77)
>  [org.apache.sling.discovery.base:2.0.8]
>   at 
> org.apache.sling.discovery.oak.OakDiscoveryService.checkForTopologyChange(OakDiscoveryService.java:660)
>  [org.apache.sling.discovery.oak:1.2.30]
>   at 
> org.apache.sling.discovery.oak.pinger.OakViewChecker.discoveryLiteCheck(OakViewChecker.java:217)
>  [org.apache.sling.discovery.oak:1.2.30]
>   at 
> org.apache.sling.discovery.oak.pinger.OakViewChecker.access$000(OakViewChecker.java:62)
>  [org.apache.sling.discovery.oak:1.2.30]
>   at 
> org.apache.sling.discovery.oak.pinger.OakViewChecker$1.run(OakViewChecker.java:193)
>  [org.apache.sling.discovery.oak:1.2.30]
>   at 
> org.apache.sling.discovery.base.commons.PeriodicBackgroundJob.safelyRun(PeriodicBackgroundJob.java:86)
>  [org.apache.sling.discovery.base:2.0.8]
>   at 
> org.apache.sling.discovery.base.commons.PeriodicBackgroundJob.run(PeriodicBackgroundJob.java:77)
>  [org.apache.sling.discovery.base:2.0.8]
>   at java.base/java.lang.Thread.run(Thread.java:834)
> {noformat}
> {noformat}
> java.lang.Exception: Could not adapt resourceResolver to session: 
> org.apache.sling.resourceresolver.impl.ResourceResolverImpl@215bf7ef
>   at 
> org.apache.sling.discovery.commons.providers.spi.base.DiscoveryLiteDescriptor.getDescriptorFrom(DiscoveryLiteDescriptor.java:54)
>  [org.apache.sling.discovery.commons:1.0.20]
>   at 
> org.apache.sling.discovery.oak.TopologyWebConsolePlugin.updateDiscoveryLiteHistory(TopologyWebConsolePlugin.java:778)
>  [org.apache.sling.discovery.oak:1.2.30]
>   at 
> org.apache.sling.discovery.oak.TopologyWebConsolePlugin.handleTopologyEvent(TopologyWebConsolePlugin.java:728)
>  [org.apache.sling.discovery.oak:1.2.30]
>   

[GitHub] [sling-org-apache-sling-discovery-oak] stefan-egli merged pull request #2: SLING-10204 : less noisy logging on unregistration

2021-04-21 Thread GitBox


stefan-egli merged pull request #2:
URL: https://github.com/apache/sling-org-apache-sling-discovery-oak/pull/2


   


-- 
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-serviceusermapper] anchela commented on pull request #5: SLING-10321 : Deprecate service mapping by userID

2021-04-21 Thread GitBox


anchela commented on pull request #5:
URL: 
https://github.com/apache/sling-org-apache-sling-serviceusermapper/pull/5#issuecomment-823849392


   @cziegeler , unless you have any concerns i would go ahead and merge the 
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




[jira] [Assigned] (SLING-10324) ServiceUserMapper documentation doesn't describe mapping by principal names

2021-04-21 Thread Angela Schreiber (Jira)


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

Angela Schreiber reassigned SLING-10324:


Assignee: Angela Schreiber

> ServiceUserMapper documentation doesn't describe mapping by principal names
> ---
>
> Key: SLING-10324
> URL: https://issues.apache.org/jira/browse/SLING-10324
> Project: Sling
>  Issue Type: Bug
>  Components: Documentation
>Reporter: Angela Schreiber
>Assignee: Angela Schreiber
>Priority: Major
>
> for SLING-10321 i was looking for the corresponding documentation and found 
> that the description of the {{ServiceUserMapper}} at 
> https://sling.apache.org/documentation/the-sling-engine/service-authentication.html#serviceusermapper
>  doesn't correctly reflect the current status of the {{ServiceUserMapper}}, 
> which first resolves mapping by principal names. 



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


[jira] [Created] (SLING-10324) ServiceUserMapper documentation doesn't describe mapping by principal names

2021-04-21 Thread Angela Schreiber (Jira)
Angela Schreiber created SLING-10324:


 Summary: ServiceUserMapper documentation doesn't describe mapping 
by principal names
 Key: SLING-10324
 URL: https://issues.apache.org/jira/browse/SLING-10324
 Project: Sling
  Issue Type: Bug
  Components: Documentation
Reporter: Angela Schreiber


for SLING-10321 i was looking for the corresponding documentation and found 
that the description of the {{ServiceUserMapper}} at 
https://sling.apache.org/documentation/the-sling-engine/service-authentication.html#serviceusermapper
 doesn't correctly reflect the current status of the {{ServiceUserMapper}}, 
which first resolves mapping by principal names. 



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