Skip to content

Tag: java

How can i change the Gradle Version in InteliJ?

I have the Error: “Found invalid Gradle JVM configuration” “JDK 17.0.1 isn´t compatible with gradle 7.1. Please fix JAVA_HOME enviroment variable” Im not sure why it says gradle 7.1. The gradle Version i have is 7.4.2. This version should work with JDK 17 Answer Take a look at the grad…

Java streams average

I need to create two methods using streams. A method that returns an average score of each task. and a method that returns a task with the highest average score. I can only modify those 2 methods. Here is CourseResult class And methods that create CourseResult objects. Based on these methods I can calculate a…

Unable to receive data out of api call with webclient

So I’m trying to get my head around the webclient, but I keep getting a nullpointerexception, though my test work fine and say that object is not null. I also see my console making connection to the api. But when I ask the value, I get null. Here are the two objects I use for it: and then here I

Resubmit Callable to executorService on exception

My situation I’m trying to craft a functionality which would execute n (where n >=0) requests to a given endpoint, but I do understand that sometimes that endpoint might not respond due to 500 error or other issue, so I want to repeat my requests to an endpoint (with a small interval in between [not …