Category "java"

How to programmatically authenticate Subscriber and pass in application credentials json for Spring Cloud

I have a Subscriber app in Java using spring-cloud-gcp-starter-pubsub, but I don't want to authenticate to Google Cloud using a JSON file on the filesystem; we

JDK directory is not set or invalid (unity)?

I am now creating a keystore for my game (in unity) but when I press the add key button, an error pops up Java Development Kit (JDK) directory is not set or

Handle Security exceptions in Spring Boot Resource Server

How can I get my custom ResponseEntityExceptionHandler or OAuth2ExceptionRenderer to handle Exceptions raised by Spring security on a pure resource server? We

Netty shutdown/Stop UDP server

I'm trying to create Netty UDP listener. The problem I faced is that I can't stop udp server like tcp, the udp always is running, even with shutdowngracefully c

what does "&" means in java properties file

what does "&" means in java properties file? for example CopyProjectAction_title = &Copy. does it equal CopyProjectAction_title = Copy?

Failed to determine a suitable driver class

when starting the application, see the below error: Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.

How to avoid VS Code warning: "[myfile].java is a non-project file, only syntax errors are reported"

I am running a build task in a java project in Visual Studio Code. The warning in the "PROBLEMS" tab: [myfile].java is a non-project file, only syntax errors a

Java: How to implement wildcard matching?

I'm researching on how to find k values in the BST that are closest to the target, and came across the following implementation with the rules: '?' Matches

Answer consists out of certain characters

Scanner input = new Scanner(System.in); String[] colors = {"R", "G", "B", "P", "O", "Y"}; String guess = ""; String valid = false; //Get Input guess = input.n

Java - Skipping element of outer loop if condition is true for any element in inner loop

Here's the code: for ( Element e : elements ){ boolean shouldContinue = false; for ( OtherElement oe : otherElements ){ if ( e.magicalCondition(

Break statement not taking me outside of loop java

I am solving this problem on code forces. https://codeforces.com/contest/1675/problem/B The break statement I have doesn't break out of the while loop. When I u

How to set @PartFilename of Entity field in @POST RESTEasy client method in runtime?

I am trying to write Resteasy Client Class to make simple POST multipart/form-data request to upload file. So POST request must contain Content-Disposition: for

Measure execution time in Project Reactor

I'm trying to load test one of my projects and I think somewhere in my changes I may have introduced some point where the performance is getting impacted. Is th

G1GC Old Gen committed heap keeps growing, used is constant - leads to Eden starvation

The G1GC old generation committed heap goes up over time (about 5 to 6 days on production) but the old generation used heap does not. The Eden and survivor hea

Mock final class with Mockito 2

I'm removing Powermock from the project I'm currently working on, so I'm trying to rewrite some existing unitary test only with Mockito (mockito-core-2.2.28). W

why my external css file not loading with html file on my tomcat server

I am beginner and I don't know why my external studentinformation.css file is not loading when I run my Signup.html on tomcat 3.2 or above but loads when I righ

java.lang.reflect.InvocationTargetException launching Minecraft forge server

That happens when I run my Minecraft forge server.bat A problem occurred running the Server launcher.java.lang.reflect.InvocationTargetException at sun

Error sending fetch request (sessionId=1175648978, epoch=189) to node 53: org.apache.kafka.common.errors.DisconnectException

We have a topic with 100 partitions and the load is millions of records per hour. We ran into the problem whenever we deploy a new version of stream-processor

Take a txt file and Insert to tableview (JavaFX)

I try to insert to tableview from txt file, but I couldn't do it. This is my txt file. aa.txt (It contains int A, int B, int F) 0 0 0 1 0 1 0 1 0 1 0 0 Th

No serializer found for class org.hibernate.proxy.pojo.bytebuddy.ByteBuddyInterceptor

When i try to navigate to an endpoint i get the following error Type definition error: [simple type, class org.hibernate.proxy.pojo.bytebuddy.ByteBuddyIntercep