Skip to content

Commit 69c1e8d

Browse files
committed
cleanup
1 parent 0bf1c56 commit 69c1e8d

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

instrumentation-docs/src/main/java/io/opentelemetry/instrumentation/docs/DocSynchronization.java

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,18 +42,15 @@ public class DocSynchronization {
4242
private static final List<String> INSTRUMENTATION_EXCLUSIONS =
4343
List.of("resources", "spring-boot-resources");
4444

45-
private final HttpClient client;
46-
47-
public DocSynchronization(HttpClient client) {
48-
this.client = client;
49-
}
45+
private DocSynchronization() {}
5046

5147
/**
5248
* Retrieves contents of the disable page from the main branch of the documentation site.
5349
*
5450
* @return the file content as a string
5551
*/
56-
private String getDocumentationDisableList() throws IOException, InterruptedException {
52+
private static String getDocumentationDisableList(HttpClient client)
53+
throws IOException, InterruptedException {
5754
HttpRequest request =
5855
HttpRequest.newBuilder().uri(URI.create(DOCUMENTATION_DISABLE_LIST)).build();
5956

@@ -168,10 +165,9 @@ public static List<String> parseDocumentationDisabledList(String fileContent) {
168165

169166
public static void main(String[] args) {
170167
HttpClient client = HttpClient.newHttpClient();
171-
DocSynchronization synchronization = new DocSynchronization(client);
172168

173169
try {
174-
String content = synchronization.getDocumentationDisableList();
170+
String content = getDocumentationDisableList(client);
175171
List<String> disabledList = parseDocumentationDisabledList(content);
176172

177173
String instrumentationListContent = Objects.requireNonNull(getInstrumentationList());

0 commit comments

Comments
 (0)