javax.naming.NameNotFoundException: Name [comp/env] is not bound in this Context. Unable to find [comp] error with java scheduler

后端 未结 6 2004
后悔当初
后悔当初 2021-02-05 23:02

What I\'m trying to do is to update my database after a period of time. So I\'m using java scheduler and connection pooling. I don\'t know why but my code only working once. It

6条回答
  •  Happy的楠姐
    2021-02-05 23:33

    Try stopping and restarting your server (I assume you are using Eclipse and a Tomcat server). Maybe when you created your context xml file as it did was empty initially, your server was not able to synchronize its contents hence its inability to find the database connection resource name you later specified in the context.xml file.

    i.e. if you have not already solved this problem.

提交回复
热议问题