Serge Yurk

+ Follow
since Apr 09, 2011
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Serge Yurk

Thank you, Kishori Sharan.
Congratulations all.
1 week ago
Hi Kishori,
By what time do you expect the rate of new issue discovery in Java13 will be relatively low to move a production system on Java 13?
Thank you in advance,
2 weeks ago
I use this plugin as I have mentioned before.
I’ll try to teach it to assemble projects with unpacked configuration files.
8 years ago
by 2 I mean the case when the main class and surrounding classes are not packed at all.
They are in file system as a bunch of files.

In this case we need to get from maven a list of used jars,
concatenate them into JAVA_CLASSPATH,
then add a reference on config to JAVA_CLASSPATH
and launch an application by command like
java $JAVA_OPTS –cp $ JAVA_CLASSPATH MainClass.
8 years ago
Thank you, Tim.
The last way is definitely better. But there are at least 2 issues on this way.

1. Let the main class is in a jar and configuration files are in a folder config. Question: How can I tell maven to add config to the Class-Path entry of a jar that contains the main class?

2. Let the main class is not in any jar. Question: How can I tell maven not to make jar from the main module of my project?
8 years ago

I develop a standalone application.

It consists of several modules and uses a Spring container and JPA above Hibernate.
I use Maven maven-jar-plugin and maven-assembly-plugin to build app.

I would like to have configuration files (persistence.xml, Spring context files and a log4j configuration) outside of the application’s jar.

What is the best way to do that?

Thanks in advance.

8 years ago