Category "java"

Spring MVC Controller testing PUT

Trying to test my web tier (spring boot, spring mvc) with junit5 and mockito. All other tests on http methods (get, put, ...) are working fine but the update. F

How to make Java Mac App that doesn't require installing Java

I want to make a Mac Application using Java code I wrote, and I want to make it that the person using it doesn't require Java to be installed on their own compu

Getting error as char cannot be dereferenced in java

Getting char cannot be dereferenced error , while writing following code for(int i =1;i<=m;i++){ for(int j =1;j<=l;j++){ if(A.charAt(i-1).equa

Spring Boot and H2 Table Population Error: org.hibernate.tool.schema.spi.CommandAcceptanceException: Error executing DDL

I am having trouble getting an H2 In Memory database to populate. The idea here to have the BuildingCode which is unique as a primary key and id. I get the foll

Randomise each element of String from inside? [duplicate]

I am trying to change the place of characters in a string. The first and last have to stay like they are. For example: String str = "String te

how to set JVM arguments with quota for a Managed Server started by Node Manager

I have a WebLogic domain with multiple Managed Servers. Everything runs on separated hosts. The managed servers are started by Node Manager. According to the Or

Issue with Spring batch metadata tables

I created the spring batch metadata tables using the following link in my own oracle database https://github.com/spring-projects/spring-batch/tree/main/spring-b

Caused by: java.net.SocketTimeoutException: Accept timed out

I am getting this error while running pyspark package in pycharm using python 3.9 using this below code. from pyspark.sql import SparkSession from pyspark.sql.t

Thymeleaf + spring save new object instead of update

I am asking for a hint. I searched the internet for a long time for a solution to the problem, but I'm already desperate. I would like the update operation to u

Java Spring Reactive, returning one Mono<..> from many multiple requests

[Java, Spring Reactive, MongoDB] I'm currently trying to learn Reactive programming by doing and I found a challenge. I have db object CategoryDB which looks li

Is there a neat way of converting lists into maps with the keys set to the elements of original collection and values set to an enum in java

Java newbie... I have a dictionary like so: electronictypeModelsMap = { "laptops" => ["macbook", "thinkpad", "yoga"], "desktops" => ["macmini", "imac", "o

Spring boot mapsId

Hi I using spring boot jpa and I need to use mapsid. There are not so much information about that and I wonder if anyone can help me understand how to use maybe

File pattern was reassigned to file type by 'Android' plugin. You can confirm or revert reassigning pattern

I am developing an app using Flutter 2.10.3 but I assume this issue is not related to Flutter. Since upgrading to Android Studio Bumblebee | 2021.1.1 Patch 2 I

Netbeans jsp, errors not showing

when i write in jsp page using Netbean javaWeb it doenst show error or do completations while coding ive to run it in order to show the errors and it's really a

arrays and methods help needed

i've been puzzling over this for about 5 hours now, I just can't get the errors to stop. am I doing something fundamentally wrong, or misunderstanding something

How to formate or validate date in java like 20992012 or 12122022? [duplicate]

i have to validate date yyyyMMdd or MMddyyyy or ddMMyyyy. if i pass input 20221224, ho to make this is valid? but how can i do this in regex

how to add 'host_name' extension for SNI in java (using jetty)

i am trying in every way to add the SNI to my client (jetty 11.0.9). The server requires me to send host_name, but there is no way with jetty. can anyone do it?

How can I compare User and password input to a text file?

Heyoo! I'm creating a simple login form using the swing package in java and I am having trouble in checking if the username and password is correct or not. this

What is the best practice for solving the number of cases of N searches in Spring JPA?

What is the best practice for solving the number of cases of N searches? There are 3 search conditions for me. There are search conditions of A, B, and C. In th

Proper mapping ( JPA ) composite key

For example i have entities @Entity public class A{ @Id Long Id; ... } @Entity public class B{ @Id Long Id; ... } @Entity @IdClass(ABId.class). public class AB{