Skip to content

Commit

Permalink
add a delay
Browse files Browse the repository at this point in the history
  • Loading branch information
Yinnii committed Oct 4, 2024
1 parent 004b8c8 commit e552bd5
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -636,6 +636,13 @@ public ResponseEntity<JSONObject> biwibot(HttpServletRequest req, @RequestBody J
.build();
// Send the request
HttpResponse<String> respond = httpClient.send(httpRequest, HttpResponse.BodyHandlers.ofString());

try {
Thread.sleep(2500);
} catch (InterruptedException e) {
e.printStackTrace();
}

int responseCode = respond.statusCode();
if (responseCode == HttpURLConnection.HTTP_OK) {
System.out.println("Response from service: " + respond.body());
Expand Down

0 comments on commit e552bd5

Please sign in to comment.