Skip to content
Advertisement

Elasticsearch stops working after I run the springboot Java program and elasticsearch transport node is not loading in my Java Program

Elasticsearch version 8.1.3 Java version 1.8 Im trying to connect elasticsearch with Java springboot program. My Elasticsearch works fine until I run the Java program, also my java program works fine but with “.d.e.r.s.AbstractElasticsearchRepository : failed to load elasticsearch nodes : org.elasticsearch.client.transport.NoNodeAvailableException: None of the configured nodes are available: [{#transport#-1}{LsJSQJtCS56wr7IM_S0h4Q}{localhost}{127.0.0.1:9300}]” on springboot error. Also, as soon as I run my

Pretty message on exceptions from REST app

I have a problem with my REST app. Here is the git link to ease your burden: https://github.com/TheNiceGuy123/AstonishingBackEnd Here is the raw code also: Classes posted in order: Employee Controller: Employee Service: Global Exception Handler: CNPNotFoundException class: ApiErrorModel class: I want to give some relevant informations to the user like in the second picture but in postman everything remains at

Spring Api-Gateway: (M1) java.lang.UnsatisfiedLinkError: no netty_resolver_dns_native_macos_aarch_64

Just to clearify this only occurs on M1 Mac, the intel version doesn’t seem to have this problem. JDK 17 Project Diagram Problem: java.lang.UnsatisfiedLinkError exception is thrown when trying to access one of the microservice through API-Gateway. For example, http://localhost:8082/API-USER/users/status/ok will throw this exception. The return value is correct, API-Gateway continuse to run dispite the annoying exception. Question Does any

Java: FileOutputStream(“NUL:”) not working after Java upgrade

On Windows, NUL is the null output device similar to /dev/null on Linux. With Oracle Java 8 Update 331, trying to get a new FileOutputStream(“NUL:”) throws an exception. Previously (Java 8u321) it worked fine. The problem seems to be the colon: new FileOutputStream(“NUL”) – OK new FileOutputStream(“NUL:”) – exception Can anyone point me to docs or JDK sources regarding this

How can I return null of denominator is 0 in this method Java

I am struggling with creation of a to calculate fractions and return in an array[3]. So if nominator is 7 and denominator is 3 it should return {2,1,3}, a fraction part and a integer part. If denominator is 0, the integer division should not be executed and I have to return null (not print it). That is what I am

Converting a scanner.next() to a char[]

I want to give a function a char array from scanner.next(). I only get an error message if I try to convert it like I do it now: This is the errormessage I get: It also shows this error on the other ones where I want to pass the char[] over. Need to add more text cause they say it

Unable to start activity: java.lang.ArrayIndexOutOfBoundsException

Everyone, hi! Friends, when you click on the button, a new activity does not start. The following exception occurs: java.lang.ArrayIndexOutOfBoundsException. The log of my error is presented below: Program code for MainActivity.java Program code for PlayerActivity.java: If I understand correctly, then the error is in the following lines: But… I do not know how to fix the error. Could you

Best practice for storing TOKEN/password in Java

I’m working on a Java application that interacts with a REST API. To communicate with this API, I must use TOKEN, all these TOKEN are sensitive data and I cannot write in my code. So I’m looking for a way like a configuration file to store the TOKEN and access it. Currently, I made an XML file with all my

Advertisement