This is an automated email from the ASF dual-hosted git repository.
kwin pushed a commit to branch provider-type-check-bnd-plugin
in repository https://gitbox.apache.org/repos/asf/sling-whiteboard.git
The following commit(s) were added to refs/heads/provider-type-check-bnd-plugin
by this push:
new 6bb4524a Refactoring of artifactId and packageNames to be in line with
https://github.com/apache/sling-org-apache-sling-caconfig-bnd-plugin/tree/master
6bb4524a is described below
commit 6bb4524a225fce07d324987dc9cc1fcfe19ad530
Author: Konrad Windszus <[email protected]>
AuthorDate: Tue Dec 5 16:46:27 2023 +0100
Refactoring of artifactId and packageNames to be in line with
https://github.com/apache/sling-org-apache-sling-caconfig-bnd-plugin/tree/master
---
org.apache.sling.bnd.providertype/pom.xml | 4 ++--
org.apache.sling.bnd.providertype/readme.md | 8 ++++----
.../bndplugin}/ProviderTypeScanner.java | 2 +-
.../bndplugin}/BndBuilderExtension.java | 2 +-
.../bndplugin}/ProviderTypeScannerTest.java | 6 +++---
.../sling/{bnd/providertype => providertype/bndplugin}/TypeA.java | 2 +-
.../{bnd/providertype => providertype/bndplugin}/TypeAImpl.java | 2 +-
.../sling/{bnd/providertype => providertype/bndplugin}/TypeB.java | 2 +-
.../providertype => providertype/bndplugin}/TypeBExtension.java | 2 +-
.../src/test/resources/META-INF/api-info.json | 2 +-
10 files changed, 16 insertions(+), 16 deletions(-)
diff --git a/org.apache.sling.bnd.providertype/pom.xml
b/org.apache.sling.bnd.providertype/pom.xml
index c451eebb..5e3bffdc 100644
--- a/org.apache.sling.bnd.providertype/pom.xml
+++ b/org.apache.sling.bnd.providertype/pom.xml
@@ -27,10 +27,10 @@
<version>52</version>
<relativePath />
</parent>
- <artifactId>org.apache.sling.bnd.providertype</artifactId>
+ <artifactId>org.apache.sling.providertype.bnd-plugin</artifactId>
<version>0.0.1-SNAPSHOT</version>
- <name>Apache Sling Bnd Provider Type Checker</name>
+ <name>Apache Sling Provider Type Checker Bnd Plugin</name>
<description>Bnd plugin enforcing that no class extends/implements a
provider type</description>
<properties>
diff --git a/org.apache.sling.bnd.providertype/readme.md
b/org.apache.sling.bnd.providertype/readme.md
index d502e59c..362b506d 100644
--- a/org.apache.sling.bnd.providertype/readme.md
+++ b/org.apache.sling.bnd.providertype/readme.md
@@ -1,6 +1,6 @@
[](https://sling.apache.org)
-# Apache Sling Bnd Provider Type Checker
+# Apache Sling Provider Type Checker Bnd Plugin
This module contains a [Bnd
plugin](https://bnd.bndtools.org/chapters/870-plugins.html) enforcing that no
class of the current bundle extends or implements a provider type. Note that
*using* a provider type (without implementing or extending it) is still allowed
(even for consumers).
@@ -18,7 +18,7 @@ For usage with Maven the Bnd plugin has to be added to the
plugin dependencies o
<dependencies>
<dependency>
<groupId>org.apache.sling</groupId>
- <artifactId>org.apache.sling.bnd.providertype</artifactId>
+ <artifactId>org.apache.sling.providertype.bnd-plugin</artifactId>
<version>1.0.0</version>
</dependency>
</dependencies>
@@ -28,13 +28,13 @@ For usage with Maven the Bnd plugin has to be added to the
plugin dependencies o
In addition the `bnd.bnd` file needs to register the Bnd plugin with the
[plugin instruction](https://bnd.bndtools.org/instructions/plugin.html)
```
--plugin.providertype:org.apache.sling.bnd.providertype.ProviderTypeScanner
+-plugin.providertype:org.apache.sling.providertype.bndplugin.ProviderTypeScanner
```
To explicitly ignore certain provider types (i.e. don't fail when these are
extended/implemented) one can use the attribute `ignored` with one or multiple
comma-separated fully qualified provider type names. For example
```
--plugin.providertype:org.apache.sling.bnd.providertype.ProviderTypeScanner;ignored=org.apache.jackrabbit.api.security.user.User
+-plugin.providertype:org.apache.sling.providertype.bndplugin.ProviderTypeScanner;ignored=org.apache.jackrabbit.api.security.user.User
```
## Prerequisites
diff --git
a/org.apache.sling.bnd.providertype/src/main/java/org/apache/sling/bnd/providertype/ProviderTypeScanner.java
b/org.apache.sling.bnd.providertype/src/main/java/org/apache/sling/providertype/bndplugin/ProviderTypeScanner.java
similarity index 99%
rename from
org.apache.sling.bnd.providertype/src/main/java/org/apache/sling/bnd/providertype/ProviderTypeScanner.java
rename to
org.apache.sling.bnd.providertype/src/main/java/org/apache/sling/providertype/bndplugin/ProviderTypeScanner.java
index e5aa6f82..a71bbcc2 100644
---
a/org.apache.sling.bnd.providertype/src/main/java/org/apache/sling/bnd/providertype/ProviderTypeScanner.java
+++
b/org.apache.sling.bnd.providertype/src/main/java/org/apache/sling/providertype/bndplugin/ProviderTypeScanner.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.sling.bnd.providertype;
+package org.apache.sling.providertype.bndplugin;
import java.io.InputStream;
import java.util.Arrays;
diff --git
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/BndBuilderExtension.java
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/BndBuilderExtension.java
similarity index 97%
rename from
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/BndBuilderExtension.java
rename to
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/BndBuilderExtension.java
index e21ee713..d14add8c 100644
---
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/BndBuilderExtension.java
+++
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/BndBuilderExtension.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.sling.bnd.providertype;
+package org.apache.sling.providertype.bndplugin;
import java.io.File;
import java.io.IOException;
diff --git
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/ProviderTypeScannerTest.java
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/ProviderTypeScannerTest.java
similarity index 90%
rename from
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/ProviderTypeScannerTest.java
rename to
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/ProviderTypeScannerTest.java
index 6694e2cc..bf26f0fa 100644
---
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/ProviderTypeScannerTest.java
+++
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/ProviderTypeScannerTest.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.sling.bnd.providertype;
+package org.apache.sling.providertype.bndplugin;
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertTrue;
@@ -44,8 +44,8 @@ class ProviderTypeScannerTest {
builder.setClasspath(new File[] { new File("src/test/resources") });
try (Jar jar = builder.build()) {
List<String> expectedErrors = Arrays.asList(
- "Type \"org.apache.sling.bnd.providertype.TypeAImpl\"
implements provider type \"org.apache.sling.bnd.providertype.TypeA\". This is
not allowed!",
- "Type \"org.apache.sling.bnd.providertype.TypeBExtension\"
extends provider type \"org.apache.sling.bnd.providertype.TypeB\". This is not
allowed!");
+ "Type
\"org.apache.sling.providertype.bndplugin.TypeAImpl\" implements provider type
\"org.apache.sling.providertype.bndplugin.TypeA\". This is not allowed!",
+ "Type
\"org.apache.sling.providertype.bndplugin.TypeBExtension\" extends provider
type \"org.apache.sling.providertype.bndplugin.TypeB\". This is not allowed!");
assertEquals(expectedErrors, builder.getErrors());
if (!builder.getWarnings().isEmpty()) {
fail(String.join("\n", builder.getWarnings()));
diff --git
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeA.java
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeA.java
similarity index 94%
rename from
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeA.java
rename to
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeA.java
index 84c0e806..521d1dba 100644
---
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeA.java
+++
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeA.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.sling.bnd.providertype;
+package org.apache.sling.providertype.bndplugin;
public interface TypeA {
diff --git
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeAImpl.java
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeAImpl.java
similarity index 94%
rename from
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeAImpl.java
rename to
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeAImpl.java
index afcc422a..2061e7af 100644
---
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeAImpl.java
+++
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeAImpl.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.sling.bnd.providertype;
+package org.apache.sling.providertype.bndplugin;
public class TypeAImpl implements TypeA {
diff --git
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeB.java
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeB.java
similarity index 94%
rename from
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeB.java
rename to
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeB.java
index 013c3235..141fb5a2 100644
---
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeB.java
+++
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeB.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.sling.bnd.providertype;
+package org.apache.sling.providertype.bndplugin;
public class TypeB {
diff --git
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeBExtension.java
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeBExtension.java
similarity index 94%
rename from
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeBExtension.java
rename to
org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeBExtension.java
index 5b81b6f6..c227cc29 100644
---
a/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/bnd/providertype/TypeBExtension.java
+++
b/org.apache.sling.bnd.providertype/src/test/java/org/apache/sling/providertype/bndplugin/TypeBExtension.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.sling.bnd.providertype;
+package org.apache.sling.providertype.bndplugin;
public class TypeBExtension extends TypeB {
diff --git
a/org.apache.sling.bnd.providertype/src/test/resources/META-INF/api-info.json
b/org.apache.sling.bnd.providertype/src/test/resources/META-INF/api-info.json
index c5687c2d..ce4dcf73 100644
---
a/org.apache.sling.bnd.providertype/src/test/resources/META-INF/api-info.json
+++
b/org.apache.sling.bnd.providertype/src/test/resources/META-INF/api-info.json
@@ -1,3 +1,3 @@
{
-
"providerTypes":["org.apache.sling.bnd.providertype.TypeA","org.apache.sling.bnd.providertype.TypeB"]
+
"providerTypes":["org.apache.sling.providertype.bndplugin.TypeA","org.apache.sling.providertype.bndplugin.TypeB"]
}
\ No newline at end of file