Greetings,

I have a simple Ant Task, which looks up EJB in it. 
it works when i run it via Eclipse IDE >run as java app but whne i try to
run it via Ant it gives an NoInitialContextException. Folder structure is
like this 
-root
-root/lib
-root/execute.xml

lib folder conatins all the neccesary jar files, this is not a problem Ant
can find all the needed classes. The particular Ant Task clas is in
-root/lib/Myclient.jar which has this structure:
-Myclient.jar/myPackage/MyAntTask.class
-Myclient.jar/jndi.properties

Ant succesfuly finds the task and runs it, but when it comes to 'ic = new
InitialContext();'  it throws an  javax.naming.NoInitialContextException:
Need to specify class name in environment or system property, or as an
applet parameter, or in an application resource file: 
java.naming.factory.initial

but the jndi.properties fiels provided is correct, as  I mentioned It works
when i run it from IDE. But somehow Ant doesnt not recognise it 
Any help would be very appreciated.Thanks Matus

 
-- 
View this message in context: 
http://www.nabble.com/how-to-define-JNDI-props%2C-ant-failed-to-find-them-when-runnin-ant-task-tf4467155.html#a12736986
Sent from the Ant - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to