[jira] [Updated] (SLING-12317) Make Sling Engine build with Java 21

2024-05-15 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12317:

Fix Version/s: Engine 2.15.16

> Make Sling Engine build with Java 21
> 
>
> Key: SLING-12317
> URL: https://issues.apache.org/jira/browse/SLING-12317
> Project: Sling
>  Issue Type: Task
>  Components: Engine
>Affects Versions: Engine 2.15.14
>Reporter: Joerg Hoh
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Engine 2.15.16
>
>
> {noformat}[ERROR] 
> org.apache.sling.engine.impl.SlingHttpServletRequestImplTest.getUserPrincipal_testUnauthenticated_nonspeccompliant
>   Time elapsed: 0 s  <<< ERROR!
> java.lang.IllegalStateException: No code generation strategy available
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser.proxyClass(ByteBuddyClassImposteriser.java:167)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser.access$000(ByteBuddyClassImposteriser.java:41)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser$1.apply(ByteBuddyClassImposteriser.java:100)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser$1.apply(ByteBuddyClassImposteriser.java:96)
>   at 
> java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser.proxy(ByteBuddyClassImposteriser.java:95)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser.imposterise(ByteBuddyClassImposteriser.java:66)
>   at org.jmock.Mockery.mock(Mockery.java:167)
>   at org.jmock.Mockery.mock(Mockery.java:143)
>   at 
> org.apache.sling.engine.impl.SlingHttpServletRequestImplTest.getUserPrincipal_testUnauthenticated_nonspeccompliant(SlingHttpServletRequestImplTest.java:176)
>   at 
> java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
>   at java.base/java.lang.reflect.Method.invoke(Method.java:580)
>   at 
> org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
>   at 
> org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
>   at 
> org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
>   at 
> org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
>   at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
>   at 
> org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
>   at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
>   at 
> org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
>   at 
> org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
>   at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
>   at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
>   at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
>   at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
>   at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
>   at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
>   at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
>   at 
> org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:364)
>   at 
> org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:272)
>   at 
> org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:237)
>   at 
> org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:158)
>   at 
> org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:428)
>   at 
> org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
>   at 
> org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:562)
>   at 
> org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:548){noformat}



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


[jira] [Updated] (SLING-12317) Make Sling Engine build with Java 21

2024-05-15 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12317:

Description: 
{noformat}[ERROR] 
org.apache.sling.engine.impl.SlingHttpServletRequestImplTest.getUserPrincipal_testUnauthenticated_nonspeccompliant
  Time elapsed: 0 s  <<< ERROR!
java.lang.IllegalStateException: No code generation strategy available
at 
org.jmock.imposters.ByteBuddyClassImposteriser.proxyClass(ByteBuddyClassImposteriser.java:167)
at 
org.jmock.imposters.ByteBuddyClassImposteriser.access$000(ByteBuddyClassImposteriser.java:41)
at 
org.jmock.imposters.ByteBuddyClassImposteriser$1.apply(ByteBuddyClassImposteriser.java:100)
at 
org.jmock.imposters.ByteBuddyClassImposteriser$1.apply(ByteBuddyClassImposteriser.java:96)
at 
java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
at 
org.jmock.imposters.ByteBuddyClassImposteriser.proxy(ByteBuddyClassImposteriser.java:95)
at 
org.jmock.imposters.ByteBuddyClassImposteriser.imposterise(ByteBuddyClassImposteriser.java:66)
at org.jmock.Mockery.mock(Mockery.java:167)
at org.jmock.Mockery.mock(Mockery.java:143)
at 
org.apache.sling.engine.impl.SlingHttpServletRequestImplTest.getUserPrincipal_testUnauthenticated_nonspeccompliant(SlingHttpServletRequestImplTest.java:176)
at 
java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
at java.base/java.lang.reflect.Method.invoke(Method.java:580)
at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at 
org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:364)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:272)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:237)
at 
org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:158)
at 
org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:428)
at 
org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
at 
org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:562)
at 
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:548){noformat}

> Make Sling Engine build with Java 21
> 
>
> Key: SLING-12317
> URL: https://issues.apache.org/jira/browse/SLING-12317
> Project: Sling
>  Issue Type: Task
>  Components: Engine
>Affects Versions: Engine 2.15.14
>Reporter: Joerg Hoh
>Assignee: Robert Munteanu
>Priority: Major
>
> {noformat}[ERROR] 
> org.apache.sling.engine.impl.SlingHttpServletRequestImplTest.getUserPrincipal_testUnauthenticated_nonspeccompliant
>   Time elapsed: 0 s  <<< ERROR!
> java.lang.IllegalStateException: No code generation strategy available
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser.proxyClass(ByteBuddyClassImposteriser.java:167)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser.access$000(ByteBuddyClassImposteriser.java:41)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser$1.apply(ByteBuddyClassImposteriser.java:100)
>   at 
> org.jmock.imposters.ByteBuddyClassImposteriser$1.apply(ByteBuddyClassImposteriser.java:96)
>   at 
> java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
>   at 
> 

[jira] [Assigned] (SLING-12317) Make Sling Engine build with Java 21

2024-05-15 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12317:
---

Assignee: Robert Munteanu

> Make Sling Engine build with Java 21
> 
>
> Key: SLING-12317
> URL: https://issues.apache.org/jira/browse/SLING-12317
> Project: Sling
>  Issue Type: Task
>  Components: Engine
>Affects Versions: Engine 2.15.14
>Reporter: Joerg Hoh
>Assignee: Robert Munteanu
>Priority: Major
>




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


[jira] [Assigned] (SLING-12315) A race condition leads to failing resource-bundle registration during deactivation

2024-05-13 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12315:
---

Assignee: Elia Colombo

> A race condition leads to failing resource-bundle registration during 
> deactivation
> --
>
> Key: SLING-12315
> URL: https://issues.apache.org/jira/browse/SLING-12315
> Project: Sling
>  Issue Type: Bug
>  Components: i18n
>Reporter: Elia Colombo
>Assignee: Elia Colombo
>Priority: Major
>
> The following exception was observed:
> {code:java}
> [sling-default-5-ResourceBundleProvider: reload all resource bundles] 
> org.apache.sling.commons.scheduler.impl.QuartzScheduler Exception during job 
> execution of job 
> 'org.apache.sling.i18n.impl.JcrResourceBundleProvider$1@688bc8e' with name 
> 'ResourceBundleProvider: reload all resource bundles' : Cannot invoke 
> "org.osgi.framework.BundleContext.registerService(java.lang.Class, Object, 
> java.util.Dictionary)" because "this.bundleContext" is 
> nulljava.lang.NullPointerException: Cannot invoke 
> "org.osgi.framework.BundleContext.registerService(java.lang.Class, Object, 
> java.util.Dictionary)" because "this.bundleContext" is null at  
> org.apache.sling.i18n.impl.JcrResourceBundleProvider.registerResourceBundle(JcrResourceBundleProvider.java:532)
>  [org.apache.sling.i18n:2.6.2]{code}
> During the deactivation of JcrResourceBundleProvider, ReloadBundle jobs that 
> are still running can try to register new resourceBundles. This fails, if 
> deactivate already set bundleContext to null. 
> Proposed solution:
>  * use bundleContext as cancel flag during deactivation (bundleContext=null)
>  * prevent new registration of resources during deactivation (necessary)
>  * prevent processing of new onChange events during deactivation (improvement)
>  * prevent scheduling of new bundle reloading jobs during deactivation 
> (improvement)
>  * execute clearCache after setting bundleContext to null, to prevent new 
> registrations (improvement)
> BundleContext can be used as cancel flag, since conveniently it is anyway set 
> to null during deactivation. New registrations can be effectively avoided by 
> checking bundleContext==null before any registration within a synchronized 
> block.



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


[jira] [Updated] (SLING-12315) A race condition leads to failing resource-bundle registration during deactivation

2024-05-13 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12315:

Fix Version/s: i18n 2.6.4

> A race condition leads to failing resource-bundle registration during 
> deactivation
> --
>
> Key: SLING-12315
> URL: https://issues.apache.org/jira/browse/SLING-12315
> Project: Sling
>  Issue Type: Bug
>  Components: i18n
>Reporter: Elia Colombo
>Assignee: Elia Colombo
>Priority: Major
> Fix For: i18n 2.6.4
>
>
> The following exception was observed:
> {code:java}
> [sling-default-5-ResourceBundleProvider: reload all resource bundles] 
> org.apache.sling.commons.scheduler.impl.QuartzScheduler Exception during job 
> execution of job 
> 'org.apache.sling.i18n.impl.JcrResourceBundleProvider$1@688bc8e' with name 
> 'ResourceBundleProvider: reload all resource bundles' : Cannot invoke 
> "org.osgi.framework.BundleContext.registerService(java.lang.Class, Object, 
> java.util.Dictionary)" because "this.bundleContext" is 
> nulljava.lang.NullPointerException: Cannot invoke 
> "org.osgi.framework.BundleContext.registerService(java.lang.Class, Object, 
> java.util.Dictionary)" because "this.bundleContext" is null at  
> org.apache.sling.i18n.impl.JcrResourceBundleProvider.registerResourceBundle(JcrResourceBundleProvider.java:532)
>  [org.apache.sling.i18n:2.6.2]{code}
> During the deactivation of JcrResourceBundleProvider, ReloadBundle jobs that 
> are still running can try to register new resourceBundles. This fails, if 
> deactivate already set bundleContext to null. 
> Proposed solution:
>  * use bundleContext as cancel flag during deactivation (bundleContext=null)
>  * prevent new registration of resources during deactivation (necessary)
>  * prevent processing of new onChange events during deactivation (improvement)
>  * prevent scheduling of new bundle reloading jobs during deactivation 
> (improvement)
>  * execute clearCache after setting bundleContext to null, to prevent new 
> registrations (improvement)
> BundleContext can be used as cancel flag, since conveniently it is anyway set 
> to null during deactivation. New registrations can be effectively avoided by 
> checking bundleContext==null before any registration within a synchronized 
> block.



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


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


[jira] [Closed] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2024-04-27 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12173.
---

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Bug
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.getProjectFacade(MavenBuilder.java:146)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.lambda$0(MavenBuilder.java:84)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.execute(MavenBuilder.java:83)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder.build(MavenBuilder.java:192)
>   at 
> org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:1079)
> 

[jira] [Closed] (SLING-12153) Update maven-archiver and maven-filtering

2024-04-27 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12153.
---

> Update maven-archiver and maven-filtering
> -
>
> Key: SLING-12153
> URL: https://issues.apache.org/jira/browse/SLING-12153
> Project: Sling
>  Issue Type: Improvement
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Minor
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> [~jsedding] noticed that the plug-in brings in older versions of the 
> maven-archiver and maven-filtering. Those dependencies 
> {quote}drag an ancient guava version into the classpath via a transitive 
> dependency that was moved into "test" scope in newer versions of these two 
> libraries{quote}
> This causes various problems with IntelliJ and Eclipse integration. And 
> upgrading dependencies is always a good idea :-)



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


[jira] [Closed] (SLING-12159) Add report to list package imports of jsp scripts

2024-04-27 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12159.
---

> Add report to list package imports of jsp scripts
> -
>
> Key: SLING-12159
> URL: https://issues.apache.org/jira/browse/SLING-12159
> Project: Sling
>  Issue Type: New Feature
>  Components: Maven Plugins and Archetypes
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> In addition to the reports about bundle package imports, we should generate 
> info about package imports from scripts (jsps)



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


[jira] [Closed] (SLING-12174) Parameter 'defaultMetadata' is unknown for plugin

2024-04-27 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12174.
---

> Parameter 'defaultMetadata' is unknown for plugin
> -
>
> Key: SLING-12174
> URL: https://issues.apache.org/jira/browse/SLING-12174
> Project: Sling
>  Issue Type: Bug
>  Components: Feature Model, Maven Plugins and Archetypes
>Affects Versions: OSGi Feature Maven Plugin 1.8.0
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> When running the slingfeature maven plugin with latest Apache Maven, the 
> warning "Parameter 'defaultMetadata' is unknown for plugin" appears for all 
> goals.
> This is due to the fact that this parameter is evaluated in the preprocessor.



--
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-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12197:
-

Sure, if Niek has the time to look at it I'm all for it :-) I looked the 
initial PR from SLING-10931 and it's a lot of code, not easy to figure out 
where to insert what.

As for the test case, it would be very helpful if you could create a simple 
package with Sling initial content that install on the latest Sling Starter but 
fails when passed through the CP Converter. The bundle you linked above 
requires AEM-specific APIs and I can't use it for testing. 

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


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

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12304:
---

Assignee: Remo Liechti

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


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

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12304.
-
Resolution: Fixed

PR applied, thanks [~rliechti]!

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


[jira] [Closed] (SLING-11633) ClientSideTeleporter throwing illegal argument when target byte code is > 1.8

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-11633.
---

> ClientSideTeleporter throwing illegal argument when target byte code is > 1.8
> -
>
> Key: SLING-11633
> URL: https://issues.apache.org/jira/browse/SLING-11633
> Project: Sling
>  Issue Type: Improvement
>  Components: Testing
> Environment: Apache Maven 3.8.5 
> (3599d3414f046de2324203b78ddcf9b5e4388aa0)
> Maven home: C:\aem-tools\utils\apache-maven-3.8.5
> Java version: 11.0.15.1, vendor: Oracle Corporation, runtime: 
> C:\aem-tools\utils\jdk-11.0.15.1
> Default locale: en_US, platform encoding: Cp1252
> OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"
>Reporter: Scott Yuan
>Assignee: Scott Yuan
>Priority: Trivial
> Fix For: JUnit Tests Teleporter 1.0.26
>
> Attachments: mylab.zip
>
>   Original Estimate: 2h
>  Time Spent: 0.5h
>  Remaining Estimate: 1.5h
>
> When attempted to use the latest 1.0.22 to build test cases using 
> TeleporterRule with Java 11+ code, illegal arguments error occurred. 
> It can be reproduce with the attached Maven project by change following 
> properites to 11. 
> * maven.compiler.source
> * maven.compiler.target



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


[jira] [Closed] (SLING-9327) Teleporter not working with jdk11 due to missing xml bind classes

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-9327.
--

> Teleporter not working with jdk11 due to missing xml bind classes
> -
>
> Key: SLING-9327
> URL: https://issues.apache.org/jira/browse/SLING-9327
> Project: Sling
>  Issue Type: Bug
>  Components: Testing
>Affects Versions: JUnit Tests Teleporter 1.0.10
>Reporter: Thierry Ygé
>Assignee: Robert Munteanu
>Priority: Blocker
> Fix For: JUnit Tests Teleporter 1.0.26
>
>  Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> Currently when using teleporter on jdk11 based environment, the teleporter is 
> failing due to missing class.
> {quote}java.lang.NoClassDefFoundError: javax/xml/bind/DatatypeConverter at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.setConnectionCredentials(TeleporterHttpClient.java:63)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.getHttpGetStatus(TeleporterHttpClient.java:136)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.waitForStatus(TeleporterHttpClient.java:75)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.installBundle(TeleporterHttpClient.java:94)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.installTestBundle(ClientSideTeleporter.java:173)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.access$000(ClientSideTeleporter.java:45)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter$2.evaluate(ClientSideTeleporter.java:207)
>  at 
> com.adobe.granite.testing.serverside.rules.GraniteSSTRule$1.evaluate(GraniteSSTRule.java:104)
> {quote}
> This is due to jdk not containing this package anymore since jdk 9.
> Teleporter used is 1.0.10 and with 1.0.20 I couldn't use it as it fails with 
> missing osgi core dependency, unless I would then add it manually in the test 
> module pom.
> Note from [~bdelacretaz]
> As per 
> [https://stackoverflow.com/questions/52502189/java-11-package-javax-xml-bind-does-not-exist]
>  it looks like using {{jakarta.xml.bind}} as an additional dependency might 
> fix this.



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


[jira] [Resolved] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12173.
-
Fix Version/s: OSGi Feature Maven Plugin 1.8.2
   (was: OSGi Feature Maven Plugin 1.8.4)
   Resolution: Fixed

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Bug
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.getProjectFacade(MavenBuilder.java:146)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.lambda$0(MavenBuilder.java:84)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.execute(MavenBuilder.java:83)
>   at 
> 

[jira] [Updated] (SLING-12305) Build fails on Java 21 due to invoker plug-in: Unsupported class file major version 65

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12305:

Fix Version/s: OSGi Feature Maven Plugin 1.8.4
   (was: OSGi Feature Maven Plugin 1.8.2)

> Build fails on Java 21 due to invoker plug-in: Unsupported class file major 
> version 65
> --
>
> Key: SLING-12305
> URL: https://issues.apache.org/jira/browse/SLING-12305
> Project: Sling
>  Issue Type: Bug
>Affects Versions: OSGi Feature Maven Plugin 1.8.0
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.4
>
>
> The invoker plugin-ins runs groovy scripts in the {{verify}} goal, and this 
> fails on Java 21 with
> {noformat}
> [INFO] --- invoker:3.5.1:integration-test (integration-test) @ 
> slingfeature-maven-plugin ---
> [INFO] Building: analyzer-apiregions-errors-detected/pom.xml
> [INFO] run post-build script verify.groovy
> [INFO]   BUG! exception in phase 'semantic analysis' in source unit 
> 'Script1.groovy' Unsupported class file major version 65
> [INFO]   analyzer-apiregions-errors-detected/pom.xml .. FAILED 
> (3.0 s)
> {noformat}
> The stack trace seems to indicate that Groovy tries to parse Java 21 bytecode 
> and fails.
> {noformat}
> Caused by: java.lang.IllegalArgumentException: Unsupported class file major 
> version 65
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:199)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:180)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:166)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:287)
>   at 
> org.codehaus.groovy.ast.decompiled.AsmDecompiler.parseClass(AsmDecompiler.java:83)
> {noformat}



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


[jira] [Resolved] (SLING-12305) Build fails on Java 21 due to invoker plug-in: Unsupported class file major version 65

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12305.
-
Resolution: Fixed

> Build fails on Java 21 due to invoker plug-in: Unsupported class file major 
> version 65
> --
>
> Key: SLING-12305
> URL: https://issues.apache.org/jira/browse/SLING-12305
> Project: Sling
>  Issue Type: Bug
>Affects Versions: OSGi Feature Maven Plugin 1.8.0
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.4
>
>
> The invoker plugin-ins runs groovy scripts in the {{verify}} goal, and this 
> fails on Java 21 with
> {noformat}
> [INFO] --- invoker:3.5.1:integration-test (integration-test) @ 
> slingfeature-maven-plugin ---
> [INFO] Building: analyzer-apiregions-errors-detected/pom.xml
> [INFO] run post-build script verify.groovy
> [INFO]   BUG! exception in phase 'semantic analysis' in source unit 
> 'Script1.groovy' Unsupported class file major version 65
> [INFO]   analyzer-apiregions-errors-detected/pom.xml .. FAILED 
> (3.0 s)
> {noformat}
> The stack trace seems to indicate that Groovy tries to parse Java 21 bytecode 
> and fails.
> {noformat}
> Caused by: java.lang.IllegalArgumentException: Unsupported class file major 
> version 65
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:199)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:180)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:166)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:287)
>   at 
> org.codehaus.groovy.ast.decompiled.AsmDecompiler.parseClass(AsmDecompiler.java:83)
> {noformat}



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


[jira] [Updated] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12173:

Fix Version/s: OSGi Feature Maven Plugin 1.8.4
   (was: OSGi Feature Maven Plugin 1.8.2)

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Bug
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.4
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.getProjectFacade(MavenBuilder.java:146)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.lambda$0(MavenBuilder.java:84)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.execute(MavenBuilder.java:83)
>   at 
> 

[jira] [Updated] (SLING-12305) Build fails on Java 21 due to invoker plug-in: Unsupported class file major version 65

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12305:

Issue Type: Bug  (was: Task)

> Build fails on Java 21 due to invoker plug-in: Unsupported class file major 
> version 65
> --
>
> Key: SLING-12305
> URL: https://issues.apache.org/jira/browse/SLING-12305
> Project: Sling
>  Issue Type: Bug
>Affects Versions: OSGi Feature Maven Plugin 1.8.0
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The invoker plugin-ins runs groovy scripts in the {{verify}} goal, and this 
> fails on Java 21 with
> {noformat}
> [INFO] --- invoker:3.5.1:integration-test (integration-test) @ 
> slingfeature-maven-plugin ---
> [INFO] Building: analyzer-apiregions-errors-detected/pom.xml
> [INFO] run post-build script verify.groovy
> [INFO]   BUG! exception in phase 'semantic analysis' in source unit 
> 'Script1.groovy' Unsupported class file major version 65
> [INFO]   analyzer-apiregions-errors-detected/pom.xml .. FAILED 
> (3.0 s)
> {noformat}
> The stack trace seems to indicate that Groovy tries to parse Java 21 bytecode 
> and fails.
> {noformat}
> Caused by: java.lang.IllegalArgumentException: Unsupported class file major 
> version 65
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:199)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:180)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:166)
>   at groovyjarjarasm.asm.ClassReader.(ClassReader.java:287)
>   at 
> org.codehaus.groovy.ast.decompiled.AsmDecompiler.parseClass(AsmDecompiler.java:83)
> {noformat}



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


[jira] [Created] (SLING-12305) Build fails on Java 21 due to invoker plug-in: Unsupported class file major version 65

2024-04-25 Thread Robert Munteanu (Jira)
Robert Munteanu created SLING-12305:
---

 Summary: Build fails on Java 21 due to invoker plug-in: 
Unsupported class file major version 65
 Key: SLING-12305
 URL: https://issues.apache.org/jira/browse/SLING-12305
 Project: Sling
  Issue Type: Task
Affects Versions: OSGi Feature Maven Plugin 1.8.0
Reporter: Robert Munteanu
Assignee: Robert Munteanu
 Fix For: OSGi Feature Maven Plugin 1.8.2


The invoker plugin-ins runs groovy scripts in the {{verify}} goal, and this 
fails on Java 21 with

{noformat}
[INFO] --- invoker:3.5.1:integration-test (integration-test) @ 
slingfeature-maven-plugin ---
[INFO] Building: analyzer-apiregions-errors-detected/pom.xml
[INFO] run post-build script verify.groovy
[INFO]   BUG! exception in phase 'semantic analysis' in source unit 
'Script1.groovy' Unsupported class file major version 65
[INFO]   analyzer-apiregions-errors-detected/pom.xml .. FAILED (3.0 
s)
{noformat}

The stack trace seems to indicate that Groovy tries to parse Java 21 bytecode 
and fails.

{noformat}
Caused by: java.lang.IllegalArgumentException: Unsupported class file major 
version 65
at groovyjarjarasm.asm.ClassReader.(ClassReader.java:199)
at groovyjarjarasm.asm.ClassReader.(ClassReader.java:180)
at groovyjarjarasm.asm.ClassReader.(ClassReader.java:166)
at groovyjarjarasm.asm.ClassReader.(ClassReader.java:287)
at 
org.codehaus.groovy.ast.decompiled.AsmDecompiler.parseClass(AsmDecompiler.java:83)
{noformat}



--
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-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12197:
-

[~sseifert] - I did not have time to look into it in depth, but reading through 
the description it seems like a clear incompatibility between the CP Converter 
and Initial Content behaviour that we need to address. I don't know the 
codebase that well either, so a fix is not immediate for me either, 
unfortunately.

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


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

2024-04-25 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12304:

Fix Version/s: Commons JSON 2.0.28

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


[jira] [Commented] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2024-04-24 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12173:
-

[~cziegeler] - that was my attempt to try out and see if the older plug-in 
version has the same problem. It does have it, so both the jakarta.json and 
javax.json implementations are problematic - in Eclipse, for me.

I suspect this is a classloader interaction between
- Maven/Plexus
- the OSGi runtime from Eclipse (Equinox)
- the ServiceLoader framework
- m2e

I _could_ try and chase this down across these projects but it seems like a lot 
of work. Instead, I am experimenting with using our commons.johnzon dependency 
instead the official JSON artifacts, and for now it seems to work fine.

IIUC this would avoid any such classloading issues, and hopefully will not 
bring any problems with Maven executions. I'll try to run some tests over the 
coming days, but wanted to check what you think of this approach.

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Bug
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   

[jira] [Closed] (SLING-12290) Update tenant module to use parent pom 52

2024-04-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12290.
---

> Update tenant module to use parent pom 52
> -
>
> Key: SLING-12290
> URL: https://issues.apache.org/jira/browse/SLING-12290
> Project: Sling
>  Issue Type: Task
>  Components: Extensions
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Tenant 1.1.8
>
>




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


[jira] [Closed] (SLING-12285) adding bind & unbind methods mapping in reference annotation

2024-04-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12285.
---

> adding bind & unbind methods mapping in reference annotation
> 
>
> Key: SLING-12285
> URL: https://issues.apache.org/jira/browse/SLING-12285
> Project: Sling
>  Issue Type: Bug
>  Components: Extensions
>Reporter: Gagan Malpani
>Assignee: Gagan Malpani
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> adding bind & unbind methods mapping in reference annotation for 
> tenantproviderimpl



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


[jira] [Closed] (SLING-12286) Tenant build fails with Java 17 or newer

2024-04-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12286.
---

> Tenant build fails with Java 17 or newer
> 
>
> Key: SLING-12286
> URL: https://issues.apache.org/jira/browse/SLING-12286
> Project: Sling
>  Issue Type: Bug
>  Components: Extensions
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> [ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.038 
> s <<< FAILURE! - in org.apache.sling.tenant.internal.TenantProviderImplTest
> [ERROR] 
> org.apache.sling.tenant.internal.TenantProviderImplTest.testListTenantsWithoutTenantRoot
>   Time elapsed: 0.036 s  <<< ERROR!
> java.lang.ExceptionInInitializerError
>   at 
> org.mockito.cglib.core.KeyFactory$Generator.generateClass(KeyFactory.java:167)



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


[jira] [Closed] (SLING-12291) Broken backwards compatibility for duplicated keys

2024-04-17 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12291.
---

> Broken backwards compatibility for duplicated keys
> --
>
> Key: SLING-12291
> URL: https://issues.apache.org/jira/browse/SLING-12291
> Project: Sling
>  Issue Type: Bug
>Affects Versions: Commons JSON 2.0.24
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.26
>
>
> The fix of CVE-2022-47937 introduced an invalid backwards compatibility for 
> duplicated keys in a json.
> New behaviour: throws an exception on duplicated keys
> Old behaviour: ignores the fact and is able to process json with duplicated 
> keys.
> To no break existing users of the library, reestablish the old behaviour.



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


[jira] [Assigned] (SLING-11633) ClientSideTeleporter throwing illegal argument when target byte code is > 1.8

2024-04-17 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-11633:
---

Assignee: Scott Yuan

> ClientSideTeleporter throwing illegal argument when target byte code is > 1.8
> -
>
> Key: SLING-11633
> URL: https://issues.apache.org/jira/browse/SLING-11633
> Project: Sling
>  Issue Type: Improvement
>  Components: Testing
> Environment: Apache Maven 3.8.5 
> (3599d3414f046de2324203b78ddcf9b5e4388aa0)
> Maven home: C:\aem-tools\utils\apache-maven-3.8.5
> Java version: 11.0.15.1, vendor: Oracle Corporation, runtime: 
> C:\aem-tools\utils\jdk-11.0.15.1
> Default locale: en_US, platform encoding: Cp1252
> OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"
>Reporter: Scott Yuan
>Assignee: Scott Yuan
>Priority: Trivial
> Fix For: JUnit Tests Teleporter 1.0.26
>
> Attachments: mylab.zip
>
>   Original Estimate: 2h
>  Time Spent: 0.5h
>  Remaining Estimate: 1.5h
>
> When attempted to use the latest 1.0.22 to build test cases using 
> TeleporterRule with Java 11+ code, illegal arguments error occurred. 
> It can be reproduce with the attached Maven project by change following 
> properites to 11. 
> * maven.compiler.source
> * maven.compiler.target



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


[jira] [Commented] (OAK-6773) Convert oak-store-composite to OSGi R7 annotations

2024-04-17 Thread Robert Munteanu (Jira)


[ 
https://issues.apache.org/jira/browse/OAK-6773?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17838076#comment-17838076
 ] 

Robert Munteanu commented on OAK-6773:
--

Thanks for the heads-up [~baedke]. I think the descriptions are valuable to 
developers, so keeping them as comments would be good.

> Convert oak-store-composite to OSGi R7 annotations
> --
>
> Key: OAK-6773
> URL: https://issues.apache.org/jira/browse/OAK-6773
> Project: Jackrabbit Oak
>  Issue Type: Technical task
>  Components: composite
>Reporter: Robert Munteanu
>Assignee: Manfred Baedke
>Priority: Major
> Fix For: 1.64.0
>
>




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


[jira] [Resolved] (SLING-9327) Teleporter not working with jdk11 due to missing xml bind classes

2024-04-16 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-9327.

Resolution: Fixed

Merged 
https://github.com/apache/sling-org-apache-sling-junit-teleporter/pull/6, I 
think we can close this now.

> Teleporter not working with jdk11 due to missing xml bind classes
> -
>
> Key: SLING-9327
> URL: https://issues.apache.org/jira/browse/SLING-9327
> Project: Sling
>  Issue Type: Bug
>  Components: Testing
>Affects Versions: JUnit Tests Teleporter 1.0.10
>Reporter: Thierry Ygé
>Assignee: Robert Munteanu
>Priority: Blocker
> Fix For: JUnit Tests Teleporter 1.0.24
>
>  Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> Currently when using teleporter on jdk11 based environment, the teleporter is 
> failing due to missing class.
> {quote}java.lang.NoClassDefFoundError: javax/xml/bind/DatatypeConverter at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.setConnectionCredentials(TeleporterHttpClient.java:63)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.getHttpGetStatus(TeleporterHttpClient.java:136)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.waitForStatus(TeleporterHttpClient.java:75)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.installBundle(TeleporterHttpClient.java:94)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.installTestBundle(ClientSideTeleporter.java:173)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.access$000(ClientSideTeleporter.java:45)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter$2.evaluate(ClientSideTeleporter.java:207)
>  at 
> com.adobe.granite.testing.serverside.rules.GraniteSSTRule$1.evaluate(GraniteSSTRule.java:104)
> {quote}
> This is due to jdk not containing this package anymore since jdk 9.
> Teleporter used is 1.0.10 and with 1.0.20 I couldn't use it as it fails with 
> missing osgi core dependency, unless I would then add it manually in the test 
> module pom.
> Note from [~bdelacretaz]
> As per 
> [https://stackoverflow.com/questions/52502189/java-11-package-javax-xml-bind-does-not-exist]
>  it looks like using {{jakarta.xml.bind}} as an additional dependency might 
> fix this.



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


[jira] [Resolved] (SLING-12276) Update to java-html-sanitizer 20240325.1

2024-04-12 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12276.
-
Resolution: Fixed

> Update to java-html-sanitizer 20240325.1
> 
>
> Key: SLING-12276
> URL: https://issues.apache.org/jira/browse/SLING-12276
> Project: Sling
>  Issue Type: Improvement
>  Components: XSS Protection API
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: XSS Protection API 2.4.2
>
>
> A new Java HTML Sanitizer version is out, notably removing the dependency on 
> Guava ( 
> https://github.com/OWASP/java-html-sanitizer/releases/tag/release-20240325.1 
> ).
> This will allow us to remove:
> - the embedding of Guava classes, cutting down on bundle size
> - the shading of the Guava classes, reducing the complexity of the pom



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


[jira] [Updated] (SLING-12291) Broken backwards compatibility for duplicated keys

2024-04-12 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12291:

Fix Version/s: Commons JSON 2.0.26
   (was: Commons JSON 2.0.24)

> Broken backwards compatibility for duplicated keys
> --
>
> Key: SLING-12291
> URL: https://issues.apache.org/jira/browse/SLING-12291
> Project: Sling
>  Issue Type: Bug
>Affects Versions: Commons JSON 2.0.24
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.26
>
>
> The fix of CVE-2022-47937 introduced an invalid backwards compatibility for 
> duplicated keys in a json.
> New behaviour: throws an exception on duplicated keys
> Old behaviour: ignores the fact and is able to process json with duplicated 
> keys.
> To no break existing users of the library, reestablish the old behaviour.



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


[jira] [Resolved] (SLING-12291) Broken backwards compatibility for duplicated keys

2024-04-12 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12291.
-
Resolution: Fixed

PR applied, thanks [~rliechti]!

> Broken backwards compatibility for duplicated keys
> --
>
> Key: SLING-12291
> URL: https://issues.apache.org/jira/browse/SLING-12291
> Project: Sling
>  Issue Type: Bug
>Affects Versions: Commons JSON 2.0.24
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.24
>
>
> The fix of CVE-2022-47937 introduced an invalid backwards compatibility for 
> duplicated keys in a json.
> New behaviour: throws an exception on duplicated keys
> Old behaviour: ignores the fact and is able to process json with duplicated 
> keys.
> To no break existing users of the library, reestablish the old behaviour.



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


[jira] [Assigned] (SLING-12291) Broken backwards compatibility for duplicated keys

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12291:
---

Assignee: Remo Liechti

> Broken backwards compatibility for duplicated keys
> --
>
> Key: SLING-12291
> URL: https://issues.apache.org/jira/browse/SLING-12291
> Project: Sling
>  Issue Type: Bug
>Affects Versions: Commons JSON 2.0.24
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.24
>
>
> The fix of CVE-2022-47937 introduced an invalid backwards compatibility for 
> duplicated keys in a json.
> New behaviour: throws an exception on duplicated keys
> Old behaviour: ignores the fact and is able to process json with duplicated 
> keys.
> To no break existing users of the library, reestablish the old behaviour.



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


[jira] [Updated] (SLING-12291) Broken backwards compatibility for duplicated keys

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12291:

Fix Version/s: Commons JSON 2.0.24

> Broken backwards compatibility for duplicated keys
> --
>
> Key: SLING-12291
> URL: https://issues.apache.org/jira/browse/SLING-12291
> Project: Sling
>  Issue Type: Bug
>Affects Versions: Commons JSON 2.0.24
>Reporter: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.24
>
>
> The fix of CVE-2022-47937 introduced an invalid backwards compatibility for 
> duplicated keys in a json.
> New behaviour: throws an exception on duplicated keys
> Old behaviour: ignores the fact and is able to process json with duplicated 
> keys.
> To no break existing users of the library, reestablish the old behaviour.



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


[jira] [Resolved] (SLING-12290) Update tenant module to use parent pom 52

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12290.
-
Resolution: Fixed

> Update tenant module to use parent pom 52
> -
>
> Key: SLING-12290
> URL: https://issues.apache.org/jira/browse/SLING-12290
> Project: Sling
>  Issue Type: Task
>  Components: Extensions
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Tenant 1.1.8
>
>




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


[jira] [Created] (SLING-12290) Update tenant module to use parent pom 52

2024-04-11 Thread Robert Munteanu (Jira)
Robert Munteanu created SLING-12290:
---

 Summary: Update tenant module to use parent pom 52
 Key: SLING-12290
 URL: https://issues.apache.org/jira/browse/SLING-12290
 Project: Sling
  Issue Type: Task
  Components: Extensions
Reporter: Robert Munteanu
Assignee: Robert Munteanu
 Fix For: Tenant 1.1.8






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


[jira] [Resolved] (SLING-12285) adding bind & unbind methods mapping in reference annotation

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12285.
-
Resolution: Fixed

> adding bind & unbind methods mapping in reference annotation
> 
>
> Key: SLING-12285
> URL: https://issues.apache.org/jira/browse/SLING-12285
> Project: Sling
>  Issue Type: Bug
>  Components: Extensions
>Reporter: Gagan Malpani
>Assignee: Gagan Malpani
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> adding bind & unbind methods mapping in reference annotation for 
> tenantproviderimpl



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


[jira] [Assigned] (SLING-12285) adding bind & unbind methods mapping in reference annotation

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12285:
---

Assignee: Gagan Malpani

> adding bind & unbind methods mapping in reference annotation
> 
>
> Key: SLING-12285
> URL: https://issues.apache.org/jira/browse/SLING-12285
> Project: Sling
>  Issue Type: Bug
>  Components: General
>Reporter: Gagan Malpani
>Assignee: Gagan Malpani
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> adding bind & unbind methods mapping in reference annotation for 
> tenantproviderimpl



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


[jira] [Updated] (SLING-12285) adding bind & unbind methods mapping in reference annotation

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12285:

Component/s: Extensions
 (was: General)

> adding bind & unbind methods mapping in reference annotation
> 
>
> Key: SLING-12285
> URL: https://issues.apache.org/jira/browse/SLING-12285
> Project: Sling
>  Issue Type: Bug
>  Components: Extensions
>Reporter: Gagan Malpani
>Assignee: Gagan Malpani
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> adding bind & unbind methods mapping in reference annotation for 
> tenantproviderimpl



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


[jira] [Updated] (SLING-12285) adding bind & unbind methods mapping in reference annotation

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12285:

Issue Type: Bug  (was: Improvement)

> adding bind & unbind methods mapping in reference annotation
> 
>
> Key: SLING-12285
> URL: https://issues.apache.org/jira/browse/SLING-12285
> Project: Sling
>  Issue Type: Bug
>  Components: General
>Reporter: Gagan Malpani
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> adding bind & unbind methods mapping in reference annotation for 
> tenantproviderimpl



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


[jira] [Resolved] (SLING-12286) Tenant build fails with Java 17 or newer

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12286.
-
Resolution: Fixed

> Tenant build fails with Java 17 or newer
> 
>
> Key: SLING-12286
> URL: https://issues.apache.org/jira/browse/SLING-12286
> Project: Sling
>  Issue Type: Bug
>  Components: Extensions
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> [ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.038 
> s <<< FAILURE! - in org.apache.sling.tenant.internal.TenantProviderImplTest
> [ERROR] 
> org.apache.sling.tenant.internal.TenantProviderImplTest.testListTenantsWithoutTenantRoot
>   Time elapsed: 0.036 s  <<< ERROR!
> java.lang.ExceptionInInitializerError
>   at 
> org.mockito.cglib.core.KeyFactory$Generator.generateClass(KeyFactory.java:167)



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


[jira] [Updated] (SLING-12286) Tenant build fails with Java 17 or newer

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12286:

Summary: Tenant build fails with Java 17 or newer  (was: Tenat build fails 
with Java 17 or newer)

> Tenant build fails with Java 17 or newer
> 
>
> Key: SLING-12286
> URL: https://issues.apache.org/jira/browse/SLING-12286
> Project: Sling
>  Issue Type: Bug
>  Components: Extensions
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> [ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.038 
> s <<< FAILURE! - in org.apache.sling.tenant.internal.TenantProviderImplTest
> [ERROR] 
> org.apache.sling.tenant.internal.TenantProviderImplTest.testListTenantsWithoutTenantRoot
>   Time elapsed: 0.036 s  <<< ERROR!
> java.lang.ExceptionInInitializerError
>   at 
> org.mockito.cglib.core.KeyFactory$Generator.generateClass(KeyFactory.java:167)



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


[jira] [Created] (SLING-12286) Tenat build fails with Java 17 or newer

2024-04-11 Thread Robert Munteanu (Jira)
Robert Munteanu created SLING-12286:
---

 Summary: Tenat build fails with Java 17 or newer
 Key: SLING-12286
 URL: https://issues.apache.org/jira/browse/SLING-12286
 Project: Sling
  Issue Type: Bug
  Components: Extensions
Reporter: Robert Munteanu
Assignee: Robert Munteanu
 Fix For: Tenant 1.1.8


[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.038 s 
<<< FAILURE! - in org.apache.sling.tenant.internal.TenantProviderImplTest
[ERROR] 
org.apache.sling.tenant.internal.TenantProviderImplTest.testListTenantsWithoutTenantRoot
  Time elapsed: 0.036 s  <<< ERROR!
java.lang.ExceptionInInitializerError
at 
org.mockito.cglib.core.KeyFactory$Generator.generateClass(KeyFactory.java:167)



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


[jira] [Updated] (SLING-12285) adding bind & unbind methods mapping in reference annotation

2024-04-11 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12285:

Fix Version/s: Tenant 1.1.8

> adding bind & unbind methods mapping in reference annotation
> 
>
> Key: SLING-12285
> URL: https://issues.apache.org/jira/browse/SLING-12285
> Project: Sling
>  Issue Type: Improvement
>  Components: General
>Reporter: Gagan Malpani
>Priority: Major
> Fix For: Tenant 1.1.8
>
>
> adding bind & unbind methods mapping in reference annotation for 
> tenantproviderimpl



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


[jira] [Commented] (SLING-12285) adding bind & unbind methods mapping in reference annotation

2024-04-10 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12285:
-

Thanks for the report [~malp...@adobe.com]. Is this an actual bug? How does 
this manifest (log entries, etc)?

> adding bind & unbind methods mapping in reference annotation
> 
>
> Key: SLING-12285
> URL: https://issues.apache.org/jira/browse/SLING-12285
> Project: Sling
>  Issue Type: Improvement
>  Components: General
>Reporter: Gagan Malpani
>Priority: Major
>
> adding bind & unbind methods mapping in reference annotation for 
> tenantproviderimpl



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


[jira] [Commented] (SLING-9327) Teleporter not working with jdk11 due to missing xml bind classes

2024-04-08 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-9327:


I've created a PR to remove the commons-codec dependency, I don't see how that 
can be needed. I'll try to get some proper tests running before merging.

> Teleporter not working with jdk11 due to missing xml bind classes
> -
>
> Key: SLING-9327
> URL: https://issues.apache.org/jira/browse/SLING-9327
> Project: Sling
>  Issue Type: Bug
>  Components: Testing
>Affects Versions: JUnit Tests Teleporter 1.0.10
>Reporter: Thierry Ygé
>Assignee: Robert Munteanu
>Priority: Blocker
> Fix For: JUnit Tests Teleporter 1.0.24
>
>  Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> Currently when using teleporter on jdk11 based environment, the teleporter is 
> failing due to missing class.
> {quote}java.lang.NoClassDefFoundError: javax/xml/bind/DatatypeConverter at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.setConnectionCredentials(TeleporterHttpClient.java:63)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.getHttpGetStatus(TeleporterHttpClient.java:136)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.waitForStatus(TeleporterHttpClient.java:75)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.installBundle(TeleporterHttpClient.java:94)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.installTestBundle(ClientSideTeleporter.java:173)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.access$000(ClientSideTeleporter.java:45)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter$2.evaluate(ClientSideTeleporter.java:207)
>  at 
> com.adobe.granite.testing.serverside.rules.GraniteSSTRule$1.evaluate(GraniteSSTRule.java:104)
> {quote}
> This is due to jdk not containing this package anymore since jdk 9.
> Teleporter used is 1.0.10 and with 1.0.20 I couldn't use it as it fails with 
> missing osgi core dependency, unless I would then add it manually in the test 
> module pom.
> Note from [~bdelacretaz]
> As per 
> [https://stackoverflow.com/questions/52502189/java-11-package-javax-xml-bind-does-not-exist]
>  it looks like using {{jakarta.xml.bind}} as an additional dependency might 
> fix this.



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


[jira] [Assigned] (SLING-9327) Teleporter not working with jdk11 due to missing xml bind classes

2024-04-08 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-9327:
--

Assignee: Robert Munteanu

> Teleporter not working with jdk11 due to missing xml bind classes
> -
>
> Key: SLING-9327
> URL: https://issues.apache.org/jira/browse/SLING-9327
> Project: Sling
>  Issue Type: Bug
>  Components: Testing
>Affects Versions: JUnit Tests Teleporter 1.0.10
>Reporter: Thierry Ygé
>Assignee: Robert Munteanu
>Priority: Blocker
> Fix For: JUnit Tests Teleporter 1.0.24
>
>  Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> Currently when using teleporter on jdk11 based environment, the teleporter is 
> failing due to missing class.
> {quote}java.lang.NoClassDefFoundError: javax/xml/bind/DatatypeConverter at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.setConnectionCredentials(TeleporterHttpClient.java:63)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.getHttpGetStatus(TeleporterHttpClient.java:136)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.waitForStatus(TeleporterHttpClient.java:75)
>  at 
> org.apache.sling.testing.teleporter.client.TeleporterHttpClient.installBundle(TeleporterHttpClient.java:94)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.installTestBundle(ClientSideTeleporter.java:173)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter.access$000(ClientSideTeleporter.java:45)
>  at 
> org.apache.sling.testing.teleporter.client.ClientSideTeleporter$2.evaluate(ClientSideTeleporter.java:207)
>  at 
> com.adobe.granite.testing.serverside.rules.GraniteSSTRule$1.evaluate(GraniteSSTRule.java:104)
> {quote}
> This is due to jdk not containing this package anymore since jdk 9.
> Teleporter used is 1.0.10 and with 1.0.20 I couldn't use it as it fails with 
> missing osgi core dependency, unless I would then add it manually in the test 
> module pom.
> Note from [~bdelacretaz]
> As per 
> [https://stackoverflow.com/questions/52502189/java-11-package-javax-xml-bind-does-not-exist]
>  it looks like using {{jakarta.xml.bind}} as an additional dependency might 
> fix this.



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


[jira] [Assigned] (SLING-12276) Update to java-html-sanitizer 20240325.1

2024-03-26 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12276:
---

Assignee: Robert Munteanu

> Update to java-html-sanitizer 20240325.1
> 
>
> Key: SLING-12276
> URL: https://issues.apache.org/jira/browse/SLING-12276
> Project: Sling
>  Issue Type: Improvement
>  Components: XSS Protection API
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: XSS Protection API 2.4.2
>
>
> A new Java HTML Sanitizer version is out, notably removing the dependency on 
> Guava ( 
> https://github.com/OWASP/java-html-sanitizer/releases/tag/release-20240325.1 
> ).
> This will allow us to remove:
> - the embedding of Guava classes, cutting down on bundle size
> - the shading of the Guava classes, reducing the complexity of the pom



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


[jira] [Created] (SLING-12276) Update to java-html-sanitizer 20240325.1

2024-03-26 Thread Robert Munteanu (Jira)
Robert Munteanu created SLING-12276:
---

 Summary: Update to java-html-sanitizer 20240325.1
 Key: SLING-12276
 URL: https://issues.apache.org/jira/browse/SLING-12276
 Project: Sling
  Issue Type: Improvement
  Components: XSS Protection API
Reporter: Robert Munteanu
 Fix For: XSS Protection API 2.4.2


A new Java HTML Sanitizer version is out, notably removing the dependency on 
Guava ( 
https://github.com/OWASP/java-html-sanitizer/releases/tag/release-20240325.1 ).

This will allow us to remove:
- the embedding of Guava classes, cutting down on bundle size
- the shading of the Guava classes, reducing the complexity of the pom



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


[jira] [Updated] (SLING-12272) Document org.apache.sling.models.annotations.apt.ValidatingAnnotationProcessor

2024-03-22 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12272:

Component/s: Sling Models

> Document org.apache.sling.models.annotations.apt.ValidatingAnnotationProcessor
> --
>
> Key: SLING-12272
> URL: https://issues.apache.org/jira/browse/SLING-12272
> Project: Sling
>  Issue Type: Improvement
>  Components: Documentation, Sling Models
>Reporter: Konrad Windszus
>Priority: Major
>
> With JDK 22 annotation processors will no longer be automatically executed by 
> javac (https://bugs.openjdk.org/browse/JDK-8306819). Instead they need to be 
> explicitly enabled with
> {code}
> -processor 
> {code}
> (https://docs.oracle.com/en/java/javase/17/docs/specs/man/javac.html#option-processor)
> That and a minimum description of what it does should be added to 
> https://sling.apache.org/documentation/bundles/models.html.



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


[jira] [Updated] (SLING-12272) Document org.apache.sling.models.annotations.apt.ValidatingAnnotationProcessor

2024-03-22 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12272:

Component/s: Documentation

> Document org.apache.sling.models.annotations.apt.ValidatingAnnotationProcessor
> --
>
> Key: SLING-12272
> URL: https://issues.apache.org/jira/browse/SLING-12272
> Project: Sling
>  Issue Type: Improvement
>  Components: Documentation
>Reporter: Konrad Windszus
>Priority: Major
>
> With JDK 22 annotation processors will no longer be automatically executed by 
> javac (https://bugs.openjdk.org/browse/JDK-8306819). Instead they need to be 
> explicitly enabled with
> {code}
> -processor 
> {code}
> (https://docs.oracle.com/en/java/javase/17/docs/specs/man/javac.html#option-processor)
> That and a minimum description of what it does should be added to 
> https://sling.apache.org/documentation/bundles/models.html.



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


[jira] [Assigned] (SLING-12269) Changed behaviour in commons json when used as a dependency

2024-03-20 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12269:
---

Assignee: Remo Liechti

> Changed behaviour in commons json when used as a dependency
> ---
>
> Key: SLING-12269
> URL: https://issues.apache.org/jira/browse/SLING-12269
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Blocker
> Attachments: SLING-12269.patch
>
>
> With the new internal release 2.0.22, there seems to be a different behaviour 
> when it comes to get values from JSONObject.
> The new version checks for types and throws an exception, as of the old 
> version simply called toString() on any object found.
> *Old:*
> {code:java}
> public String getString(String key) throws JSONException {
>   return get(key).toString();
> }{code}
> *New:*
> {{}}
> {code:java}
> public String getString(String key) throws JSONException {
>   Objectobject=this.get(key);
>   if (objectinstanceofString) {
>     return (String) object;
>      }
>   throwwrongValueFormatException(key, "string", object, null);
> }{code}
>  
> Same is true for all other types, such as getInt, getLong etc.
> There might be more such small differences in behaviour.



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


[jira] [Resolved] (SLING-12269) Restore previous behaviour of JSONObject and JSONArray getString methods

2024-03-20 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12269.
-
Resolution: Fixed

Thanks for the PR [~rliechti], I have merged it.

> Restore previous behaviour of JSONObject and JSONArray getString methods
> 
>
> Key: SLING-12269
> URL: https://issues.apache.org/jira/browse/SLING-12269
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Blocker
> Fix For: Commons JSON 2.0.24
>
> Attachments: SLING-12269.patch
>
>
> With the new internal release 2.0.22, there seems to be a different behaviour 
> when it comes to get values from JSONObject.
> The new version checks for types and throws an exception, as of the old 
> version simply called toString() on any object found.
> *Old:*
> {code:java}
> public String getString(String key) throws JSONException {
>   return get(key).toString();
> }{code}
> *New:*
> {{}}
> {code:java}
> public String getString(String key) throws JSONException {
>   Objectobject=this.get(key);
>   if (objectinstanceofString) {
>     return (String) object;
>      }
>   throwwrongValueFormatException(key, "string", object, null);
> }{code}
>  
> Same is true for all other types, such as getInt, getLong etc.
> There might be more such small differences in behaviour.



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


[jira] [Updated] (SLING-12269) Restore previous behaviour of JSONObject and JSONArray getString methods

2024-03-20 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12269:

Summary: Restore previous behaviour of JSONObject and JSONArray getString 
methods  (was: Changed behaviour in commons json when used as a dependency)

> Restore previous behaviour of JSONObject and JSONArray getString methods
> 
>
> Key: SLING-12269
> URL: https://issues.apache.org/jira/browse/SLING-12269
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Blocker
> Attachments: SLING-12269.patch
>
>
> With the new internal release 2.0.22, there seems to be a different behaviour 
> when it comes to get values from JSONObject.
> The new version checks for types and throws an exception, as of the old 
> version simply called toString() on any object found.
> *Old:*
> {code:java}
> public String getString(String key) throws JSONException {
>   return get(key).toString();
> }{code}
> *New:*
> {{}}
> {code:java}
> public String getString(String key) throws JSONException {
>   Objectobject=this.get(key);
>   if (objectinstanceofString) {
>     return (String) object;
>      }
>   throwwrongValueFormatException(key, "string", object, null);
> }{code}
>  
> Same is true for all other types, such as getInt, getLong etc.
> There might be more such small differences in behaviour.



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


[jira] [Updated] (SLING-12268) Fix CVE-2022-47937

2024-03-20 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12268:

Fix Version/s: Commons JSON 2.0.24
   (was: Commons JSON 2.0.22)

> Fix CVE-2022-47937
> --
>
> Key: SLING-12268
> URL: https://issues.apache.org/jira/browse/SLING-12268
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.24
>
>
> Current version of apache commons json is affected by 
> [https://nvd.nist.gov/vuln/detail/CVE-2022-47937]
> Due to the relicenced base library ([https://github.com/stleary/JSON-java)], 
> that now uses the 'public domain', the fix of that CVE is as simple as 
> migrating to the latest codebase of said library.
> Along this, it would be beneficial to perform some side activities, such as 
> the upgrade to the latest parent pom and junit5.



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


[jira] [Updated] (SLING-12269) Restore previous behaviour of JSONObject and JSONArray getString methods

2024-03-20 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12269:

Fix Version/s: Commons JSON 2.0.24

> Restore previous behaviour of JSONObject and JSONArray getString methods
> 
>
> Key: SLING-12269
> URL: https://issues.apache.org/jira/browse/SLING-12269
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Blocker
> Fix For: Commons JSON 2.0.24
>
> Attachments: SLING-12269.patch
>
>
> With the new internal release 2.0.22, there seems to be a different behaviour 
> when it comes to get values from JSONObject.
> The new version checks for types and throws an exception, as of the old 
> version simply called toString() on any object found.
> *Old:*
> {code:java}
> public String getString(String key) throws JSONException {
>   return get(key).toString();
> }{code}
> *New:*
> {{}}
> {code:java}
> public String getString(String key) throws JSONException {
>   Objectobject=this.get(key);
>   if (objectinstanceofString) {
>     return (String) object;
>      }
>   throwwrongValueFormatException(key, "string", object, null);
> }{code}
>  
> Same is true for all other types, such as getInt, getLong etc.
> There might be more such small differences in behaviour.



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


[jira] [Commented] (SLING-12269) Changed behaviour in commons json when used as a dependency

2024-03-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12269:
-

Right, in this case the new version is more lenient and uses {{toString()}} 
instead of conditionally downcasting. That is a behaviour change indeed, but I 
am personally not very concerned about that as it will not break consumers 
relying on the old behaviour.

> Changed behaviour in commons json when used as a dependency
> ---
>
> Key: SLING-12269
> URL: https://issues.apache.org/jira/browse/SLING-12269
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Priority: Blocker
>
> With the new internal release 2.0.22, there seems to be a different behaviour 
> when it comes to get values from JSONObject.
> The new version checks for types and throws an exception, as of the old 
> version simply called toString() on any object found.
> *Old:*
> {{public String getString(String key) throws JSONException {}}
> {{  return get(key).toString();}}
> {{}}}
> *New:*
> {{public String getString(String key) throws JSONException {}}
> {{  Objectobject=this.get(key);}}
> {{  if (objectinstanceofString) {}}
> {{    return (String) object;}}
>      }
> {{  throwwrongValueFormatException(key, "string", object, null);}}
> {{}}}
>  
> Same is true for all other types, such as getInt, getLong etc.
> There might be more such small differences in behaviour.



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


[jira] [Updated] (SLING-12269) Changed behaviour in commons json when used as a dependency

2024-03-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12269:

Component/s: Commons

> Changed behaviour in commons json when used as a dependency
> ---
>
> Key: SLING-12269
> URL: https://issues.apache.org/jira/browse/SLING-12269
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Priority: Blocker
>
> With the new internal release 2.0.22, there seems to be a different behaviour 
> when it comes to get values from JSONObject.
> The new version checks for types and throws an exception, as of the old 
> version simply called toString() on any object found.
> *Old:*
> {{public String getString(String key) throws JSONException {}}
> {{  return get(key).toString();}}
> {{}}}
> *New:*
> {{public String getString(String key) throws JSONException {}}
> {{  Objectobject=this.get(key);}}
> {{  if (objectinstanceofString) {}}
> {{    return (String) object;}}
>      }
> {{  throwwrongValueFormatException(key, "string", object, null);}}
> {{}}}
>  
> Same is true for all other types, such as getInt, getLong etc.
> There might be more such small differences in behaviour.



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


[jira] [Commented] (SLING-12269) Changed behaviour in commons json when used as a dependency

2024-03-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12269:
-

Thanks for the report [~rliechti]. I would like to understand what methods are 
affected, so here's a comparison table:

||Method||Version 2.0.20|| Version 2.0.22|| Change? ||
|JSONObject.getString| 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L487-L489|
  
https://github.com/apache/sling-org-apache-sling-commons-json/blob/7a15fe774b6892c770af4d7ad12aa1d1bd7f976c/src/main/java/org/apache/sling/commons/json/JSONObject.java#L913-L919
 | (!) Yes, 2.0.22 fails if value is not string |
| JSONObject.getBoolean | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L375-L388
 | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/7a15fe774b6892c770af4d7ad12aa1d1bd7f976c/src/main/java/org/apache/sling/commons/json/JSONObject.java#L663-L675
 | No, both versions need either "true" or "false", case insensitive |
| JSonObject.getDouble | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L398-L408
 | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L398-L408
 | No, both versions check for {{Number}} and try to parse if needed |
| JSonObject.getInt | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L420-L424
 | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/7a15fe774b6892c770af4d7ad12aa1d1bd7f976c/src/main/java/org/apache/sling/commons/json/JSONObject.java#L795-L805
 | No, both versions check for {{Number}} and try to parse if needed |
| JSONObject.getJSONArray | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L435-L442
 | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/7a15fe774b6892c770af4d7ad12aa1d1bd7f976c/src/main/java/org/apache/sling/commons/json/JSONObject.java#L817-L823
 | No, both versions throw exceptions if the instanceof check fails |
| JSONObject.getJSONObject | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L453-L460
 | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/7a15fe774b6892c770af4d7ad12aa1d1bd7f976c/src/main/java/org/apache/sling/commons/json/JSONObject.java#L835-L841
 | No, both versions throw exceptions if the instanceof check fails |
| JSONObject.getLong | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/43d3030dbb967232d129ed19f79d0b89b82f4965/src/main/java/org/apache/sling/commons/json/JSONObject.java#L472-L477
 | 
https://github.com/apache/sling-org-apache-sling-commons-json/blob/7a15fe774b6892c770af4d7ad12aa1d1bd7f976c/src/main/java/org/apache/sling/commons/json/JSONObject.java#L854-L864
 | No, both versions check for {{Number}} and try to parse if needed |

It looks to me like {{getString}} is the only problematic change. Do you see 
anything else?

> Changed behaviour in commons json when used as a dependency
> ---
>
> Key: SLING-12269
> URL: https://issues.apache.org/jira/browse/SLING-12269
> Project: Sling
>  Issue Type: Bug
>Reporter: Remo Liechti
>Priority: Blocker
>
> With the new internal release 2.0.22, there seems to be a different behaviour 
> when it comes to get values from JSONObject.
> The new version checks for types and throws an exception, as of the old 
> version simply called toString() on any object found.
> *Old:*
> {{public String getString(String key) throws JSONException {}}
> {{  return get(key).toString();}}
> {{}}}
> *New:*
> {{public String getString(String key) throws JSONException {}}
> {{  Objectobject=this.get(key);}}
> {{  if (objectinstanceofString) {}}
> {{    return (String) object;}}
>      }
> {{  throwwrongValueFormatException(key, "string", object, null);}}
> {{}}}
>  
> Same is true for all other types, such as getInt, getLong etc.
> There might be more such small differences in behaviour.



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


[jira] [Updated] (SLING-12268) Fix CVE-2022-47937

2024-03-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12268:

Fix Version/s: Commons JSON 2.0.22

> Fix CVE-2022-47937
> --
>
> Key: SLING-12268
> URL: https://issues.apache.org/jira/browse/SLING-12268
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.22
>
>
> Current version of apache commons json is affected by 
> [https://nvd.nist.gov/vuln/detail/CVE-2022-47937]
> Due to the relicenced base library ([https://github.com/stleary/JSON-java)], 
> that now uses the 'public domain', the fix of that CVE is as simple as 
> migrating to the latest codebase of said library.
> Along this, it would be beneficial to perform some side activities, such as 
> the upgrade to the latest parent pom and junit5.



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


[jira] [Resolved] (SLING-12268) Fix CVE-2022-47937

2024-03-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12268.
-
Resolution: Fixed

Thanks for the contribution [~rliechti]!

> Fix CVE-2022-47937
> --
>
> Key: SLING-12268
> URL: https://issues.apache.org/jira/browse/SLING-12268
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
> Fix For: Commons JSON 2.0.22
>
>
> Current version of apache commons json is affected by 
> [https://nvd.nist.gov/vuln/detail/CVE-2022-47937]
> Due to the relicenced base library ([https://github.com/stleary/JSON-java)], 
> that now uses the 'public domain', the fix of that CVE is as simple as 
> migrating to the latest codebase of said library.
> Along this, it would be beneficial to perform some side activities, such as 
> the upgrade to the latest parent pom and junit5.



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


[jira] [Assigned] (SLING-12268) Fix CVE-2022-47937

2024-03-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12268:
---

Assignee: Remo Liechti

> Fix CVE-2022-47937
> --
>
> Key: SLING-12268
> URL: https://issues.apache.org/jira/browse/SLING-12268
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Remo Liechti
>Assignee: Remo Liechti
>Priority: Major
>
> Current version of apache commons json is affected by 
> [https://nvd.nist.gov/vuln/detail/CVE-2022-47937]
> Due to the relicenced base library ([https://github.com/stleary/JSON-java)], 
> that now uses the 'public domain', the fix of that CVE is as simple as 
> migrating to the latest codebase of said library.
> Along this, it would be beneficial to perform some side activities, such as 
> the upgrade to the latest parent pom and junit5.



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


[jira] [Commented] (SLING-12262) Repoinit: report failures via metrics

2024-03-07 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12262:
-

Right, I was just expecting that the window of opportunity when these metrics 
are available to be quite short, as the instance would be taken down.

Not opposing the implementation, just asking :-)

> Repoinit: report failures via metrics
> -
>
> Key: SLING-12262
> URL: https://issues.apache.org/jira/browse/SLING-12262
> Project: Sling
>  Issue Type: Task
>  Components: Repoinit
>Affects Versions: Repoinit JCR 1.1.46
>Reporter: Joerg Hoh
>Priority: Major
>
> When a repoinit statement fails (and for that reason the SlingRepository 
> service cannot be started, repoinit should expose this as a metric.



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


[jira] [Commented] (SLING-12262) Repoinit: report failures via metrics

2024-03-05 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12262:
-

With the repository being unavailable, is there any point to the metrics with 
regards to repoinit failure being exposed/scraped? The instance is presumably 
unhealthy and should not be around for long.

> Repoinit: report failures via metrics
> -
>
> Key: SLING-12262
> URL: https://issues.apache.org/jira/browse/SLING-12262
> Project: Sling
>  Issue Type: Task
>  Components: Repoinit
>Affects Versions: Repoinit JCR 1.1.46
>Reporter: Joerg Hoh
>Priority: Major
>
> When a repoinit statement fails (and for that reason the SlingRepository 
> service cannot be started, repoinit should expose this as a metric.



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


[jira] [Closed] (SLING-12113) CPConverter: Improve error message "File being unzipped is too big" for Sling-Initial-Content

2024-03-04 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12113.
---

> CPConverter: Improve error message "File being unzipped is too big" for 
> Sling-Initial-Content
> -
>
> Key: SLING-12113
> URL: https://issues.apache.org/jira/browse/SLING-12113
> Project: Sling
>  Issue Type: Improvement
>  Components: Feature Model
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Stefan Seifert
>Assignee: Stefan Seifert
>Priority: Major
> Fix For: Content-Package to Feature Model Converter 1.3.6
>
>
> if you use an OSGi bundle with Sling-Initial-Content, and the size of the 
> unzipped content exceeds 100MB, currently an error messages without any 
> context (out of a complex build) is issued:
> {noformat}
> Caused by: java.lang.IllegalStateException: File being unzipped is too big.
> at 
> org.apache.sling.feature.cpconverter.handlers.slinginitialcontent.SlingInitialContentBundleEntryMetaDataCollector.collectFromContextAndWriteTmpFiles
>  (SlingInitialContentBundleEntryMetaDataCollector.java:105)
> at 
> org.apache.sling.feature.cpconverter.handlers.slinginitialcontent.BundleSlingInitialContentExtractor.extract
>  (BundleSlingInitialContentExtractor.java:80)
> at 
> org.apache.sling.feature.cpconverter.handlers.SlingInitialContentBundleHandler.processBundleInputStream
>  (SlingInitialContentBundleHandler.java:53)
> at 
> org.apache.sling.feature.cpconverter.handlers.BundleEntryHandler.handle 
> (BundleEntryHandler.java:141)
> ...
> {noformat}
> this error messages should be improved to include the actual file name, and 
> the actual limit that was hit (it's hard-coded 100MB in this case).



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


[jira] [Closed] (SLING-12254) jcr:data node missing for file resources generated in binaries index defintions

2024-03-04 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12254.
---

> jcr:data node missing for file resources generated in binaries index 
> defintions
> ---
>
> Key: SLING-12254
> URL: https://issues.apache.org/jira/browse/SLING-12254
> Project: Sling
>  Issue Type: Bug
>  Components: Content-Package to Feature Model Converter
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Abhishek Garg
>Assignee: Abhishek Garg
>Priority: Major
> Fix For: Content-Package to Feature Model Converter 1.3.6
>
>
> The index definition files generated by the cpcconvertor are missing 
> mandatory jcr:data nodes.
> How the resource should look:
> {code:java}
>     "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml"
>                 }
>             }
>         } 
> {code}
>  
> How it looks like now:
> {code:java}
>       "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
> 
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml",
>                     "jcr:data": ""
>                 }
>             }
>         } {code}
> There is no `jcr:data` node present
> This happens when node structure is like:
> {code:java}
>       
>             
>                                          jcr:primaryType="nt:unstructured"
>                         jcr:mimeType="text/xml"/>
>             
>           {code}



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


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

2024-02-29 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12197:

Fix Version/s: Content-Package to Feature Model Converter 1.3.8
   (was: Content-Package to Feature Model Converter 1.3.6)

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


[jira] [Updated] (SLING-11778) Test that the feature models generated by the CPConverter are deployable

2024-02-29 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-11778:

Fix Version/s: Content-Package to Feature Model Converter 1.3.8
   (was: Content-Package to Feature Model Converter 1.3.6)

> Test that the feature models generated by the CPConverter are deployable
> 
>
> Key: SLING-11778
> URL: https://issues.apache.org/jira/browse/SLING-11778
> Project: Sling
>  Issue Type: Improvement
>  Components: Content-Package to Feature Model Converter
>Reporter: Robert Munteanu
>Priority: Major
> Fix For: Content-Package to Feature Model Converter 1.3.8
>
>
> We have a set of tests in the CPConverter that validate what the output looks 
> like. I have a feeling that we would be better off if we would validate that 
> the  feature models and associated artifacts can actually be installed.
> We can do this by setting up a Sling application that contains the 
> prerequisites ( Oak/FileVault mostly ) and starting that application with the 
> feature models generated. The application can be parameterised to use 
> different FileVault versions, so we are certain that we don't run into 
> problems like SLING-11777 .
> We can then validate that
> - all bundles are started
> - all content packages are installed
> I think this would cover a gap that we have regarding validating the 
> correctness of the artifacts that we generate with the CPConverter.
> We don't have to start with a lot of tests, but having 1-3 content packages 
> with good coverages validated as "installable" would IMO be a great step 
> forward.



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


[jira] [Commented] (SLING-12254) jcr:data node missing for file resources generated in binaries index defintions

2024-02-23 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12254:
-

Thanks for the contribution [~abhigarg]!

> jcr:data node missing for file resources generated in binaries index 
> defintions
> ---
>
> Key: SLING-12254
> URL: https://issues.apache.org/jira/browse/SLING-12254
> Project: Sling
>  Issue Type: Bug
>  Components: Content-Package to Feature Model Converter
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Abhishek Garg
>Assignee: Abhishek Garg
>Priority: Major
> Fix For: Content-Package to Feature Model Converter 1.3.6
>
>
> The index definition files generated by the cpcconvertor are missing 
> mandatory jcr:data nodes.
> How the resource should look:
> {code:java}
>     "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml"
>                 }
>             }
>         } 
> {code}
>  
> How it looks like now:
> {code:java}
>       "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
> 
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml",
>                     "jcr:data": ""
>                 }
>             }
>         } {code}
> There is no `jcr:data` node present
> This happens when node structure is like:
> {code:java}
>       
>             
>                                          jcr:primaryType="nt:unstructured"
>                         jcr:mimeType="text/xml"/>
>             
>           {code}



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


[jira] [Resolved] (SLING-12254) jcr:data node missing for file resources generated in binaries index defintions

2024-02-23 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12254.
-
Fix Version/s: Content-Package to Feature Model Converter 1.3.6
   Resolution: Fixed

> jcr:data node missing for file resources generated in binaries index 
> defintions
> ---
>
> Key: SLING-12254
> URL: https://issues.apache.org/jira/browse/SLING-12254
> Project: Sling
>  Issue Type: Bug
>  Components: Content-Package to Feature Model Converter
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Abhishek Garg
>Assignee: Abhishek Garg
>Priority: Major
> Fix For: Content-Package to Feature Model Converter 1.3.6
>
>
> The index definition files generated by the cpcconvertor are missing 
> mandatory jcr:data nodes.
> How the resource should look:
> {code:java}
>     "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml"
>                 }
>             }
>         } 
> {code}
>  
> How it looks like now:
> {code:java}
>       "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
> 
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml",
>                     "jcr:data": ""
>                 }
>             }
>         } {code}
> There is no `jcr:data` node present
> This happens when node structure is like:
> {code:java}
>       
>             
>                                          jcr:primaryType="nt:unstructured"
>                         jcr:mimeType="text/xml"/>
>             
>           {code}



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


[jira] [Assigned] (SLING-12254) jcr:data node missing for file resources generated in binaries index defintions

2024-02-23 Thread Robert Munteanu (Jira)


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

Robert Munteanu reassigned SLING-12254:
---

Assignee: Abhishek Garg

> jcr:data node missing for file resources generated in binaries index 
> defintions
> ---
>
> Key: SLING-12254
> URL: https://issues.apache.org/jira/browse/SLING-12254
> Project: Sling
>  Issue Type: Bug
>  Components: Content-Package to Feature Model Converter
>Affects Versions: Content-Package to Feature Model Converter 1.3.4
>Reporter: Abhishek Garg
>Assignee: Abhishek Garg
>Priority: Major
>
> The index definition files generated by the cpcconvertor are missing 
> mandatory jcr:data nodes.
> How the resource should look:
> {code:java}
>     "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml"
>                 }
>             }
>         } 
> {code}
>  
> How it looks like now:
> {code:java}
>       "tika": {
>             "jcr:primaryType": "nam:nt:unstructured",
>             "config.xml": {
>                 "jcr:primaryType": "nam:nt:file",
> 
>                 "jcr:content": {
>                     "jcr:primaryType": "nam:nt:unstructured",
>                     "jcr:mimeType": "text/xml",
>                     "jcr:data": ""
>                 }
>             }
>         } {code}
> There is no `jcr:data` node present
> This happens when node structure is like:
> {code:java}
>       
>             
>                                          jcr:primaryType="nt:unstructured"
>                         jcr:mimeType="text/xml"/>
>             
>           {code}



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


[jira] [Closed] (SLING-12235) Upgrade logback version to 1.2.13

2024-02-06 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12235.
---

> Upgrade logback version to 1.2.13
> -
>
> Key: SLING-12235
> URL: https://issues.apache.org/jira/browse/SLING-12235
> Project: Sling
>  Issue Type: Task
>  Components: Commons
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.5.0
>
>
> Dependabot has fired off a couple of PRs for it
> - https://github.com/apache/sling-org-apache-sling-commons-log/pull/14
> - https://github.com/apache/sling-org-apache-sling-commons-log/pull/13



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


[jira] [Closed] (SLING-12240) Upgrade to parent pom 52 and Java 11

2024-02-06 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed SLING-12240.
---

> Upgrade to parent pom 52 and Java 11
> 
>
> Key: SLING-12240
> URL: https://issues.apache.org/jira/browse/SLING-12240
> Project: Sling
>  Issue Type: Improvement
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.5.0
>
>
> This way we can take advantage of the latest improvements.



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


[jira] [Commented] (SLING-12241) Anonymous testing client throws NPE

2024-02-02 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12241:
-

Thanks for the report [~etugarev]. As it stands, this issue is not actionable 
to Sling, we don't have access to "CQClient.class" or to "AEMCS". Can you 
please rephrase this in a way that is applicable to Sling?

> Anonymous testing client throws NPE
> ---
>
> Key: SLING-12241
> URL: https://issues.apache.org/jira/browse/SLING-12241
> Project: Sling
>  Issue Type: Bug
>  Components: Apache Sling Testing Clients
>Affects Versions: Apache Sling Testing Clients 3.0.22
>Reporter: Evgeny Tugarev
>Priority: Major
>
> When using the AEM testing Clients: anonymous client to access content on a 
> publish instance ( AEMCS)  the client throws an NPE
> to reproduce:
> {code:java}
>  anonymousPublish = cqBaseClassRule.publishRule.getClient(CQClient.class, 
> null, null);
>  anonymousPublish.doGet("/graphql/execute.json", 204);
> {code}
>  



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


[jira] [Updated] (SLING-12234) Commons Log builds fail on Windows

2024-01-29 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12234:

Fix Version/s: Commons Log 5.5.2
   (was: Commons Log 5.5.0)

> Commons Log builds fail on Windows
> --
>
> Key: SLING-12234
> URL: https://issues.apache.org/jira/browse/SLING-12234
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.5.2
>
>
> https://ci-builds.apache.org/blue/organizations/jenkins/Sling%2Fmodules%2Fsling-org-apache-sling-commons-log/detail/master/205/pipeline:
> {noformat}
> [ERROR] Tests run: 3, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 
> 19.585 s <<< FAILURE! - in 
> org.apache.sling.commons.log.logback.integration.ITPackagingData
> [ERROR] 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking
>   Time elapsed: 6.929 s  <<< ERROR!
> java.io.IOException: Access is denied
>   at java.base/java.io.WinNTFileSystem.createFileExclusively(Native 
> Method)
>   at java.base/java.io.File.createTempFile(File.java:2129)
>   at java.base/java.io.File.createTempFile(File.java:2175)
>   at org.ops4j.store.StoreFactory.anonymousStore(StoreFactory.java:100)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.getDefaultStore(TinyBundles.java:104)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.bundle(TinyBundles.java:50)
>   at 
> org.apache.sling.commons.log.logback.integration.PackagingDataTestUtil.createTestBundle(PackagingDataTestUtil.java:44)
>   at 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking(ITPackagingData.java:148)
>   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.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
>   at 
> org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
>   at 
> org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
>   at 
> org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runLeafWithRetry(ContainerTestRunner.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChildWithRetry(ContainerTestRunner.java:84)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:75)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:43)
>   at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
>   at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
>   at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
>   at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
>   at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
>   at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.invokeViaJUnit(JUnitProbeInvoker.java:124)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.findAndInvoke(JUnitProbeInvoker.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.call(JUnitProbeInvoker.java:73)
>   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.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:435)
>   at 
> org.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:408)
>   at 
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>   at 
> 

[jira] [Reopened] (SLING-12240) Upgrade to parent pom 52 and Java 11

2024-01-29 Thread Robert Munteanu (Jira)


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

Robert Munteanu reopened SLING-12240:
-

> Upgrade to parent pom 52 and Java 11
> 
>
> Key: SLING-12240
> URL: https://issues.apache.org/jira/browse/SLING-12240
> Project: Sling
>  Issue Type: Improvement
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.5.0
>
>
> This way we can take advantage of the latest improvements.



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


[jira] [Resolved] (SLING-12240) Upgrade to parent pom 52 and Java 11

2024-01-29 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12240.
-
Resolution: Fixed

> Upgrade to parent pom 52 and Java 11
> 
>
> Key: SLING-12240
> URL: https://issues.apache.org/jira/browse/SLING-12240
> Project: Sling
>  Issue Type: Improvement
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.5.0
>
>
> This way we can take advantage of the latest improvements.



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


[jira] [Commented] (SLING-11906) Migrate to slf4j 2.x

2024-01-24 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-11906:
-

[~kwin] - perhaps upgrading logback to 1.3.x. or 1.4.x in Commons Log will 
remove the need to import the old package; did not have the time to investigate.

> Migrate to slf4j 2.x
> 
>
> Key: SLING-11906
> URL: https://issues.apache.org/jira/browse/SLING-11906
> Project: Sling
>  Issue Type: Improvement
>Reporter: Eric Norman
>Priority: Major
> Fix For: Commons Log 6.0.0
>
>
> Increasingly more libraries have been migrating to slf4j 2.x (for example 
> logback 1.3+, tika 2.5+ and jetty 10+)
> To be compatible with those, the sling commons log bundle should migrate to 
> slf4j v2.x (and logback v1.4.x or v1.3.x?)
> It looks like slf4j 2.x exports both 2.x and 1.7.36 versions of the exported 
> packages, so it should hopefully be compatible with existing bundles that are 
> importing the 1.x version of the slf4j packages.



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


[jira] [Comment Edited] (SLING-11906) Migrate to slf4j 2.x

2024-01-24 Thread Robert Munteanu (Jira)


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

Robert Munteanu edited comment on SLING-11906 at 1/24/24 3:45 PM:
--

For the record, when trying to upgrade to slf4j 2.0.11 the following errors 
come up

- Oak bundles importing org.slf4j.event with narrow range
- Sling commons.log importing org.slf4j.event with narrow range
- missing serviceloader mediator capability

{noformat}
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-lucene:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-store-document:1.60.0: 
Bundle is importing package org.slf4j.event;version=[1.7,2) with start order 15 
but no bundle is exporting these for that start order in the required version 
range.
[ERROR] [bundle-packages] org.apache.sling:org.apache.sling.commons.log:5.4.2: 
Bundle is importing packages [Package org.slf4j.event;version=[1.7,2), Package 
org.slf4j.spi;version=[1.7,2)] with start order 1 but no bundle is exporting 
these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-commons:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-core:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-query-spi:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [requirements-capabilities] org.slf4j:slf4j-api:2.0.11: Artifact 
org.slf4j:slf4j-api:2.0.11 requires [slf4j.api/2.0.11] osgi.serviceloader; 
osgi.serviceloader=org.slf4j.spi.SLF4JServiceProvider; 
filter:="(osgi.serviceloader=org.slf4j.spi.SLF4JServiceProvider)" in start 
level 1 but no artifact is providing a matching capability in this start level.
{noformat}

-

Edit: the commons.log import is probably coming from the ch.qos.logback.classic 
packages that we wrap and re-export.


was (Author: rombert):
For the record, when trying to upgrade to slf4j 2.0.11 the following errors 
come up

- Oak bundles importing org.slf4j.event with narrow range
- Sling commons.log importing org.slf4j.event with narrow range
- missing serviceloader mediator capability

{noformat}
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-lucene:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-store-document:1.60.0: 
Bundle is importing package org.slf4j.event;version=[1.7,2) with start order 15 
but no bundle is exporting these for that start order in the required version 
range.
[ERROR] [bundle-packages] org.apache.sling:org.apache.sling.commons.log:5.4.2: 
Bundle is importing packages [Package org.slf4j.event;version=[1.7,2), Package 
org.slf4j.spi;version=[1.7,2)] with start order 1 but no bundle is exporting 
these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-commons:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-core:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-query-spi:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [requirements-capabilities] org.slf4j:slf4j-api:2.0.11: Artifact 
org.slf4j:slf4j-api:2.0.11 requires [slf4j.api/2.0.11] osgi.serviceloader; 
osgi.serviceloader=org.slf4j.spi.SLF4JServiceProvider; 
filter:="(osgi.serviceloader=org.slf4j.spi.SLF4JServiceProvider)" in start 
level 1 but no artifact is providing a matching capability in this start level.
{noformat}

> Migrate to slf4j 2.x
> 
>
> Key: SLING-11906
> URL: https://issues.apache.org/jira/browse/SLING-11906
> Project: Sling
>  Issue Type: Improvement
>Reporter: Eric Norman
>Priority: Major
> Fix For: Commons Log 6.0.0

[jira] [Commented] (SLING-11906) Migrate to slf4j 2.x

2024-01-24 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-11906:
-

For the record, when trying to upgrade to slf4j 2.0.11 the following errors 
come up

- Oak bundles importing org.slf4j.event with narrow range
- Sling commons.log importing org.slf4j.event with narrow range
- missing serviceloader mediator capability

{noformat}
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-lucene:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-store-document:1.60.0: 
Bundle is importing package org.slf4j.event;version=[1.7,2) with start order 15 
but no bundle is exporting these for that start order in the required version 
range.
[ERROR] [bundle-packages] org.apache.sling:org.apache.sling.commons.log:5.4.2: 
Bundle is importing packages [Package org.slf4j.event;version=[1.7,2), Package 
org.slf4j.spi;version=[1.7,2)] with start order 1 but no bundle is exporting 
these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-commons:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-core:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [bundle-packages] org.apache.jackrabbit:oak-query-spi:1.60.0: Bundle is 
importing package org.slf4j.event;version=[1.7,2) with start order 15 but no 
bundle is exporting these for that start order in the required version range.
[ERROR] [requirements-capabilities] org.slf4j:slf4j-api:2.0.11: Artifact 
org.slf4j:slf4j-api:2.0.11 requires [slf4j.api/2.0.11] osgi.serviceloader; 
osgi.serviceloader=org.slf4j.spi.SLF4JServiceProvider; 
filter:="(osgi.serviceloader=org.slf4j.spi.SLF4JServiceProvider)" in start 
level 1 but no artifact is providing a matching capability in this start level.
{noformat}

> Migrate to slf4j 2.x
> 
>
> Key: SLING-11906
> URL: https://issues.apache.org/jira/browse/SLING-11906
> Project: Sling
>  Issue Type: Improvement
>Reporter: Eric Norman
>Priority: Major
> Fix For: Commons Log 6.0.0
>
>
> Increasingly more libraries have been migrating to slf4j 2.x (for example 
> logback 1.3+, tika 2.5+ and jetty 10+)
> To be compatible with those, the sling commons log bundle should migrate to 
> slf4j v2.x (and logback v1.4.x or v1.3.x?)
> It looks like slf4j 2.x exports both 2.x and 1.7.36 versions of the exported 
> packages, so it should hopefully be compatible with existing bundles that are 
> importing the 1.x version of the slf4j packages.



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


[jira] [Created] (SLING-12240) Upgrade to parent pom 52 and Java 11

2024-01-24 Thread Robert Munteanu (Jira)
Robert Munteanu created SLING-12240:
---

 Summary: Upgrade to parent pom 52 and Java 11
 Key: SLING-12240
 URL: https://issues.apache.org/jira/browse/SLING-12240
 Project: Sling
  Issue Type: Improvement
Reporter: Robert Munteanu
Assignee: Robert Munteanu
 Fix For: Commons Log 5.4.4


This way we can take advantage of the latest improvements.



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


[jira] [Resolved] (SLING-12235) Upgrade logback version to 1.2.13

2024-01-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu resolved SLING-12235.
-
Resolution: Fixed

> Upgrade logback version to 1.2.13
> -
>
> Key: SLING-12235
> URL: https://issues.apache.org/jira/browse/SLING-12235
> Project: Sling
>  Issue Type: Task
>  Components: Commons
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.4.4
>
>
> Dependabot has fired off a couple of PRs for it
> - https://github.com/apache/sling-org-apache-sling-commons-log/pull/14
> - https://github.com/apache/sling-org-apache-sling-commons-log/pull/13



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


[jira] [Commented] (SLING-12234) Commons Log builds fail on Windows

2024-01-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12234:
-

[~joerghoh] - I haven't seen this so far, no. It may be indeed a problem with 
the temp dir, which means that perhaps we need to talk to the infra team about 
it. I haven't seen a simple way to configure TinyBundles to use a different 
directory.

> Commons Log builds fail on Windows
> --
>
> Key: SLING-12234
> URL: https://issues.apache.org/jira/browse/SLING-12234
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.4.4
>
>
> https://ci-builds.apache.org/blue/organizations/jenkins/Sling%2Fmodules%2Fsling-org-apache-sling-commons-log/detail/master/205/pipeline:
> {noformat}
> [ERROR] Tests run: 3, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 
> 19.585 s <<< FAILURE! - in 
> org.apache.sling.commons.log.logback.integration.ITPackagingData
> [ERROR] 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking
>   Time elapsed: 6.929 s  <<< ERROR!
> java.io.IOException: Access is denied
>   at java.base/java.io.WinNTFileSystem.createFileExclusively(Native 
> Method)
>   at java.base/java.io.File.createTempFile(File.java:2129)
>   at java.base/java.io.File.createTempFile(File.java:2175)
>   at org.ops4j.store.StoreFactory.anonymousStore(StoreFactory.java:100)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.getDefaultStore(TinyBundles.java:104)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.bundle(TinyBundles.java:50)
>   at 
> org.apache.sling.commons.log.logback.integration.PackagingDataTestUtil.createTestBundle(PackagingDataTestUtil.java:44)
>   at 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking(ITPackagingData.java:148)
>   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.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
>   at 
> org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
>   at 
> org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
>   at 
> org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runLeafWithRetry(ContainerTestRunner.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChildWithRetry(ContainerTestRunner.java:84)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:75)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:43)
>   at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
>   at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
>   at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
>   at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
>   at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
>   at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.invokeViaJUnit(JUnitProbeInvoker.java:124)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.findAndInvoke(JUnitProbeInvoker.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.call(JUnitProbeInvoker.java:73)
>   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.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:435)
>   at 
> org.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:408)
>   at 
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   

[jira] [Commented] (SLING-12234) Commons Log builds fail on Windows

2024-01-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12234:
-

For now, I have restricted the CI builds to Linux only ( 
https://github.com/apache/sling-org-apache-sling-commons-log/pull/16 ) in order 
to have passing builds.

> Commons Log builds fail on Windows
> --
>
> Key: SLING-12234
> URL: https://issues.apache.org/jira/browse/SLING-12234
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.4.4
>
>
> https://ci-builds.apache.org/blue/organizations/jenkins/Sling%2Fmodules%2Fsling-org-apache-sling-commons-log/detail/master/205/pipeline:
> {noformat}
> [ERROR] Tests run: 3, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 
> 19.585 s <<< FAILURE! - in 
> org.apache.sling.commons.log.logback.integration.ITPackagingData
> [ERROR] 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking
>   Time elapsed: 6.929 s  <<< ERROR!
> java.io.IOException: Access is denied
>   at java.base/java.io.WinNTFileSystem.createFileExclusively(Native 
> Method)
>   at java.base/java.io.File.createTempFile(File.java:2129)
>   at java.base/java.io.File.createTempFile(File.java:2175)
>   at org.ops4j.store.StoreFactory.anonymousStore(StoreFactory.java:100)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.getDefaultStore(TinyBundles.java:104)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.bundle(TinyBundles.java:50)
>   at 
> org.apache.sling.commons.log.logback.integration.PackagingDataTestUtil.createTestBundle(PackagingDataTestUtil.java:44)
>   at 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking(ITPackagingData.java:148)
>   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.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
>   at 
> org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
>   at 
> org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
>   at 
> org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runLeafWithRetry(ContainerTestRunner.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChildWithRetry(ContainerTestRunner.java:84)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:75)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:43)
>   at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
>   at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
>   at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
>   at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
>   at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
>   at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.invokeViaJUnit(JUnitProbeInvoker.java:124)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.findAndInvoke(JUnitProbeInvoker.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.call(JUnitProbeInvoker.java:73)
>   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.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:435)
>   at 
> org.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:408)
>   at 
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> 

[jira] [Created] (SLING-12235) Upgrade logback version to 1.2.13

2024-01-19 Thread Robert Munteanu (Jira)
Robert Munteanu created SLING-12235:
---

 Summary: Upgrade logback version to 1.2.13
 Key: SLING-12235
 URL: https://issues.apache.org/jira/browse/SLING-12235
 Project: Sling
  Issue Type: Task
  Components: Commons
Reporter: Robert Munteanu
Assignee: Robert Munteanu
 Fix For: Commons Log 5.4.4


Dependabot has fired off a couple of PRs for it

- https://github.com/apache/sling-org-apache-sling-commons-log/pull/14
- https://github.com/apache/sling-org-apache-sling-commons-log/pull/13



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


[jira] [Commented] (SLING-12234) Commons Log builds fail on Windows

2024-01-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12234:
-

I've tried a couple of things:
- use a different store - 
https://github.com/apache/sling-org-apache-sling-commons-log/pull/15
- upgrade to tinybundles 4.0.0 - ITs fail with "Caused by: 
java.lang.ClassNotFoundException: org.ops4j.pax.tinybundles.core.TinyBundles"; 
probably pax-exam requires version 3.x
- upgrade to pax-exam 4.3.15 - as noted in the POM, ITs fail with 
"java.lang.ClassNotFoundException: org.slf4j.LoggerFactory"

I am out of ideas as this point.

[~olli] - does any of the above ring any bells to you?

> Commons Log builds fail on Windows
> --
>
> Key: SLING-12234
> URL: https://issues.apache.org/jira/browse/SLING-12234
> Project: Sling
>  Issue Type: Bug
>  Components: Commons
>Reporter: Robert Munteanu
>Priority: Major
> Fix For: Commons Log 5.4.4
>
>
> https://ci-builds.apache.org/blue/organizations/jenkins/Sling%2Fmodules%2Fsling-org-apache-sling-commons-log/detail/master/205/pipeline:
> {noformat}
> [ERROR] Tests run: 3, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 
> 19.585 s <<< FAILURE! - in 
> org.apache.sling.commons.log.logback.integration.ITPackagingData
> [ERROR] 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking
>   Time elapsed: 6.929 s  <<< ERROR!
> java.io.IOException: Access is denied
>   at java.base/java.io.WinNTFileSystem.createFileExclusively(Native 
> Method)
>   at java.base/java.io.File.createTempFile(File.java:2129)
>   at java.base/java.io.File.createTempFile(File.java:2175)
>   at org.ops4j.store.StoreFactory.anonymousStore(StoreFactory.java:100)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.getDefaultStore(TinyBundles.java:104)
>   at 
> org.ops4j.pax.tinybundles.core.TinyBundles.bundle(TinyBundles.java:50)
>   at 
> org.apache.sling.commons.log.logback.integration.PackagingDataTestUtil.createTestBundle(PackagingDataTestUtil.java:44)
>   at 
> org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking(ITPackagingData.java:148)
>   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.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
>   at 
> org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
>   at 
> org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
>   at 
> org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runLeafWithRetry(ContainerTestRunner.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChildWithRetry(ContainerTestRunner.java:84)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:75)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:43)
>   at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
>   at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
>   at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
>   at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
>   at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
>   at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
>   at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.invokeViaJUnit(JUnitProbeInvoker.java:124)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.findAndInvoke(JUnitProbeInvoker.java:97)
>   at 
> org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.call(JUnitProbeInvoker.java:73)
>   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 
> 

[jira] [Updated] (SLING-12234) Commons Log builds fail on Windows

2024-01-19 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12234:

Description: 
https://ci-builds.apache.org/blue/organizations/jenkins/Sling%2Fmodules%2Fsling-org-apache-sling-commons-log/detail/master/205/pipeline:
{noformat}
[ERROR] Tests run: 3, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 19.585 
s <<< FAILURE! - in 
org.apache.sling.commons.log.logback.integration.ITPackagingData
[ERROR] 
org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking
  Time elapsed: 6.929 s  <<< ERROR!
java.io.IOException: Access is denied
at java.base/java.io.WinNTFileSystem.createFileExclusively(Native 
Method)
at java.base/java.io.File.createTempFile(File.java:2129)
at java.base/java.io.File.createTempFile(File.java:2175)
at org.ops4j.store.StoreFactory.anonymousStore(StoreFactory.java:100)
at 
org.ops4j.pax.tinybundles.core.TinyBundles.getDefaultStore(TinyBundles.java:104)
at 
org.ops4j.pax.tinybundles.core.TinyBundles.bundle(TinyBundles.java:50)
at 
org.apache.sling.commons.log.logback.integration.PackagingDataTestUtil.createTestBundle(PackagingDataTestUtil.java:44)
at 
org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking(ITPackagingData.java:148)
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.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runLeafWithRetry(ContainerTestRunner.java:97)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChildWithRetry(ContainerTestRunner.java:84)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:75)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:43)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at 
org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.invokeViaJUnit(JUnitProbeInvoker.java:124)
at 
org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.findAndInvoke(JUnitProbeInvoker.java:97)
at 
org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.call(JUnitProbeInvoker.java:73)
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.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:435)
at 
org.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:408)
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 
java.rmi/sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:359)
at java.rmi/sun.rmi.transport.Transport$1.run(Transport.java:200)
at java.rmi/sun.rmi.transport.Transport$1.run(Transport.java:197)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.rmi/sun.rmi.transport.Transport.serviceCall(Transport.java:196)
at 

[jira] [Created] (SLING-12234) Commons Log builds fail on Windows

2024-01-19 Thread Robert Munteanu (Jira)
Robert Munteanu created SLING-12234:
---

 Summary: Commons Log builds fail on Windows
 Key: SLING-12234
 URL: https://issues.apache.org/jira/browse/SLING-12234
 Project: Sling
  Issue Type: Bug
  Components: Commons
Reporter: Robert Munteanu
 Fix For: Commons Log 5.4.4


https://ci-builds.apache.org/blue/organizations/jenkins/Sling%2Fmodules%2Fsling-org-apache-sling-commons-log/detail/master/205/pipeline:

[ERROR] Tests run: 3, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 19.585 
s <<< FAILURE! - in 
org.apache.sling.commons.log.logback.integration.ITPackagingData
[ERROR] 
org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking
  Time elapsed: 6.929 s  <<< ERROR!
java.io.IOException: Access is denied
at java.base/java.io.WinNTFileSystem.createFileExclusively(Native 
Method)
at java.base/java.io.File.createTempFile(File.java:2129)
at java.base/java.io.File.createTempFile(File.java:2175)
at org.ops4j.store.StoreFactory.anonymousStore(StoreFactory.java:100)
at 
org.ops4j.pax.tinybundles.core.TinyBundles.getDefaultStore(TinyBundles.java:104)
at 
org.ops4j.pax.tinybundles.core.TinyBundles.bundle(TinyBundles.java:50)
at 
org.apache.sling.commons.log.logback.integration.PackagingDataTestUtil.createTestBundle(PackagingDataTestUtil.java:44)
at 
org.apache.sling.commons.log.logback.integration.ITPackagingData.packageDataWorking(ITPackagingData.java:148)
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.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runLeafWithRetry(ContainerTestRunner.java:97)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChildWithRetry(ContainerTestRunner.java:84)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:75)
at 
org.ops4j.pax.exam.invoker.junit.internal.ContainerTestRunner.runChild(ContainerTestRunner.java:43)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at 
org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.invokeViaJUnit(JUnitProbeInvoker.java:124)
at 
org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.findAndInvoke(JUnitProbeInvoker.java:97)
at 
org.ops4j.pax.exam.invoker.junit.internal.JUnitProbeInvoker.call(JUnitProbeInvoker.java:73)
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.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:435)
at 
org.ops4j.pax.swissbox.framework.RemoteFrameworkImpl.invokeMethodOnService(RemoteFrameworkImpl.java:408)
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 
java.rmi/sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:359)
at java.rmi/sun.rmi.transport.Transport$1.run(Transport.java:200)
at java.rmi/sun.rmi.transport.Transport$1.run(Transport.java:197)
at 

[jira] [Closed] (FELIX-6672) Potentially losing comment state between reads on CommentRemovingReader

2024-01-17 Thread Robert Munteanu (Jira)


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

Robert Munteanu closed FELIX-6672.
--

> Potentially losing comment state between reads on CommentRemovingReader
> ---
>
> Key: FELIX-6672
> URL: https://issues.apache.org/jira/browse/FELIX-6672
> Project: Felix
>  Issue Type: Bug
>Affects Versions: cm.json-2.0.4
>Reporter: Dominik Süß
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: cm.json-2.0.6
>
>
> In more extensive testing on real world data I found a case that was not 
> properly handled in the rewrite towards BufferedReader. If. a read ends 
> between the first / and the subsequent / or * for comment start, the 
> detection will currently fail. 
> To fix this I refactored the detection logic that should now also be 
> significantly better readable always capturing the previous char on class 
> level allowing to check for char double char sequences that may be split by 
> the reads. 



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

2023-12-12 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12197:
-

I think we've talked about this quite a bit in different Jira issues/GitHub PRs 
... I need a bit of time to catch up :-)

> 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.6
>
> 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-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2023-12-04 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12173:
-

Opening an older project greeted me with a javax.json error, so this does not 
seem related to jakarta only.

{noformat}An internal error occurred during: "Building".
javax.json.spi.JsonProvider: org.apache.johnzon.core.JsonProviderImpl not a 
subtype{noformat}

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Bug
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.getProjectFacade(MavenBuilder.java:146)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.lambda$0(MavenBuilder.java:84)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> 

[jira] [Commented] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2023-12-04 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12173:
-

Good point [~cziegeler]. I have made the following change to the POM

{noformat}
diff --git a/pom.xml b/pom.xml
index 1172d97..d308a5b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -190,14 +190,13 @@
 
 jakarta.json
 jakarta.json-api
-2.0.2
+2.1.3
 compile
 
 
-org.apache.johnzon
-johnzon-core
-jakarta
-1.2.21
+org.eclipse.parsson
+parsson
+1.1.5
 compile
 
 
{noformat}

and it seems to work fine in Eclipse now. It did not work with jakata.json-api 
2.0.2 and parssson 1.0.3. I will keep working with this change locally for a 
while to make sure the problem does not reappear.

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Bug
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   at 
> 

[jira] [Comment Edited] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2023-12-01 Thread Robert Munteanu (Jira)


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

Robert Munteanu edited comment on SLING-12173 at 12/1/23 4:55 PM:
--

I tried switching the parser implementation to Parsson, but that did not help

{noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
org.eclipse.parsson.JsonProviderImpl not a subtype
at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
at jakarta.json.Json.createReader(Json.java:189){noformat}

This is very likely an Eclipse IDE problem.


was (Author: rombert):
OK, scratch that, I did a small POC with Parsson and I get the same problem

{noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
org.eclipse.parsson.JsonProviderImpl not a subtype
at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
at jakarta.json.Json.createReader(Json.java:189){noformat}

This is very likely an Eclipse IDE problem.

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Improvement
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> 

[jira] [Updated] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2023-12-01 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12173:

Issue Type: Bug  (was: Improvement)

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Bug
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. 
> I have noticed problems in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below).
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.getProjectFacade(MavenBuilder.java:146)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.lambda$0(MavenBuilder.java:84)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.execute(MavenBuilder.java:83)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder.build(MavenBuilder.java:192)
>   at 
> 

[jira] [Updated] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2023-12-01 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12173:

Description: 
The slingfeature-maven-plugin currently uses the Jakarta JSON implementation of 
the Apache Johnzon parser. 

I have noticed problems in the Eclipse IDE, where projects fail to update with 
hard to isolate errors (see below).

{noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
org.apache.johnzon.core.JsonProviderImpl not a subtype
at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
at jakarta.json.Json.createReader(Json.java:189)
at 
org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
at 
org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
at 
org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
at 
org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
at 
org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
at 
org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
at 
org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
at 
org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.getProjectFacade(MavenBuilder.java:146)
at 
org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.lambda$0(MavenBuilder.java:84)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
at 
org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
at 
org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.execute(MavenBuilder.java:83)
at 
org.eclipse.m2e.core.internal.builder.MavenBuilder.build(MavenBuilder.java:192)
at 
org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:1079)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
at 
org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:296)
at 
org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:352)
at 
org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:441)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
at 
org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:444)
at 
org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:555)

[jira] [Updated] (SLING-12173) Configuration errors in Eclipse for projects using the slingfeature-maven-plugin

2023-12-01 Thread Robert Munteanu (Jira)


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

Robert Munteanu updated SLING-12173:

Summary: Configuration errors in Eclipse for projects using the 
slingfeature-maven-plugin  (was: Switch JSON parser implementation away from 
Apache Johnzon)

> Configuration errors in Eclipse for projects using the 
> slingfeature-maven-plugin
> 
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Improvement
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. This works very well in 'clean' classpaths. 
> This is however problematic when both the jakarta.json and javax.json Johnzon 
> parser end up on the same classpath. 
> The main jar has the following entry
> - META-INF/services/javax.json.spi.JsonProvider = 
> org.apache.johnzon.core.JsonProviderImpl
> The {{-jakarta}} jar has the following entry
> - META-INF/services/jakarta.json.spi.JsonProvider = 
> org.apache.johnzon.core.JsonProviderImpl
> I have mostly seen this in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below). As a workaround, we could switch to 
> a different implementation.
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.readMavenProjectFacades(ProjectRegistryManager.java:760)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:392)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:366)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:318)
>   at 
> org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.getProjectFacade(MavenBuilder.java:146)
>   at 
> 

[jira] [Commented] (SLING-12173) Switch JSON parser implementation away from Apache Johnzon

2023-12-01 Thread Robert Munteanu (Jira)


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

Robert Munteanu commented on SLING-12173:
-

OK, scratch that, I did a small POC with Parsson and I get the same problem

{noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
org.eclipse.parsson.JsonProviderImpl not a subtype
at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
at 
java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
at jakarta.json.Json.createReader(Json.java:189){noformat}

This is very likely an Eclipse IDE problem.

> Switch JSON parser implementation away from Apache Johnzon
> --
>
> Key: SLING-12173
> URL: https://issues.apache.org/jira/browse/SLING-12173
> Project: Sling
>  Issue Type: Improvement
>  Components: Maven Plugins and Archetypes
>Reporter: Robert Munteanu
>Assignee: Robert Munteanu
>Priority: Major
> Fix For: OSGi Feature Maven Plugin 1.8.2
>
>
> The slingfeature-maven-plugin currently uses the Jakarta JSON implementation 
> of the Apache Johnzon parser. This works very well in 'clean' classpaths. 
> This is however problematic when both the jakarta.json and javax.json Johnzon 
> parser end up on the same classpath. 
> The main jar has the following entry
> - META-INF/services/javax.json.spi.JsonProvider = 
> org.apache.johnzon.core.JsonProviderImpl
> The {{-jakarta}} jar has the following entry
> - META-INF/services/jakarta.json.spi.JsonProvider = 
> org.apache.johnzon.core.JsonProviderImpl
> I have mostly seen this in the Eclipse IDE, where projects fail to update 
> with hard to isolate errors (see below). As a workaround, we could switch to 
> a different implementation.
> {noformat}java.util.ServiceConfigurationError: jakarta.json.spi.JsonProvider: 
> org.apache.johnzon.core.JsonProviderImpl not a subtype
>   at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:593)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1244)
>   at 
> java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1273)
>   at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1309)
>   at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1393)
>   at jakarta.json.spi.JsonProvider.provider(JsonProvider.java:69)
>   at jakarta.json.Json.createReader(Json.java:189)
>   at 
> org.apache.sling.feature.maven.JSONFeatures.read(JSONFeatures.java:64)
>   at 
> org.apache.sling.feature.maven.ProjectHelper.readFeatureFile(ProjectHelper.java:622)
>   at 
> org.apache.sling.feature.maven.Preprocessor.readProjectFeatures(Preprocessor.java:304)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:145)
>   at 
> org.apache.sling.feature.maven.Preprocessor.process(Preprocessor.java:110)
>   at 
> org.apache.sling.feature.maven.extensions.DependencyLifecycleParticipant.afterProjectsRead(DependencyLifecycleParticipant.java:87)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.executeParticipants(ProjectRegistryManager.java:824)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$15(ProjectRegistryManager.java:791)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$14(ProjectRegistryManager.java:790)
>   at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
>   at 
> org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.lambda$11(ProjectRegistryManager.java:788)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:394)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:275)
>   at 
> org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:214)
>   at 
> 

  1   2   3   4   5   6   7   8   9   10   >