spring-cloud-build icon indicating copy to clipboard operation
spring-cloud-build copied to clipboard

Add automation for projects to create javadoc links

Open dsyer opened this issue 9 years ago • 1 comments

This nice little service http://javadoc.io/ could be used to render our javadocs, but there are multiple jars per project. So there are 2 choices:

  1. Make a new page in each project's documentation that lists links to all javadocs, one per jar
  2. Publish an aggregate jar and make it appear in http://javadoc.io/. For that to work we'd have to know a little bit about the internals of the service (does it support this kind of aggregation?).

Option 1 is easier for us, but option 2 is more convenient for users.

dsyer avatar Oct 24 '16 11:10 dsyer

I think a variant of option 2 will work (cf http://javadoc.io/doc/org.springframework.cloud/spring-cloud-commons-parent/1.1.4.RELEASE). The parent project can aggregate javadocs and publish them as a single jar. The only tricky thing is then knowing the name of the parent project, but users will never need to care, if they just follow links from the home page. Here's what I used to create the spring-cloud-commons-parent docs:

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <executions>
                    <execution>
                        <id>aggregate</id>
                        <goals>
                            <goal>aggregate-jar</goal>
                        </goals>
                        <phase>package</phase>
                        <inherited>false</inherited>
                        <configuration>
                            <aggregate>true</aggregate>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

dsyer avatar Oct 24 '16 15:10 dsyer