Category "java"

My output not showing the full numbers but showing ?? instead

I'm trying to do benchmarking with JMH, the benchmarking result did come out but not perfectly Somehow there's ?? in the numbers, is it the problem with my IDE

Using java keytool to encrypt imported paswords with PBEWithHmacSHA256AndAES_128

I am looking to store sensitive passwords in a java keystore using java keytool's importpass. I am using Oracle java version 1.8.0_212, and cannot upgrade from

Is there any way to enable/disable a annotation by property in Spring Boot?

I have some property file like: application.properties enable.test.controller=true enable.cross.origin=false I want to enable/disable some functions based on t

How do I set custom tracer in ModelCamelContext?

I am implementing simple camel application using camel 3.14.0. I start using modelcamelcontext. But there is below exception during setting custom tracer. 2022-

How to map a JSON string which includes members named long and short

I need to map a JSON string which includes values named long and short: "status": { "long": "Finished", "short": "F", "elapsed": 90 } I tried the foll

How to change positions of node in a GridPane

I have an 4x4 gridpane object consists of Tiles, extends ImageView, and i want to create method for changing places of connected Tiles by mouse drag and drop. I

Swing JFrame rendering a webpage with embedded video shows a white page and throws IOException with "invalid URL"

I wonder if I do some mistakes because I do not get the content of the webpage displayed on the JFrame. Instead, I only get a white page. The error I got was: j

Java button, switch to another frame, closing current frame and running a method in another class

I have tried creating a button "Menu", and on click it closed the frame that it's on, open a class StartWindow, after that it would use a method "Menu", without

Spring's @DateTimeFormat ignores wanted date format pattern

Can't get my head on how date formatting using @DateTimeFormat works. I send query with date params being: dateCreateFrom - 01.04.2022T00%3A00%3A00 dateCreateTo

java.lang.NullPointerException: Cannot invoke "jdk.internal.platform.CgroupInfo.getMountPoint()" because "anyController" is null

I have an error when I'm trying to copy data from csv file into mysql database, but when I launch the temps.etl.xml file with java launcher, it gives me an erro

Printing out 3 of numbers in java

The output value is 100000 to 10 random natural numbers What should I do to print out only from the right end to the third? And if you print it out with multipl

Cannot add MemberSubstitution using Bytebuddy

I'm trying to add a MemberSubstitution using ByteBuddy to intercept any access to a specific field, but when running the following code I get this error: Could

Amazon DynamoDB delete data based on partition key

I am trying to delete multiple records in DynamoDB table using the partition key and sort key. The approach is taking lot of time to delete the records. I am fo

Java Spring JPA Query Error: '(',<expression>,FUNCTION or identifier expected, got '('

I'm asking the question cuz all the related posts i found are not answered Error at line 21 Screenshot Hello guys I need some help with this Query, at line 21 I

Some table rows are not returned by hibernate native query

I'm having a big problem that a few rows of the table are not returning by the native query of hibernate (Spring Data), although if I put the same query in the

Unable to access CDI

I have a class that contains a method annotated with @PostConstruct which fetchs list of customers @ViewScoped @Named public class CustomerController e

How to write Github workflow for JDK 17

This is the current Github for JDK 11 and works fine. I have migrated my project to JDK 17. It works fine locally but breaks in Github workflows. I don't know h

Error "the constructor HighScore(int,int,String)is undefined" ( game = new HighScore((id, score, user); )

when run the code is shown the constructor HighScore(int, int, String)is undefined" import java.util.Scanner; public class HighScore{ public static HighSc

Can we access to a list of available contexts to an object in java?

We know that we have many types of context in java. Regardless of what these types can do and where to use them, i want to know is there any way to get a list o

What does a "Cannot find symbol" or "Cannot resolve symbol" error mean?

Please explain the following about "Cannot find symbol", "Cannot resolve symbol" or "Symbol not found" errors (in Java): What do they mean? What things can caus