Skip to content

Commit

Permalink
build analytics improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
brunobat committed Jun 20, 2023
1 parent df7445d commit add925e
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@ public class BuildAnalyticsConfig {
* The Timeout to send the build time analytics to segment.
*/
@ConfigItem(defaultValue = "3000")
public Optional<Integer> timeout;
public Integer timeout;
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@

/**
* Prompt implementation.
*
* @author <a href="http://escoffier.me">Clement Escoffier</a>
*/
public class Prompter {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
package io.quarkus.gradle.tasks;

import static io.quarkus.analytics.dto.segment.ContextBuilder.CommonSystemProperties.GRADLE_VERSION;
import static io.quarkus.analytics.dto.segment.TrackEventType.*;
import static java.util.Collections.*;
import static io.quarkus.analytics.dto.segment.TrackEventType.DEV_MODE;

import java.io.BufferedWriter;
import java.io.File;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,35 +100,35 @@ public void execute() {
}

private static class Slf4JMessageWriter implements MessageWriter {
private final Logger LOGGER;
private final Logger logger;

public Slf4JMessageWriter(final Logger logger) {
this.LOGGER = logger;
this.logger = logger;
}

@Override
public void info(String msg) {
this.LOGGER.info(msg);
this.logger.info(msg);
}

@Override
public void error(String msg) {
this.LOGGER.error(msg);
this.logger.error(msg);
}

@Override
public boolean isDebugEnabled() {
return this.LOGGER.isDebugEnabled();
return this.logger.isDebugEnabled();
}

@Override
public void debug(String msg) {
this.LOGGER.debug(msg);
this.logger.debug(msg);
}

@Override
public void warn(String msg) {
this.LOGGER.warn(msg);
this.logger.warn(msg);
}
}
}
2 changes: 1 addition & 1 deletion devtools/maven/src/main/java/io/quarkus/maven/DevMojo.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import static io.quarkus.analytics.dto.segment.TrackEventType.DEV_MODE;
import static io.smallrye.common.expression.Expression.Flag.LENIENT_SYNTAX;
import static io.smallrye.common.expression.Expression.Flag.NO_TRIM;
import static java.util.Collections.*;
import static java.util.Collections.emptyMap;
import static java.util.function.Predicate.not;
import static org.twdata.maven.mojoexecutor.MojoExecutor.artifactId;
import static org.twdata.maven.mojoexecutor.MojoExecutor.configuration;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@

/**
* Prompt implementation.
*
* @author <a href="http://escoffier.me">Clement Escoffier</a>
*/
public class Prompter {

Expand Down
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/build-analytics.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ https://github.com/quarkusio/quarkus/tree/main/docs/src/main/asciidoc
:categories: analytics
:summary: This guide presents what build analytics is and how to configure it.

The Quarkus team has limited knowledge, from Maven download numbers, of the remarkable growth of Quarkus and the number of users reporting issues/concerns. Still, we need more insight into the platforms, operating system, java combinations, and build tools our users employ.
The Quarkus team has limited knowledge, from Maven download numbers, of the remarkable growth of Quarkus and the number of users reporting issues/concerns. Still, we need more insight into the platforms, operating system, Java combinations, and build tools our users employ.
The build analytics tool aims to provide us with this information.

== How it works
Expand All @@ -16,7 +16,7 @@ The build analytics tool aims to provide us with this information.

*All data collected is anonymous*. There is no way to link this data back to an individual or organization. The intent is to learn about general patterns and trends; therefore, only anonymous data is needed.

*Collection is Disabled by default* You will be asked if you want to opt in to data collection the first time you use devMode. The console will wait for a few seconds for your input.
*Collection is disabled by default* You will be asked if you want to opt in to data collection the first time you use dev mode. The console will wait for a few seconds for your input.

== This is the data being collected

Expand All @@ -26,7 +26,7 @@ The build analytics tool aims to provide us with this information.
* Quarkus version
* Java version
* GraalVM version
* Operating system details
* Operating system details: OS name, OS version and architecture
* Build system details, such as Maven, Gradle, and so on.
* If a CI system was detected
* Country and timezone
Expand Down

0 comments on commit add925e

Please sign in to comment.