Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken taglib docs on reports.jenkins.io #3049

Closed
NotMyFault opened this issue Jul 11, 2022 · 29 comments
Closed

Broken taglib docs on reports.jenkins.io #3049

NotMyFault opened this issue Jul 11, 2022 · 29 comments

Comments

@NotMyFault
Copy link
Member

Service(s)

Other

Summary

The taglib docs for core appear to be broken.
Normally, you can view the docs of core's Jelly tag library here, but the page is empty and has a broken image:
Screenshot 2022-07-12 at 00 53 28
The job building the tag lib library for core finishes successful though https://ci.jenkins.io/job/Infra/job/core-taglibs-report-generator/job/master/

Reproduction steps

No response

@NotMyFault NotMyFault added the triage Incoming issues that need review label Jul 11, 2022
@MarkEWaite MarkEWaite changed the title Broken taglib docs Broken taglib docs on reports.jenkins.io Jul 12, 2022
@dduportal
Copy link
Contributor

As discussed during the last infra-team meeting (2022-07-12) we are assigning this issue to @MarkEWaite to let him lead.

The infra team is not able to diagnose and solve this issue as we have no idea how is the javadoc process working.

What the infra-team knows (and can share):

=> I assume that the issue should be reproduced with the repository itself? I guess it might be a JDK8/11 related thing?

@NotMyFault
Copy link
Member Author

Idk too much about taglib docs either, but if the job on ci.j doesn't publish anything and the actual work happens on trusted.ci, we could disable or remove the public job.

@dduportal
Copy link
Contributor

Idk too much about taglib docs either, but if the job on ci.j doesn't publish anything and the actual work happens on trusted.ci, we could disable or remove the public job.

The public job allows any contributor who want to try anything to be able to get a feedback: that is why we keep components like this one with a splitted pipeline CI (ci.jenkins.io)/CD (trusted.ci.jenkins.io).

@NotMyFault
Copy link
Member Author

NotMyFault commented Jul 16, 2022

As of build 273 of the core-taglibs-report-generator, the following error appears in the log:

00:49:19  [INFO] Skipped "About" report (maven-project-info-reports-plugin:3.2.2:index), file "index.html" already exists.
00:49:19  [INFO] Rendering 1 Doxia document: 1 markdown
00:49:19  [INFO] Generating "Jelly taglib reference" report --- maven-stapler-plugin:1.17:jelly-taglibdoc
00:49:19  [WARNING] An issue has occurred with maven-stapler-plugin:1.17:jelly-taglibdoc report, skipping LinkageError org.kohsuke.stapler.TaglibDocMojo.generate(Lorg/apache/maven/doxia/sink/Sink;Ljava/util/Locale;)V, please report an issue to Maven dev team.
00:49:19  java.lang.AbstractMethodError: org.kohsuke.stapler.TaglibDocMojo.generate(Lorg/apache/maven/doxia/sink/Sink;Ljava/util/Locale;)V
00:49:19      at org.apache.maven.plugins.site.render.ReportDocumentRenderer.renderDocument (ReportDocumentRenderer.java:235)
00:49:19      at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.render (DefaultSiteRenderer.java:348)
00:49:19      at org.apache.maven.plugins.site.render.SiteMojo.renderLocale (SiteMojo.java:194)
00:49:19      at org.apache.maven.plugins.site.render.SiteMojo.execute (SiteMojo.java:143)
00:49:19      at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
00:49:19      at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:370)
00:49:19      at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
00:49:19      at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
00:49:19      at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
00:49:19      at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
00:49:19      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
00:49:19      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
00:49:19      at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
00:49:19      at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
00:49:19      at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:294)
00:49:19      at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
00:49:19      at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
00:49:19      at org.apache.maven.cli.MavenCli.execute (MavenCli.java:960)
00:49:19      at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:293)
00:49:19      at org.apache.maven.cli.MavenCli.main (MavenCli.java:196)
00:49:19      at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
00:49:19      at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
00:49:19      at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
00:49:19      at java.lang.reflect.Method.invoke (Method.java:498)
00:49:19      at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
00:49:19      at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
00:49:19      at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
00:49:19      at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)

273 is the first build building 2.346, 272 has no error and built 2.332 fine.

I assume something changed (possibly code and infra wise) between these two LTS releases?

@daniel-beck
Copy link

daniel-beck commented Jul 28, 2022

I would check for updates of maven-site-plugin or related plugins, that broke site generation before.

@NotMyFault
Copy link
Member Author

That was already broken before my change, looks like something broke when we required Java 11.
Using the last release before restored it locally for me afaik.

@michael-o
Copy link

Can someone try apache/maven-reporting-api#13? It should restore binary compat for the 3.x line, but beware it will NOT work with the next major version of MSITE.

@basil
Copy link
Collaborator

basil commented Jul 29, 2022

Thank you for the quick response @michael-o. I tested your PR and verified that my issue is resolved.

I reproduced the problem by building maven-reporting-api at commit e21ec0e (3.1.1-SNAPSHOT), building maven-site-plugin at commit 039b29b9 (3.12.1-SNAPSHOT) with the preceding snapshot of maven-reporting-api, building the Jenkins parent POM with the preceding snapshot of maven-site-plugin, and building Jenkins core with the preceding snapshot of the Jenkins parent POM. Running mvn --show-version --batch-mode -DgenerateProjectInfo=false -DgenerateSitemap=false -e clean site:site in Jenkins core gave me the following error:

[INFO] Generating "Jelly taglib reference" report --- maven-stapler-plugin:1.17:jelly-taglibdoc
[WARNING] An issue has occurred with maven-stapler-plugin:1.17:jelly-taglibdoc report, skipping LinkageError Receiver class org.kohsuke.stapler.TaglibDocMojo does not define or inherit an implementation of the resolved method 'abstract void generate(org.apache.maven.doxia.sink.Sink, java.util.Locale)' of interface org.apache.maven.reporting.MavenReport., please report an issue to Maven dev team.
java.lang.AbstractMethodError: Receiver class org.kohsuke.stapler.TaglibDocMojo does not define or inherit an implementation of the resolved method 'abstract void generate(org.apache.maven.doxia.sink.Sink, java.util.Locale)' of interface org.apache.maven.reporting.MavenReport.
    at org.apache.maven.plugins.site.render.ReportDocumentRenderer.renderDocument (ReportDocumentRenderer.java:235)
    at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.render (DefaultSiteRenderer.java:348)
    at org.apache.maven.plugins.site.render.SiteMojo.renderLocale (SiteMojo.java:194)
    at org.apache.maven.plugins.site.render.SiteMojo.execute (SiteMojo.java:143)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:370)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:294)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
    at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
    at org.apache.maven.cli.MavenCli.execute (MavenCli.java:960)
    at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:293)
    at org.apache.maven.cli.MavenCli.main (MavenCli.java:196)
    at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
    at jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
    at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke (Method.java:566)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
[INFO] Generating "CI Management" report        --- maven-project-info-reports-plugin:3.4.0:ci-management

Next, I rebuilt maven-reporting-api with the changes from your PR. The Jenkins core build now passes:

[INFO] Generating "Jelly taglib reference" report --- maven-stapler-plugin:1.17:jelly-taglibdoc
[INFO] Processing /home/basil/src/jenkinsci/jenkins/core/src/main/resources/lib/form
[INFO] Processing /home/basil/src/jenkinsci/jenkins/core/src/main/resources/lib/test
[INFO] Processing /home/basil/src/jenkinsci/jenkins/core/src/main/resources/lib/layout
[INFO] Processing /home/basil/src/jenkinsci/jenkins/core/src/main/resources/lib/hudson
[INFO] Processing /home/basil/src/jenkinsci/jenkins/core/src/main/resources/lib/hudson/project
[INFO] Processing /home/basil/src/jenkinsci/jenkins/core/src/main/resources/lib/hudson/newFromList
[info] Generating XML Schema
[INFO] Generating "CI Management" report        --- maven-project-info-reports-plugin:3.4.0:ci-management

@basil
Copy link
Collaborator

basil commented Jul 29, 2022

It should restore binary compat for the 3.x line

The hotfix is appreciated, as that will restore the web page for Jenkins users immediately.

beware it will NOT work with the next major version of MSITE.

Thank you for the warning. I have started the following thread to track updating these Maven plugins for compatibility with future releases (CC @kohsuke):

https://groups.google.com/g/jenkinsci-dev/c/cQSf2qP7jbc/m/VJHxxgJ8AQAJ

@basil
Copy link
Collaborator

basil commented Jul 29, 2022

looks like something broke when we required Java 11.

I do not see how it could.

@michael-o
Copy link

@michael-o
Copy link

FYI: https://lists.apache.org/thread/q9f9dkjpjov0t0bmlcb1skj4wq9myht4

VOTE complete. Release done. MSITE is onging. Will likely land on Wednesday on Central, then you just need to update it and done.

@michael-o
Copy link

Maven Site Plugin 3.12.1 is now on Maven Central. Enjoy your old reporting plugins as long as you can!

@MarkEWaite MarkEWaite removed their assignment Aug 4, 2022
@basil
Copy link
Collaborator

basil commented Aug 4, 2022

Core has been upgraded to the new release of Maven Site plugin and I confirmed that things are working again now in a manual build. That gets us back to a working state in the short term.

Let's keep this ticket open to track the long-term fix: releasing new versions of Maven Jellydoc Plugin and Maven Stapler Plugin that are compatible with Maven 4. I started the upgrade of the latter in jenkinsci/stapler-maven-plugin#13, but getting that to compile depends on the former, which is blocked on transferring the code from Kohsuke's GitHub organization to ours. I have pinged Kohsuke last week and I sent another ping today.

@michael-o
Copy link

@basil Please note that this is not Maven 4 related. This is a 10-year old technical debt we need to clean up. This will happen without Maven 4 and runs w/o issues on older versions as well.

@basil
Copy link
Collaborator

basil commented Aug 5, 2022

My point is that we need to migrate up the consumers in the long term because you said that Maven will eventually stop supporting the deprecated API they are currently using. I thought you said the API would be removed in Maven 4 but the point is that it will be removed eventually.

@michael-o
Copy link

My point is that we need to migrate up the consumers in the long term because you said that Maven will eventually stop supporting the deprecated API they are currently using. I thought you said the API would be removed in Maven 4 but the point is that it will be removed eventually.

No, you interpretation is wrong. This isn't a Maven Core issue, Maven Core does not care about this. It is solely the entire Maven Reporting stack which is used by reporting plugins and Maven Site Plugin. The actual Maven version does not matter. Maven Site Plugin 4 GA will depend on new major versions of Doxia and Reporting components, baseline will still be Maven 3.2.5. Everything deprecated in that trail will be relentlessly removed.

The simple test recommendation: If your reporting plugin has deps which start with maven-reporing- or doxia-, create a branch, upgrade them, run your ITs with Maven Site Plugin 4.0.0-Mx and see what fail. Also save the IT output in target/site and diff them. Some are expected, some are not. If you questions, join ASF slack, channel #maven, I'd be happy to help the Jenkins community.

@basil
Copy link
Collaborator

basil commented Aug 5, 2022

I don't think my interpretation is wrong. When I wrote "Maven will eventually stop supporting the deprecated API" I meant the Maven project, not Maven core. So it sounds like Maven Site Plugin 4 is the version that will finally drop support for these APIs. So we will just not upgrade to Maven Site Plugin 4 until we have time to fix up the consumers.

@michael-o
Copy link

I don't think my interpretation is wrong. When I wrote "Maven will eventually stop supporting the deprecated API" I meant the Maven project, not Maven core. So it sounds like Maven Site Plugin 4 is the version that will finally drop support for these APIs. So we will just not upgrade to Maven Site Plugin 4 until we have time to fix up the consumers.

That one is correct.

@basil
Copy link
Collaborator

basil commented Aug 5, 2022

Oh good.

@michael-o
Copy link

Import note: Given that I am basically the only one working on this and @hboutemy is doing the reviews and I have to test all of our report plugins, don't expect a GA version before of end of fall or winter somewhere. So you still have months and months to go.

@michael-o
Copy link

Oh good.

That's imporant because I don't like imprecision and misunderstandings from my statements.

@basil
Copy link
Collaborator

basil commented Aug 5, 2022

Me neither Michael, thank you for clarifying the version where this will be no longer supported, as this gives consumers time to adapt.

@michael-o
Copy link

Me neither Michael, thank you for clarifying the version where this will be no longer supported, as this gives consumers time to adapt.

Sure thing. When 80% of the Reporting changes are done I will write a lengthy changelog for everyone to be prepared for the change. From a user PoV is it merely an upgrade, for devs a bit more.

@basil
Copy link
Collaborator

basil commented Aug 5, 2022

Having implemented similar migrations in the Jenkins project and beyond, I wish you the best of luck!

@basil
Copy link
Collaborator

basil commented Sep 7, 2022

With the merge of jenkins-infra/core-taglibs-report-generator#16 https://ci.jenkins.io/job/Infra/job/core-taglibs-report-generator/job/master/ is finally passing against LTS again. Can someone please kick off the corresponding job on trusted.ci.jenkins.io to publish to https://reports.jenkins.io/core-taglib/ - I would do so myself but I lack the permissions.

@MarkEWaite
Copy link

I think that I've correctly run the job on trusted.ci.jenkins.io and the https://reports.jenkins.io/core-taglib/jelly-taglib-ref.html page reports that is is run for 2.361.1. I see a broken image on the page at the top but other content seemed reasonable

@basil
Copy link
Collaborator

basil commented Sep 7, 2022

With end-to-end testing complete and the refreshing of Maven Stapler Plugin and Maven Jellydoc Plugin, I think this ticket can now be closed. While using a non-deprecated Sink class remains as an action item, that does not seem possible with current stable Maven APIs. In any case, I think that work is better tracked in jenkinsci/jellydoc-maven-plugin#7.

@basil basil closed this as completed Sep 7, 2022
@dduportal dduportal removed the triage Incoming issues that need review label Aug 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants