@@ -121,7 +121,8 @@ private static List<Artifact> convertToArtifacts(Map<?, ?> map) {
121121 HttpResponse <String > response = client .send (request , HttpResponse .BodyHandlers .ofString ());
122122 if (response .statusCode () != 200 ) {
123123 logger .log (
124- Level .SEVERE , "Unexpected response code: " + response .statusCode () + ": " + response .body ());
124+ Level .SEVERE ,
125+ "Unexpected response code: " + response .statusCode () + ": " + response .body ());
125126 throw new IOException ("Unable to pull Maven central artifacts list" );
126127 }
127128 return objectMapper .readValue (response .body (), Map .class );
@@ -132,14 +133,14 @@ static List<String> crawlJavaDocs(HttpClient client, List<Artifact> artifacts)
132133 List <String > updatedArtifacts = new ArrayList <>();
133134
134135 for (Artifact artifact : artifacts ) {
135- String [] parts = artifact .getName ().split ("-" );
136+ String [] parts = artifact .name ().split ("-" );
136137 StringBuilder path = new StringBuilder ();
137138 path .append (JAVA_DOCS_BASE_URL )
138139 .append (GROUP )
139140 .append ("/" )
140- .append (artifact .getName ())
141+ .append (artifact .name ())
141142 .append ("/" )
142- .append (artifact .getVersion ())
143+ .append (artifact .version ())
143144 .append ("/" )
144145 .append (String .join ("/" , parts ))
145146 .append ("/package-summary.html" );
@@ -155,15 +156,15 @@ static List<String> crawlJavaDocs(HttpClient client, List<Artifact> artifacts)
155156 String .format (
156157 Locale .ROOT ,
157158 "Crawl failed for %s with status code %d at URL %s\n Response: %s" ,
158- artifact .getName (),
159+ artifact .name (),
159160 crawlResponse .statusCode (),
160161 path ,
161162 crawlResponse .body ()));
162163 continue ;
163164 }
164165
165166 if (crawlResponse .body ().contains (JAVA_DOC_DOWNLOADED_TEXT )) {
166- updatedArtifacts .add (artifact .getName ());
167+ updatedArtifacts .add (artifact .name ());
167168 }
168169
169170 Thread .sleep (THROTTLE_MS ); // some light throttling
0 commit comments