Category "java"

how to send a byte array in kafka with Avro Schema registry

I'm trying to send bytes with a JSON object using a Java POJO and an Avro schema, with schema registry. So my question is, how should my code send "bytes" type

How to fetch a HCP file from Amazons3 bucket using objectId as input parameter is there any API?

I'm using getObject("filepath"); to retrieve a document /xml file from HCP. I need to pass an Object in input to the getObject(); method and retrieve the same.

Setting connection properties on the URL object

Question: Is there a way to set the connection properties on the URL object? Background: We are connecting to a remote server that requires certain connection p

How I access objects which I create in scene builder? JAVAFX

For example, I created a grid pane, added text areas into every cell. Now I want to get grid pane as an Object to do something with it in my Controller class? H

How to prohibit usage of classes with certain annotation

In our organizations we've got several microservices and lots of libraries. Some libraries define "public" classes that are not intended for public usage - only

How to find first match in Flux and stop processing in Reactor

Can't figure out how to stop processing Flux on first match. This what I have right now: findAll(): Flux<Object> findStorageId(Relation r): Mono<Long&g

Error: incompatible types: possible lossy conversion from double to in [duplicate]

I'm trying to print the start value with the conversion but I'm getting this error: error: incompatible types: possible lossy conversion from

Combine @Component and @ConditionalOnBean into one annotation

I want to combine two Spring annotations into a single one. More exactly I want to combine @Component and @ConditionalOnBean into one annotation named @SubCompo

My customAdapter for recycler view is not working

What is the problem causing the recycler view not to show? MainActivity.java import androidx.appcompat.app.AppCompatActivity; import androidx.recyclerview.widge

How can I validate two fields like password and confirm password in Struts 2?

I am doing web application in that I want to validate two fields in the JSP form. In registration filed I have so many fields. In that I want to validate passwo

Cordova Android: Can I get any information on underlying Java/HTTP exceptions

I have an Ionic/Cordova Android application that is deployed on various different client internal networks, where the application connects to a http service run

It's seems hibernate ignores allocationSize

I'm trying different hibernate id generation strategies and I've noticed that it seems like hibernate ignores allocationSize. I have the following entity class:

Why casting a very large long number to int gives us a strange output (Java)?

I was practicing some castings in Java and I faced a situation for which I couldn't find any answers, anywhere. There are a lot of similar questions with answer

WebFlux Spring Boot @Transactional with reactive MongoDB

Does WebFlux Spring Boot @Transactional annotation work with reactive MongoDB? I use WebFlux Spring Boot with reactive MongoDB like: id 'org.springframework

Update array object mongoDB

I have an array of objects and would like to update the count of the object where categoryId = "menu2" and subCategoryId = "1". in my mongodb i currently have t

Why one request triggered CORS policy but the other not?

I use the same request func to yield call two api on the server. Model func code: const pomdata = yield call(pullInfo1, payload) const data = yield call(pullinf

Update array object mongoDB

I have an array of objects and would like to update the count of the object where categoryId = "menu2" and subCategoryId = "1". in my mongodb i currently have t

Could not resolve all files for configuration ':app:debugRuntimeClasspath' android studio

I'm new to Android development with Java. I made an app that allows you to log in with Google and Facebook. Everything worked fine until about three days ago wh

Why is JDBC SQLITE TRUNCATE operation throwing an error?

My program throws an error when I try to execute truncate query using JDBC java with sqlite. import java.sql.*; public class sqlTruncate { public static voi

Dynamic heap implementation with insert O(log n)

I'm trying to implement a Min Heap in Java, but between studying the complexity and the actual implementation, I realized that it is not clear to me how O (log