I want to get CDI/Weld working on a command line application. Weld is finicky, the project artifact has to be the first on the classpath, and its manifest has to contain the entire classpath. The projectArtifactFirstInClassPath parameter is fine for small projects, but once I have too many dependencies the startup script crashes. I have to add useWildcardClassPath, which completely negates the former parameter.
Classpath with projectArtifactFirstInClassPath:
set CLASSPATH="%BASEDIR%"\conf;"%REPO%"\recovery-tools-1.2.1-SNAPSHOT.jar;"%REPO%"\weld-se-core-3.1.4.Final.jar;"%REPO%"\weld-environment-common-3.1.4.Final.jar;...
Classpath with useWildcardClassPath:
set CLASSPATH="%BASEDIR%"\conf;"%REPO%"\*
What I want:
set CLASSPATH="%BASEDIR%"\conf;"%REPO%"\recovery-tools-1.2.1-SNAPSHOT.jar;"%REPO%"\*
I want to get CDI/Weld working on a command line application. Weld is finicky, the project artifact has to be the first on the classpath, and its manifest has to contain the entire classpath. The projectArtifactFirstInClassPath parameter is fine for small projects, but once I have too many dependencies the startup script crashes. I have to add useWildcardClassPath, which completely negates the former parameter.
Classpath with projectArtifactFirstInClassPath:
set CLASSPATH="%BASEDIR%"\conf;"%REPO%"\recovery-tools-1.2.1-SNAPSHOT.jar;"%REPO%"\weld-se-core-3.1.4.Final.jar;"%REPO%"\weld-environment-common-3.1.4.Final.jar;...
Classpath with useWildcardClassPath:
set CLASSPATH="%BASEDIR%"\conf;"%REPO%"\*
What I want:
set CLASSPATH="%BASEDIR%"\conf;"%REPO%"\recovery-tools-1.2.1-SNAPSHOT.jar;"%REPO%"\*