Skip to content

Commit 1c1f510

Browse files
steinarbSteinar Bang
authored and
Steinar Bang
committed
Use karaf-maven-plugin 4.2.6 to create apache karaf features for the modules in jackson-modules-base (FasterXML#86)
Dependencies that are provided at runtime by karaf features have their scope changed to provided, and dependencies to their feature repositories are added.
1 parent c960c54 commit 1c1f510

File tree

10 files changed

+108
-0
lines changed

10 files changed

+108
-0
lines changed

afterburner/pom.xml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,12 @@ field access and method calls
4242
<dependency>
4343
<groupId>com.fasterxml.jackson.core</groupId>
4444
<artifactId>jackson-core</artifactId>
45+
<scope>provided</scope>
4546
</dependency>
4647
<dependency>
4748
<groupId>com.fasterxml.jackson.core</groupId>
4849
<artifactId>jackson-databind</artifactId>
50+
<scope>provided</scope>
4951
</dependency>
5052
<dependency>
5153
<groupId>org.ow2.asm</groupId>
@@ -105,6 +107,10 @@ field access and method calls
105107
<groupId>org.moditect</groupId>
106108
<artifactId>moditect-maven-plugin</artifactId>
107109
</plugin>
110+
<plugin>
111+
<groupId>org.apache.karaf.tooling</groupId>
112+
<artifactId>karaf-maven-plugin</artifactId>
113+
</plugin>
108114
</plugins>
109115

110116
</build>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<features xmlns="http://karaf.apache.org/xmlns/features/v1.6.0" name="${project.artifactId}">
3+
<repository>mvn:com.fasterxml.jackson.core/jackson-databind/${jackson.version.core}/xml/features</repository>
4+
<feature name="${project.artifactId}">
5+
<feature>jackson-databind</feature>
6+
</feature>
7+
</features>

guice/pom.xml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,19 +27,34 @@
2727
<dependency>
2828
<groupId>com.fasterxml.jackson.core</groupId>
2929
<artifactId>jackson-annotations</artifactId>
30+
<scope>provided</scope>
3031
</dependency>
3132
<dependency>
3233
<groupId>com.fasterxml.jackson.core</groupId>
3334
<artifactId>jackson-core</artifactId>
35+
<scope>provided</scope>
3436
</dependency>
3537
<dependency>
3638
<groupId>com.fasterxml.jackson.core</groupId>
3739
<artifactId>jackson-databind</artifactId>
40+
<scope>provided</scope>
3841
</dependency>
3942
<dependency>
4043
<groupId>com.google.inject</groupId>
4144
<artifactId>guice</artifactId>
4245
<version>${version.guice}</version>
46+
<exclusions>
47+
<exclusion>
48+
<groupId>javax.inject</groupId>
49+
<artifactId>javax.inject</artifactId>
50+
</exclusion>
51+
</exclusions>
52+
</dependency>
53+
<dependency>
54+
<groupId>javax.inject</groupId>
55+
<artifactId>javax.inject</artifactId>
56+
<version>1</version>
57+
<scope>provided</scope>
4358
</dependency>
4459
</dependencies>
4560

@@ -56,6 +71,13 @@
5671
<groupId>org.moditect</groupId>
5772
<artifactId>moditect-maven-plugin</artifactId>
5873
</plugin>
74+
<plugin>
75+
<groupId>org.apache.karaf.tooling</groupId>
76+
<artifactId>karaf-maven-plugin</artifactId>
77+
<configuration>
78+
<includeTransitiveDependency>true</includeTransitiveDependency>
79+
</configuration>
80+
</plugin>
5981
</plugins>
6082
</build>
6183

guice/src/main/feature/feature.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<features xmlns="http://karaf.apache.org/xmlns/features/v1.6.0" name="jackson-module-paranamer">
3+
<repository>mvn:com.fasterxml.jackson.core/jackson-databind/${jackson.version.core}/xml/features</repository>
4+
<feature name="${project.artifactId}">
5+
<feature>jackson-databind</feature>
6+
<feature>transaction-api</feature>
7+
</feature>
8+
</features>

jaxb/pom.xml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,24 @@ data-binding.
3131
<dependency>
3232
<groupId>com.fasterxml.jackson.core</groupId>
3333
<artifactId>jackson-annotations</artifactId>
34+
<scope>provided</scope>
3435
</dependency>
3536
<dependency>
3637
<groupId>com.fasterxml.jackson.core</groupId>
3738
<artifactId>jackson-core</artifactId>
39+
<scope>provided</scope>
3840
</dependency>
3941
<dependency>
4042
<groupId>com.fasterxml.jackson.core</groupId>
4143
<artifactId>jackson-databind</artifactId>
44+
<scope>provided</scope>
45+
</dependency>
46+
<dependency>
47+
<groupId>com.fasterxml.jackson.core</groupId>
48+
<artifactId>jackson-databind</artifactId>
49+
<version>${jackson.version.databind}</version>
50+
<classifier>features</classifier>
51+
<type>xml</type>
4252
</dependency>
4353

4454
<!-- and actual JAXB annotations, types -->
@@ -93,6 +103,10 @@ data-binding.
93103
<groupId>org.moditect</groupId>
94104
<artifactId>moditect-maven-plugin</artifactId>
95105
</plugin>
106+
<plugin>
107+
<groupId>org.apache.karaf.tooling</groupId>
108+
<artifactId>karaf-maven-plugin</artifactId>
109+
</plugin>
96110
</plugins>
97111
</build>
98112
</project>

jaxb/src/main/feature/feature.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<features xmlns="http://karaf.apache.org/xmlns/features/v1.6.0" name="jackson-module-jaxb-annotations">
3+
<feature name="${project.artifactId}">
4+
<bundle start-level="80">mvn:com.sun.activation/jakarta.activation/1.2.1</bundle>
5+
</feature>
6+
</features>
7+

mrbean/pom.xml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,24 @@ ${project.groupId}.mrbean.*;version=${project.version}
3333
<dependency>
3434
<groupId>com.fasterxml.jackson.core</groupId>
3535
<artifactId>jackson-core</artifactId>
36+
<scope>provided</scope>
3637
</dependency>
3738
<dependency>
3839
<groupId>com.fasterxml.jackson.core</groupId>
3940
<artifactId>jackson-databind</artifactId>
41+
<scope>provided</scope>
42+
</dependency>
43+
<dependency>
44+
<groupId>com.fasterxml.jackson.core</groupId>
45+
<artifactId>jackson-databind</artifactId>
46+
<version>${jackson.version.databind}</version>
47+
<classifier>features</classifier>
48+
<type>xml</type>
49+
</dependency>
50+
<dependency>
51+
<groupId>com.fasterxml.jackson.core</groupId>
52+
<artifactId>jackson-annotations</artifactId>
53+
<scope>provided</scope>
4054
</dependency>
4155
<dependency>
4256
<groupId>org.ow2.asm</groupId>
@@ -86,6 +100,10 @@ ${project.groupId}.mrbean.*;version=${project.version}
86100
<groupId>org.moditect</groupId>
87101
<artifactId>moditect-maven-plugin</artifactId>
88102
</plugin>
103+
<plugin>
104+
<groupId>org.apache.karaf.tooling</groupId>
105+
<artifactId>karaf-maven-plugin</artifactId>
106+
</plugin>
89107
</plugins>
90108
</build>
91109
</project>

osgi/pom.xml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,20 @@
2727
<dependency>
2828
<groupId>com.fasterxml.jackson.core</groupId>
2929
<artifactId>jackson-databind</artifactId>
30+
<scope>provided</scope>
31+
</dependency>
32+
<dependency>
33+
<groupId>com.fasterxml.jackson.core</groupId>
34+
<artifactId>jackson-databind</artifactId>
35+
<version>${jackson.version.databind}</version>
36+
<classifier>features</classifier>
37+
<type>xml</type>
3038
</dependency>
3139
<dependency>
3240
<groupId>org.osgi</groupId>
3341
<artifactId>org.osgi.core</artifactId>
3442
<version>${version.osgi.core}</version>
43+
<scope>provided</scope>
3544
</dependency>
3645
<dependency>
3746
<groupId>org.mockito</groupId>
@@ -54,6 +63,10 @@
5463
<groupId>org.moditect</groupId>
5564
<artifactId>moditect-maven-plugin</artifactId>
5665
</plugin>
66+
<plugin>
67+
<groupId>org.apache.karaf.tooling</groupId>
68+
<artifactId>karaf-maven-plugin</artifactId>
69+
</plugin>
5770
</plugins>
5871
</build>
5972

paranamer/pom.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ to introspect names of constructor (and factory method) parameters.
3030
<dependency>
3131
<groupId>com.fasterxml.jackson.core</groupId>
3232
<artifactId>jackson-databind</artifactId>
33+
<scope>provided</scope>
3334
</dependency>
3435

3536
<!-- and paranamer for introspection -->
@@ -110,6 +111,10 @@ to introspect names of constructor (and factory method) parameters.
110111
<groupId>org.moditect</groupId>
111112
<artifactId>moditect-maven-plugin</artifactId>
112113
</plugin>
114+
<plugin>
115+
<groupId>org.apache.karaf.tooling</groupId>
116+
<artifactId>karaf-maven-plugin</artifactId>
117+
</plugin>
113118
</plugins>
114119
</build>
115120

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<features xmlns="http://karaf.apache.org/xmlns/features/v1.6.0" name="jackson-module-paranamer">
3+
<repository>mvn:com.fasterxml.jackson.core/jackson-databind/${jackson.version.core}/xml/features</repository>
4+
<feature name="${project.artifactId}">
5+
<feature>jackson-databind</feature>
6+
<feature>transaction-api</feature>
7+
</feature>
8+
</features>

0 commit comments

Comments
 (0)