Skip to content

Commit 7c231e7

Browse files
authored
Merge pull request #1755 from brendandburns/sundr
Refactor how we generate fluent builders
2 parents 9328361 + 1b2c024 commit 7c231e7

File tree

1,926 files changed

+265221
-19
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,926 files changed

+265221
-19
lines changed

extended/pom.xml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,11 @@
2929
<artifactId>client-java</artifactId>
3030
<version>${project.version}</version>
3131
</dependency>
32-
32+
<dependency>
33+
<groupId>io.kubernetes</groupId>
34+
<artifactId>client-java-api-fluent</artifactId>
35+
<version>${project.version}</version>
36+
</dependency>
3337
<dependency>
3438
<groupId>org.apache.commons</groupId>
3539
<artifactId>commons-lang3</artifactId>

fluent-gen/generate.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/bash
2+
3+
# TODO: Incorporate this into the pom.xml
4+
5+
rm -r ../fluent/src/main/java/io
6+
mvn compile
7+
mv target/generated-sources/annotations/io ../fluent/src/main/java/io

fluent-gen/pom.xml

Lines changed: 208 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,208 @@
1+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
2+
<modelVersion>4.0.0</modelVersion>
3+
<groupId>io.kubernetes</groupId>
4+
<artifactId>client-java-api-fluent-gen</artifactId>
5+
<packaging>bundle</packaging>
6+
<name>client-java-api</name>
7+
<url>https://github.com/kubernetes-client/java</url>
8+
<description>Swagger Java</description>
9+
<prerequisites>
10+
<maven>2.2.0</maven>
11+
</prerequisites>
12+
13+
<parent>
14+
<groupId>io.kubernetes</groupId>
15+
<artifactId>client-java-parent</artifactId>
16+
<version>12.0.1-SNAPSHOT</version>
17+
<relativePath>../pom.xml</relativePath>
18+
</parent>
19+
20+
<build>
21+
<plugins>
22+
<plugin>
23+
<groupId>org.apache.felix</groupId>
24+
<artifactId>maven-bundle-plugin</artifactId>
25+
<extensions>true</extensions>
26+
</plugin>
27+
<plugin>
28+
<groupId>org.apache.maven.plugins</groupId>
29+
<artifactId>maven-surefire-plugin</artifactId>
30+
<configuration>
31+
<systemProperties>
32+
<property>
33+
<name>loggerPath</name>
34+
<value>conf/log4j.properties</value>
35+
</property>
36+
</systemProperties>
37+
<argLine>-Xms512m -Xmx1500m</argLine>
38+
<parallel>methods</parallel>
39+
<useUnlimitedThreads>true</useUnlimitedThreads>
40+
<forkCount>1</forkCount>
41+
<reuseForks>false</reuseForks>
42+
</configuration>
43+
</plugin>
44+
<plugin>
45+
<artifactId>maven-dependency-plugin</artifactId>
46+
<executions>
47+
<execution>
48+
<phase>package</phase>
49+
<goals>
50+
<goal>copy-dependencies</goal>
51+
</goals>
52+
<configuration>
53+
<outputDirectory>${project.build.directory}/lib</outputDirectory>
54+
</configuration>
55+
</execution>
56+
</executions>
57+
</plugin>
58+
59+
<!-- attach test jar -->
60+
<plugin>
61+
<groupId>org.apache.maven.plugins</groupId>
62+
<artifactId>maven-jar-plugin</artifactId>
63+
<executions>
64+
<execution>
65+
<goals>
66+
<goal>test-jar</goal>
67+
</goals>
68+
</execution>
69+
</executions>
70+
<configuration>
71+
</configuration>
72+
</plugin>
73+
74+
<plugin>
75+
<groupId>org.codehaus.mojo</groupId>
76+
<artifactId>build-helper-maven-plugin</artifactId>
77+
<executions>
78+
<execution>
79+
<id>add_sources</id>
80+
<phase>generate-sources</phase>
81+
<goals>
82+
<goal>add-source</goal>
83+
</goals>
84+
<configuration>
85+
<sources>
86+
<source>src/main/java</source>
87+
</sources>
88+
</configuration>
89+
</execution>
90+
<execution>
91+
<id>add_test_sources</id>
92+
<phase>generate-test-sources</phase>
93+
<goals>
94+
<goal>add-test-source</goal>
95+
</goals>
96+
<configuration>
97+
<sources>
98+
<source>src/test/java</source>
99+
</sources>
100+
</configuration>
101+
</execution>
102+
</executions>
103+
</plugin>
104+
<plugin>
105+
<groupId>org.apache.maven.plugins</groupId>
106+
<artifactId>maven-javadoc-plugin</artifactId>
107+
<executions>
108+
<execution>
109+
<id>attach-javadocs</id>
110+
<goals>
111+
<goal>jar</goal>
112+
</goals>
113+
</execution>
114+
</executions>
115+
<configuration>
116+
<tags>
117+
<tag>
118+
<name>http.response.details</name>
119+
<placement>a</placement>
120+
<head>Http Response Details:</head>
121+
</tag>
122+
</tags>
123+
</configuration>
124+
</plugin>
125+
<plugin>
126+
<groupId>org.apache.maven.plugins</groupId>
127+
<artifactId>maven-source-plugin</artifactId>
128+
<executions>
129+
<execution>
130+
<id>attach-sources</id>
131+
<goals>
132+
<goal>jar-no-fork</goal>
133+
</goals>
134+
</execution>
135+
</executions>
136+
</plugin>
137+
</plugins>
138+
</build>
139+
140+
<dependencies>
141+
<dependency>
142+
<groupId>io.sundr</groupId>
143+
<artifactId>builder-annotations</artifactId>
144+
<version>${sundrio.version}</version>
145+
<scope>compile</scope>
146+
<exclusions>
147+
<exclusion>
148+
<artifactId>tools</artifactId>
149+
<groupId>com.sun</groupId>
150+
</exclusion>
151+
</exclusions>
152+
</dependency>
153+
<dependency>
154+
<groupId>javax.annotation</groupId>
155+
<artifactId>javax.annotation-api</artifactId>
156+
</dependency>
157+
<dependency>
158+
<groupId>io.swagger</groupId>
159+
<artifactId>swagger-annotations</artifactId>
160+
</dependency>
161+
<dependency>
162+
<groupId>com.squareup.okhttp3</groupId>
163+
<artifactId>okhttp</artifactId>
164+
</dependency>
165+
<dependency>
166+
<groupId>com.squareup.okhttp3</groupId>
167+
<artifactId>logging-interceptor</artifactId>
168+
</dependency>
169+
<dependency>
170+
<groupId>com.google.code.gson</groupId>
171+
<artifactId>gson</artifactId>
172+
</dependency>
173+
<dependency>
174+
<groupId>io.gsonfire</groupId>
175+
<artifactId>gson-fire</artifactId>
176+
</dependency>
177+
<dependency>
178+
<groupId>org.apache.commons</groupId>
179+
<artifactId>commons-lang3</artifactId>
180+
</dependency>
181+
<dependency>
182+
<groupId>com.google.code.findbugs</groupId>
183+
<artifactId>jsr305</artifactId>
184+
</dependency>
185+
<dependency>
186+
<groupId>io.kubernetes</groupId>
187+
<artifactId>client-java-api</artifactId>
188+
<version>${project.version}</version>
189+
</dependency>
190+
191+
<!-- test dependencies -->
192+
<dependency>
193+
<groupId>org.hamcrest</groupId>
194+
<artifactId>hamcrest-junit</artifactId>
195+
<scope>test</scope>
196+
</dependency>
197+
<dependency>
198+
<groupId>ch.qos.logback</groupId>
199+
<artifactId>logback-classic</artifactId>
200+
<scope>test</scope>
201+
</dependency>
202+
<dependency>
203+
<groupId>junit</groupId>
204+
<artifactId>junit</artifactId>
205+
<scope>test</scope>
206+
</dependency>
207+
</dependencies>
208+
</project>

fluent/pom.xml

Lines changed: 122 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,122 @@
1+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
2+
<modelVersion>4.0.0</modelVersion>
3+
<groupId>io.kubernetes</groupId>
4+
<artifactId>client-java-api-fluent</artifactId>
5+
<packaging>bundle</packaging>
6+
<name>client-java</name>
7+
<url>https://github.com/kubernetes-client/java</url>
8+
<parent>
9+
<groupId>io.kubernetes</groupId>
10+
<artifactId>client-java-parent</artifactId>
11+
<version>12.0.1-SNAPSHOT</version>
12+
<relativePath>../pom.xml</relativePath>
13+
</parent>
14+
<dependencies>
15+
<dependency>
16+
<groupId>io.kubernetes</groupId>
17+
<artifactId>client-java-api</artifactId>
18+
<version>${project.version}</version>
19+
</dependency>
20+
<!-- test dependencies -->
21+
<dependency>
22+
<groupId>junit</groupId>
23+
<artifactId>junit</artifactId>
24+
<scope>test</scope>
25+
</dependency>
26+
<dependency>
27+
<groupId>org.mockito</groupId>
28+
<artifactId>mockito-core</artifactId>
29+
<scope>test</scope>
30+
</dependency>
31+
</dependencies>
32+
<build>
33+
<plugins>
34+
<plugin>
35+
<groupId>org.jacoco</groupId>
36+
<artifactId>jacoco-maven-plugin</artifactId>
37+
<version>0.8.7</version>
38+
<executions>
39+
<execution>
40+
<id>jacoco-initialize</id>
41+
<goals>
42+
<goal>prepare-agent</goal>
43+
</goals>
44+
</execution>
45+
<execution>
46+
<id>jacoco-report</id>
47+
<phase>test</phase>
48+
<goals>
49+
<goal>report</goal>
50+
</goals>
51+
</execution>
52+
</executions>
53+
</plugin>
54+
<plugin>
55+
<groupId>org.apache.felix</groupId>
56+
<artifactId>maven-bundle-plugin</artifactId>
57+
<extensions>true</extensions>
58+
</plugin>
59+
<plugin>
60+
<groupId>org.apache.maven.plugins</groupId>
61+
<artifactId>maven-compiler-plugin</artifactId>
62+
<configuration>
63+
<source>8</source>
64+
<target>8</target>
65+
</configuration>
66+
</plugin>
67+
<plugin>
68+
<groupId>com.diffplug.spotless</groupId>
69+
<artifactId>spotless-maven-plugin</artifactId>
70+
<configuration>
71+
<skip>true</skip>
72+
</configuration>
73+
</plugin>
74+
</plugins>
75+
</build>
76+
<profiles>
77+
<profile>
78+
<id>surefire-newerJava</id>
79+
<activation>
80+
<jdk>(1.8,)</jdk>
81+
</activation>
82+
<build>
83+
<plugins>
84+
<plugin>
85+
<groupId>org.apache.maven.plugins</groupId>
86+
<artifactId>maven-surefire-plugin</artifactId>
87+
<configuration>
88+
<argLine>@{argLine} -Xms512m -Xmx1500m --illegal-access=warn</argLine>
89+
<parallel>methods</parallel>
90+
<perCoreThreadCount>false</perCoreThreadCount>
91+
<threadCount>1</threadCount>
92+
<forkCount>1</forkCount>
93+
<reuseForks>false</reuseForks>
94+
</configuration>
95+
</plugin>
96+
</plugins>
97+
</build>
98+
</profile>
99+
<profile>
100+
<id>surefire-java8</id>
101+
<activation>
102+
<jdk>1.8</jdk>
103+
</activation>
104+
<build>
105+
<plugins>
106+
<plugin>
107+
<groupId>org.apache.maven.plugins</groupId>
108+
<artifactId>maven-surefire-plugin</artifactId>
109+
<configuration>
110+
<argLine>@{argLine} -Xms512m -Xmx1500m</argLine>
111+
<parallel>methods</parallel>
112+
<perCoreThreadCount>false</perCoreThreadCount>
113+
<threadCount>1</threadCount>
114+
<forkCount>1</forkCount>
115+
<reuseForks>false</reuseForks>
116+
</configuration>
117+
</plugin>
118+
</plugins>
119+
</build>
120+
</profile>
121+
</profiles>
122+
</project>

0 commit comments

Comments
 (0)