Category "java"

log4j writing to console but not to file (Liferay + Tomcat)

I've recently had issues with my Liferay/Tomcat logs getting clogged up from several portlets logging to the same files, which makes it tough to track down issu

Add JavaFX jmods to java --list-modules

Preface: I need to open .jar files which requires Java and JavaFX. I have installed both Java (from Oracle website) and JavaFX (SDK from openjfx website). I ha

how to read a value from Column Name in Excel in Java

How can I read a value related to Specific Column Names with Apache POI in Excel (xlsx). Column Names is my 1st Row of Excel Sheet . value is the row Which hav

setUp method: Failed to connect to binary FirefoxBinary(/usr/bin/firefox) on port 7055; process output follows:

When I am running Selenium-Webdriver scripts in Eclipse, it works fine. But the same scripts are running in jenkins in server machine, it is giving the followin

Spring MongoDB query sorting

I'm fairly new on mongodb, and while I'm trying to make ordered mongodb query. But spring data mongodb's sort method is deprecated. So I used org.springframewor

How to modify PdfPCell so that you can remove a part of a border (e.g BOTTOM, TOP, LEFT)?

Here an example of my code: PdfPCell row6cell_1 = new PdfPCell(row6Par_1); row6cell_1.setBorder(Rectangle.NO_BORDER); row6cell_1.setBorder(Rectan

Error in replacing image from Aspose.slide java

Error :- WARNING: An illegal reflective access operation has occurred WARNING: Illegal reflective access by com.aspose.slides.ms.core.System.Drawing.ima

Java Questions Regarding declaring a list of Comparable objects

It is a pretty simple one. I want to declare a list of objects, but I want make sure all objects implemented the Comparable interface. What should I do? I try t

How to read geography values using hibernate?

In my spring boot application, I am trying to store spatial data using spring data with hibernate (jpa). Full source code of minimal reproducing example is avai

Java Thread lock on static method

As per my knowledge in Java class with Non static synchronize method : lock acquire on particular object Static synchronize method : lock acquire on class I a

How to remove auto generated code from Netbeans

Whenever I create new JPanelForm, NetBeans will create some auto generated code in initComponents() method. How can I remove this auto generated code from my JP

Hibernate: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.spi.CacheImplementor]

I am attempting to deploy an application on a glassfish 4 server on my local machine. When I copy the .war file into the autodeploy directory, the glassfish log

How to delete a node from a circular linked list in Java?

Given a Circular linked list write a method in Java to delete a node.

JAVA_HOME no change for ionic run android

I am developing in Ionic 4. I am using mac Mojave, and according to java -version, I am using 1.8.0_201, and $ JAVA_HOME also points to 1.8.0_201. However, when

How to exclude all files under a directory in Gradle?

packagingOptions { exclude 'org/apache/commons/codec/language/bm/gen_approx_portuguese.txt' } For example, this one will exclude 1 file. But how to exclude a

Spring @Value annotation always evaluating as null?

So, I have a simple properties file with the following entries: my.value=123 another.value=hello world This properties file is being loaded using a PropertyP

java: how to both read and write to & from process through pipe (stdin/stdout)

(i'm new to java) I need to start a process and receive 2 or 3 handles: for STDIN, STDOUT, (and STDERR), so I can write input to the process and receive its out

Set background color in Java on a JPanel doesn't work

I am working on a "paint-like" application (a little drawing software) to familiarize with Java 2D components. Here is my problem: I have a JFrame whose Content

LocalDateTime - deserialization with LocalDateTime.parse

I have the field initiationDate which serialises by ToStringSerializer class to ISO-8601 format. @JsonSerialize(using = ToStringSerializer.class) private Local

AuthenticationSuccessEvent never fired

I writing app where user logs in using facebook. My security config/application class: @SpringBootApplication @EnableOAuth2Sso @ComponentScan(basePackages = {