File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Ant, Maven and Other Build Tools and the fly likes Maven - FileNotFoundException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven - FileNotFoundException" Watch "Maven - FileNotFoundException" New topic

Maven - FileNotFoundException

Mouli Natarajan

Joined: Feb 18, 2009
Posts: 5
Hi All,

Hope you are fine and great too.

I am deploying from application in tomcat and i use maven as my build tool.While deploying my application I get the following Exception (FileNotFoundException). I actually changed a value field which had the location file:///f: in the propertyPlaceHolder.xml .But the change is not reflecting when I start the server it still points to the old location and throws an FileNotFoundException.

EVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanInitializationException: Could not load properties; nested exception is d:\projects\ (The system cannot find the path specified)
Caused by: d:\projects\

Please help me with this problem.Thanks in advance.

Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 17417

I don't think this is a Maven problem. It appears you have stale data in your Tomcat application deployment.

Try this:

1. stop Tomcat

2. delete the subdirectory in the tomcat webapps directory that contains your application.

3. delete the subdirectory in the tomcat/work/Catalina/localhost directory that corresponds to that application.

4. Just to say you did it, clean out the tomcat temp directory.

5. Redeploy the app and start Tomcat.

To completely flush out all the lint, you should shutdown and restart your web browser, too. Or at least clear its cache.

An IDE is no substitute for an Intelligent Developer.
Mouli Natarajan

Joined: Feb 18, 2009
Posts: 5
Hi Tim,

Thanks for your reply.

I tried that too but it didnt work.If I change to something else say a G: directory it throws an exception so it is able to identify the change in the file but I am not able to understand why it is not recognizng my change.Please find the log below.

INFO: Loading properties file from URL [file:/f:/temp
18, 2009 8:08:17 AM loadProperties
INFO: Loading properties file from URL [file:/d:/temp

First it goes into F:\temp and than it goes to d:\temp.I am not able to understand why it goes back again to d:\

Martijn Verburg

Joined: Jun 24, 2003
Posts: 3275

You need to search your configuration to see where you are referencing those drive letters...

Cheers, Martijn - Blog,
Twitter, PCGen, Ikasan, My The Well-Grounded Java Developer book!,
My start-up.
I agree. Here's the link:
subject: Maven - FileNotFoundException
It's not a secret anymore!