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

[JENKINS-73616] Log spam from AnnotationParser#parseClass #409

Merged
merged 1 commit into from
Aug 28, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion src/main/java/winstone/Launcher.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
import java.util.logging.Handler;
import java.util.logging.Level;
import java.util.logging.LogRecord;
import org.eclipse.jetty.ee8.annotations.AnnotationParser;
import org.eclipse.jetty.jmx.MBeanContainer;
import org.eclipse.jetty.server.Connector;
import org.eclipse.jetty.server.LowResourceMonitor;
Expand Down Expand Up @@ -84,7 +85,7 @@ public class Launcher implements Runnable {
* available protocol listeners.
*/
@SuppressFBWarnings(
value = "DP_CREATE_CLASSLOADER_INSIDE_DO_PRIVILEGED",
value = {"DP_CREATE_CLASSLOADER_INSIDE_DO_PRIVILEGED", "LG_LOST_LOGGER_DUE_TO_WEAK_REFERENCE"},
justification = "cf. https://github.com/spotbugs/spotbugs/issues/1515")
public Launcher(Map<String, String> args) throws IOException {
boolean success = false;
Expand Down Expand Up @@ -181,6 +182,10 @@ public Launcher(Map<String, String> args) throws IOException {
server.addBean(mbeanContainer);
}

// JENKINS-73616: Turn down log level of annotation parser
java.util.logging.Logger logger = java.util.logging.Logger.getLogger(AnnotationParser.class.getName());
logger.setLevel(Level.SEVERE);

try {
server.start();
writePortToFileIfNeeded();
Expand Down