From c5cfa073a04903fcfbe18865b19a3a61f11028bd Mon Sep 17 00:00:00 2001 From: Tatu Saloranta Date: Sun, 31 Jul 2022 18:28:13 -0700 Subject: [PATCH] Add minimal OSGi metadata as per #768 --- pom.xml | 14 +++++++++++++- .../com/fasterxml/jackson/core/JsonFactory.java | 3 +++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 5f35c5aa1d..86cb3c45db 100644 --- a/pom.xml +++ b/pom.xml @@ -38,7 +38,6 @@ still use Moditect to get JDK9+ module info support; need newer bundle plugin as well (can just defaults from `jackson-parent`) --> - com.fasterxml.jackson.core;version=${project.version}, com.fasterxml.jackson.core.*;version=${project.version} @@ -46,6 +45,9 @@ com.fasterxml.jackson.core.*;version=${project.version} com/fasterxml/jackson/core/json ${project.groupId}.json + + + 6.3.1 + + biz.aQute.bnd + biz.aQute.bnd.annotation + ${version.bnd.annotation} + true + provided + + + org.junit.vintage junit-vintage-engine diff --git a/src/main/java/com/fasterxml/jackson/core/JsonFactory.java b/src/main/java/com/fasterxml/jackson/core/JsonFactory.java index 9b9a968308..b7e50c03a4 100644 --- a/src/main/java/com/fasterxml/jackson/core/JsonFactory.java +++ b/src/main/java/com/fasterxml/jackson/core/JsonFactory.java @@ -8,6 +8,8 @@ import java.lang.ref.SoftReference; import java.net.URL; +import aQute.bnd.annotation.spi.ServiceProvider; + import com.fasterxml.jackson.core.format.InputAccessor; import com.fasterxml.jackson.core.format.MatchStrength; import com.fasterxml.jackson.core.io.*; @@ -42,6 +44,7 @@ * @author Tatu Saloranta */ @SuppressWarnings("resource") +@ServiceProvider(JsonFactory.class) // will be `TokenStreamFactory` in 3.x public class JsonFactory extends TokenStreamFactory implements Versioned,