Category "java"

Google play games pop up connection message not showing

Hello I have a game application that use Google play games services with the V2 Sdk, the problem is that the user is automatically connected through the games s

How to add Google Cloud MySQL libs to Tomcat 8.5

We want to deploy our Applications (.war-Files) via Tomcat 8.5 into a k8s-infrastructure, having the depending Database on Google Cloud SQL (MySQL). Google offe

How to get file's icon and type description in Ubuntu?

With Java 11 on Windows, I can get info about my files using: import javax.swing.filechooser.FileSystemView var type = FileSystemView.getFileSystemView().getSy

Unable to assign the result returned by the Method that receives a generic List and returns a List<?>

I'm trying to filter a List of objects that implements an interface. And I'm trying to create a generic method for all the classes. Something like: interface So

How to take 2D array inputs from command Line arguments in java?

I have to take inputs from the command line and assign them to a 2X2 array. Input = 1 2 3 4 (from cmd line) output = 1 2 3 4 int a[][] = new int[

Elasticsearch wildcard query in Java - find all matching fields and replace

I want to update all path fields starting with "example/one". Map<String, Object> parameters = new HashMap<>(); parameters.put("old", "example/one")

How to customize HTTP response for WebSocket upgrade request in Spring?

I have a WebSocket endpoint configured like this in my WebSocketConfigurer implementation public void registerWebSocketHandlers(WebSocketHandlerRegistry regist

Git Diff at method level

I am looking at getting information on all the methods/function Added , Deleted and Modified between any two commits Notes - Code Base is in Java and on Github

How to make sure rector netty http client create fix connection to http server

I use bellow code to create reactor netty http client and use this client to send request. ConnectionProvider connectionProvider = ConnectionProvider.builder("l

What does 'PT' prefix stand for in Duration?

I am trying to use the Duration class instead of long. It has superior literal syntax. I like its flexibility, though it looks weird. "PT10S" means 10 seconds

Java 8 Performance Issues In Windows Server 2019

I have recently migrated some scheduled jobs from a Windows Server 2012 virtual server to a new Windows Server 2019 virtual server, and have noticed some notabl

Create a function with a class Player with values "username" set to input, "size" to 50, "x" and "y" to 0

Trying to create a function with a class Player with values "username" set to input and the rest set to numbers. Searched a few websites but the answers weren't

Android kotlin Object Any type mismatch

How to assign kotlin map to java library map. This gives type mismatch error for Object and Any. I need to assign java map variable in a 3rd party java library

java: error: release version 17 not supported

I recently updated to Intellij 2021.1. However, whenever I try to run my program, I get: java: error: release version 17 not supported I have tried snooping aro

pbkdf2-sha256 hash algorithm issue

Help me please! I am trying to hash password using the pbkdf2-sha256 algorithm. Password = "user1", salt = "IFo7KXYswe7Fiu3BoVNOWg =", hashIterations = "27500".

Failed to launch JVM

I have searched for similar problems on SO but did not find any clues how to resolve this error. Have developed a small console application (running on windows

Generating random character and numbers in java

This is my first post. I am having a hard time writing this program... Write a program that generates a new license plate every time it is executed – one

Can't close JFrame, from click inside JPanel

I have the following situation: I have a JFrame(GridBagLayout) with 3 JPanels in it (headerPanel, bodyPanel, footerPanel); On the bodyPanel I have a login butto

Missing dependency on EmbeddedKafka on integration test with groovy and spock

I've been trying to create an integration test using the embeddedKafka, but I'm getting problem of missing dependency when trying to run it, this is the error:

Oracle 19c compatibility with jdk7

I would like to know if oracle 19c is compatible with jdk 7. I have found out 2 drivers for oracle 19c ojdbc8 : for jdk8, jdk9 and jdk11 ojdbc10 : for jdk10 and