[jira] [Updated] (SLING-12211) Update Parent to 52 and make build compatible with Java 17 and above

2024-04-29 Thread Carsten Ziegeler (Jira)


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

Carsten Ziegeler updated SLING-12211:
-
Fix Version/s: Rewriter 1.4.6
   (was: Rewriter 1.4.4)

> Update Parent to 52 and make build compatible with Java 17 and above
> 
>
> Key: SLING-12211
> URL: https://issues.apache.org/jira/browse/SLING-12211
> Project: Sling
>  Issue Type: Improvement
>Reporter: Konrad Windszus
>Assignee: Konrad Windszus
>Priority: Major
> Fix For: Rewriter 1.4.6
>
>
> Updating to Parent 52 allows reproducible builds 
> (https://issues.apache.org/jira/browse/SLING-11907).



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Created] (SLING-12308) Potential ArrayIndexOutOfBoundsException with global transformers

2024-04-29 Thread Carsten Ziegeler (Jira)
Carsten Ziegeler created SLING-12308:


 Summary: Potential ArrayIndexOutOfBoundsException with global 
transformers
 Key: SLING-12308
 URL: https://issues.apache.org/jira/browse/SLING-12308
 Project: Sling
  Issue Type: Bug
  Components: General
Affects Versions: Rewriter 1.4.2
Reporter: Carsten Ziegeler
Assignee: Carsten Ziegeler
 Fix For: Rewriter 1.4.4


When several global transformers are configured but one of them does not match 
the current request, an ArrayIndexOutOfBoundsException might be thrown as the 
code assumes all transformers match.
This only happens if there is a matching transformer *after* one that does not 
match. If it is the other way round, the code works.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


Re: [PR] ProcessorManagerImpl - consistent code format + remove obvious (and private) comments [sling-org-apache-sling-rewriter]

2024-04-29 Thread via GitHub


cziegeler closed pull request #2: ProcessorManagerImpl - consistent code format 
+ remove obvious (and private) comments
URL: https://github.com/apache/sling-org-apache-sling-rewriter/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.

To unsubscribe, e-mail: dev-unsubscr...@sling.apache.org

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



[jira] [Assigned] (SLING-12307) INFO logging in case no servlet can be resolved

2024-04-29 Thread Joerg Hoh (Jira)


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

Joerg Hoh reassigned SLING-12307:
-

Assignee: Joerg Hoh

> INFO logging in case no servlet can be resolved
> ---
>
> Key: SLING-12307
> URL: https://issues.apache.org/jira/browse/SLING-12307
> Project: Sling
>  Issue Type: Task
>  Components: Servlets
>Affects Versions: Servlets Resolver 2.11.2
>Reporter: Joerg Hoh
>Assignee: Joerg Hoh
>Priority: Major
>
> The Servlets Resolver should log INFO messages in case no servlet can be 
> resolved.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Created] (SLING-12307) INFO logging in case no servlet can be resolved

2024-04-29 Thread Joerg Hoh (Jira)
Joerg Hoh created SLING-12307:
-

 Summary: INFO logging in case no servlet can be resolved
 Key: SLING-12307
 URL: https://issues.apache.org/jira/browse/SLING-12307
 Project: Sling
  Issue Type: Task
  Components: Servlets
Affects Versions: Servlets Resolver 2.11.2
Reporter: Joerg Hoh


The Servlets Resolver should log INFO messages in case no servlet can be 
resolved.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Created] (SLING-12306) Sling mock: JUnit 5 parallel execution results in unregistered adapter factories

2024-04-29 Thread Henry Kuijpers (Jira)
Henry Kuijpers created SLING-12306:
--

 Summary: Sling mock: JUnit 5 parallel execution results in 
unregistered adapter factories
 Key: SLING-12306
 URL: https://issues.apache.org/jira/browse/SLING-12306
 Project: Sling
  Issue Type: Bug
Reporter: Henry Kuijpers


We have junit-jupiter.properties:
{code:java}
junit.jupiter.execution.parallel.enabled = true
junit.jupiter.execution.parallel.mode.default = same_thread
junit.jupiter.execution.parallel.mode.classes.default = concurrent {code}
And this results, randomly everytime, in lots of tests failing because of 
missing adapter factories.
 
We sometimes see that `boundAdapterFactories` is an empty list. Sometimes we 
see that `factoryCache` is a filled map, with all value lists empty.
 
We usually see the expected `descriptors` having variable content. One time it 
has 4 entries for o.a.s.a.r.Resource, the other run it has 5 entries.
 
I believe this is a concurrency issue somehow. I can reproduce it on older 
versions as well (previously we couldn't). So there could also be something 
with dependencies involved. 
 

More specifically, we seem to get a lot of these stack traces like this:
{code:java}
java.lang.RuntimeException: No page manager.
    at 
io.wcm.testing.mock.aem.context.AemContextImpl.pageManager(AemContextImpl.java:169)
    at 
io.wcm.testing.mock.aem.context.AemContextImpl.currentPage(AemContextImpl.java:229)
 {code}
(also posting this for findability on search engines)

And also a lot of cases where a Resource cannot be adapted to a ValueMap for 
example.

Which boils down to the adapter factory that can adapt a ResourceResolver to a 
PageManager, missing or actually not registered yet.

We do have the proper @ExtendWith etc setup.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Updated] (SLING-12306) Sling mock: JUnit 5 parallel execution results in unregistered adapter factories

2024-04-29 Thread Henry Kuijpers (Jira)


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

Henry Kuijpers updated SLING-12306:
---
Component/s: Testing

> Sling mock: JUnit 5 parallel execution results in unregistered adapter 
> factories
> 
>
> Key: SLING-12306
> URL: https://issues.apache.org/jira/browse/SLING-12306
> Project: Sling
>  Issue Type: Bug
>  Components: Testing
>Reporter: Henry Kuijpers
>Priority: Major
>
> We have junit-jupiter.properties:
> {code:java}
> junit.jupiter.execution.parallel.enabled = true
> junit.jupiter.execution.parallel.mode.default = same_thread
> junit.jupiter.execution.parallel.mode.classes.default = concurrent {code}
> And this results, randomly everytime, in lots of tests failing because of 
> missing adapter factories.
>  
> We sometimes see that `boundAdapterFactories` is an empty list. Sometimes we 
> see that `factoryCache` is a filled map, with all value lists empty.
>  
> We usually see the expected `descriptors` having variable content. One time 
> it has 4 entries for o.a.s.a.r.Resource, the other run it has 5 entries.
>  
> I believe this is a concurrency issue somehow. I can reproduce it on older 
> versions as well (previously we couldn't). So there could also be something 
> with dependencies involved. 
>  
> 
> More specifically, we seem to get a lot of these stack traces like this:
> {code:java}
> java.lang.RuntimeException: No page manager.
>     at 
> io.wcm.testing.mock.aem.context.AemContextImpl.pageManager(AemContextImpl.java:169)
>     at 
> io.wcm.testing.mock.aem.context.AemContextImpl.currentPage(AemContextImpl.java:229)
>  {code}
> (also posting this for findability on search engines)
> And also a lot of cases where a Resource cannot be adapted to a ValueMap for 
> example.
> Which boils down to the adapter factory that can adapt a ResourceResolver to 
> a PageManager, missing or actually not registered yet.
> We do have the proper @ExtendWith etc setup.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Closed] (SLING-12304) Broken backwards compatibility: out of order json object

2024-04-29 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12304.
---

> Broken backwards compatibility: out of order json object
> 
>
> Key: SLING-12304
> URL: https://issues.apache.org/jira/browse/SLING-12304
> Project: Sling
>  Issue Type: Bug
>Affects Versions: Commons JSON 2.0.26
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Critical
> Fix For: Commons JSON 2.0.28
>
>
> The fix of CVE-2022-47937 introduced an invalid backwards compatibility for 
> the order in jsonobject.
> New behaviour: has the keys unordered, as JsonObject uses a HashMap.
> Old behaviour: Kept insertion order of keys as JsonObject used LinkedHashMap.
> To no break existing users of the library, reestablish the old behaviour.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[RESULT] [VOTE] Release Apache Sling Commons JSON 2.0.28

2024-04-29 Thread Robert Munteanu
Hi,

The vote has passed with the following result:

+1 (binding): Stefan Seifert, Carsten Ziegeler, Joerg Hoh
+1 (non-binding): none

I will copy this release to the Sling dist directory and
promote the artifacts to the central Maven repository.

Regards,
Robert Munteanu



[jira] [Closed] (SLING-12297) Logging in case no servlet can be resolved

2024-04-29 Thread Joerg Hoh (Jira)


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

Joerg Hoh closed SLING-12297.
-

> Logging in case no servlet can be resolved
> --
>
> Key: SLING-12297
> URL: https://issues.apache.org/jira/browse/SLING-12297
> Project: Sling
>  Issue Type: Task
>Affects Versions: Engine 2.15.10
>Reporter: Joerg Hoh
>Assignee: Joerg Hoh
>Priority: Major
> Fix For: Engine 2.15.14
>
>
> Right now the SlingEngine just returns a 404, if the no servlet was found to 
> render the resource. It should also log a WARN message indicating that this 
> happened.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[RESULT][VOTE] Sling Engine 2.15.14

2024-04-29 Thread Jörg Hoh
Hi,

The vote has passed with the following result :

+1 (binding): Carsten Ziegeler, Stefan Seifert, Jörg Hoh
+1 (non binding):

I will copy this release to the Sling dist directory and
promote the artifacts to the central Maven repository.

Jörg

Am Mo., 22. Apr. 2024 um 05:19 Uhr schrieb Jörg Hoh :

> Hi,
>
> We solved 1 issue in this 
> release:https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12310710=12354595=Text
>
> Staging 
> repository:https://repository.apache.org/content/repositories/orgapachesling-2852/
>
> You can use this UNIX script to download the release and verify the 
> signatures:https://raw.githubusercontent.com/apache/sling-tooling-release/master/check_staged_release.sh
> Usage:
> sh check_staged_release.sh 2852 /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.
>
>
>
> --
> https://cqdump.joerghoh.de
>
>

-- 
https://cqdump.joerghoh.de


[jira] [Closed] (SLING-12197) cpconverter: Sling-Initial-Content directories created as nt:folder instead of sling:Folder

2024-04-29 Thread Stefan Seifert (Jira)


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

Stefan Seifert closed SLING-12197.
--

> cpconverter: Sling-Initial-Content directories created as nt:folder instead 
> of sling:Folder
> ---
>
> Key: SLING-12197
> URL: https://issues.apache.org/jira/browse/SLING-12197
> Project: Sling
>  Issue Type: Bug
>  Components: Content-Package to Feature Model Converter
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Stefan Seifert
>Priority: Major
> Attachments: io.wcm.handler.link-apps-1.10.2-cp2fm-converted.zip
>
>
> the cpconverter extracts Sling-Initial-Content from OSGi bundles and creates 
> FileVault packages with the transformed content.
> this works well, but there is one difference when the resulting content 
> package is installed compared when uploading the OSGi bundle with the 
> Sling-Initial-Content directly:
> * the JCR Content Loader by defaults creates a {{sling:Folder}} node type for 
> each directory found in the Sling-Initial-Content (see also 
> [docs|https://sling.apache.org/documentation/bundles/content-loading-jcr-contentloader.html#initial-content-loading-1])
> * the cpconverter process creates no {{.content.xml}} file for the folders, 
> but only for the actual JSON files found in the process. as a result, the 
> folders are created as {{nt:folder}} when uploading the transformed package
> * this difference becomes relevant, when a JSON file in Sling-Initial-Content 
> defines a primary type of {{nt:unstructured}} - it is not allowed to created 
> such a node directly below a {{nt:folder}} node - but it is allowed to do so 
> below a {{sling:Folder}} node



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Resolved] (SLING-12197) cpconverter: Sling-Initial-Content directories created as nt:folder instead of sling:Folder

2024-04-29 Thread Stefan Seifert (Jira)


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

Stefan Seifert resolved SLING-12197.

Fix Version/s: (was: Content-Package to Feature Model Converter 1.3.8)
   Resolution: Not A Bug

closing this ticket, as the root cause was not in the cpconverter

> cpconverter: Sling-Initial-Content directories created as nt:folder instead 
> of sling:Folder
> ---
>
> Key: SLING-12197
> URL: https://issues.apache.org/jira/browse/SLING-12197
> Project: Sling
>  Issue Type: Bug
>  Components: Content-Package to Feature Model Converter
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Stefan Seifert
>Priority: Major
> Attachments: io.wcm.handler.link-apps-1.10.2-cp2fm-converted.zip
>
>
> the cpconverter extracts Sling-Initial-Content from OSGi bundles and creates 
> FileVault packages with the transformed content.
> this works well, but there is one difference when the resulting content 
> package is installed compared when uploading the OSGi bundle with the 
> Sling-Initial-Content directly:
> * the JCR Content Loader by defaults creates a {{sling:Folder}} node type for 
> each directory found in the Sling-Initial-Content (see also 
> [docs|https://sling.apache.org/documentation/bundles/content-loading-jcr-contentloader.html#initial-content-loading-1])
> * the cpconverter process creates no {{.content.xml}} file for the folders, 
> but only for the actual JSON files found in the process. as a result, the 
> folders are created as {{nt:folder}} when uploading the transformed package
> * this difference becomes relevant, when a JSON file in Sling-Initial-Content 
> defines a primary type of {{nt:unstructured}} - it is not allowed to created 
> such a node directly below a {{nt:folder}} node - but it is allowed to do so 
> below a {{sling:Folder}} node



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (SLING-12197) cpconverter: Sling-Initial-Content directories created as nt:folder instead of sling:Folder

2024-04-29 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12197:
-

[~Sc0rpic0m] [~sseifert] - any concerns with closing this and tracking the fix 
on the AEM Analyser side?

> cpconverter: Sling-Initial-Content directories created as nt:folder instead 
> of sling:Folder
> ---
>
> Key: SLING-12197
> URL: https://issues.apache.org/jira/browse/SLING-12197
> Project: Sling
>  Issue Type: Bug
>  Components: Content-Package to Feature Model Converter
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Stefan Seifert
>Priority: Major
> Fix For: Content-Package to Feature Model Converter 1.3.8
>
> Attachments: io.wcm.handler.link-apps-1.10.2-cp2fm-converted.zip
>
>
> the cpconverter extracts Sling-Initial-Content from OSGi bundles and creates 
> FileVault packages with the transformed content.
> this works well, but there is one difference when the resulting content 
> package is installed compared when uploading the OSGi bundle with the 
> Sling-Initial-Content directly:
> * the JCR Content Loader by defaults creates a {{sling:Folder}} node type for 
> each directory found in the Sling-Initial-Content (see also 
> [docs|https://sling.apache.org/documentation/bundles/content-loading-jcr-contentloader.html#initial-content-loading-1])
> * the cpconverter process creates no {{.content.xml}} file for the folders, 
> but only for the actual JSON files found in the process. as a result, the 
> folders are created as {{nt:folder}} when uploading the transformed package
> * this difference becomes relevant, when a JSON file in Sling-Initial-Content 
> defines a primary type of {{nt:unstructured}} - it is not allowed to created 
> such a node directly below a {{nt:folder}} node - but it is allowed to do so 
> below a {{sling:Folder}} node



--
This message was sent by Atlassian Jira
(v8.20.10#820010)