Microsoft
Software
Hardware
Network
Question : maven bootclasspath append
I have built socket provider factory library: net-socket-provider by maven.
How should I configure other module pom.xml dependencies to use net-socket-provider in compile and tests as bootclasspath/a:net-socket
-provider-
1.0.jar ?
When I configure dependency as system or compile I get:
java.lang.SecurityExceptio
n: Prohibited package name: java.net
at java.lang.ClassLoader.preD
efineClass
(ClassLoad
er.java:48
0)
at java.lang.ClassLoader.defi
neClassCon
d(ClassLoa
der.java:6
26)
at java.lang.ClassLoader.defi
neClass(Cl
assLoader.
java:616)
at java.security.SecureClassL
oader.defi
neClass(Se
cureClassL
oader.java
:141)
at java.net.URLClassLoader.de
fineClass(
URLClassLo
ader.java:
283)
at java.net.URLClassLoader.ac
cess$000(U
RLClassLoa
der.java:5
8)
at java.net.URLClassLoader$1.
run(URLCla
ssLoader.j
ava:197)
at java.security.AccessContro
ller.doPri
vileged(Na
tive Method)
at java.net.URLClassLoader.fi
ndClass(UR
LClassLoad
er.java:19
0)
at java.lang.ClassLoader.load
Class(Clas
sLoader.ja
va:307)
at sun.misc.Launcher$AppClass
Loader.loa
dClass(Lau
ncher.java
:301)
at java.lang.ClassLoader.load
Class(Clas
sLoader.ja
va:248)
at line:
Socket.setSocketImplFactor
y(new MySocketFactory());
When I call by hand:
javac/java -Xbootclasspath/a:net-sock
et-provide
r-1.0.jar ....
everything works correctly.
Answer : maven bootclasspath append
depends how you are running your tests, foir example surfire provides options you could use to pass option
http://maven.apache.org/pl
ugins/mave
n-surefire
-plugin/te
st-
mojo.ht
ml
Random Solutions
Page Performance Tuning
quadratic equation: Keep getting 1 answer right, the other one won't match up
Create a query in access 2007 that updates data in MS SQL 2005
T-Sql Query problem
Sony Bravia screen burn in
Force MsgBox popup when users are logged into XP
How do I get my printer to print in colour
Lookup column on diffent list doesn't display my field
How can i remove all <summary> tags and the comments inside them?
How to turn off or alter amount of space used by System Restore and Shadow Copy in Vista?