Announcement Announcement Module
Collapse
No announcement yet.
Unable to load Application Context using ClassPathXmlApplicationContext Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Unable to load Application Context using ClassPathXmlApplicationContext

    Hi,

    Once I'm trying to load the Application context using the below code

    ApplicationContext appCtx = new ClassPathXmlApplicationContext( "applicationContext.xml");

    It is giving a java.security.PrivilegedActionException. Anybody face this problem anytime before??

    Please help.

    Thanks
    Sreejith

  • #2
    Are you working in a corporate environment? Your JVM might have a security manager policy that prevents certain code from running (e.g. unsigned, unlicensed, unapproved, etc.). If this is a case you would need to figure out the approved method to go about doing what you're trying to do (e.g. use a development-only / sandbox environment or server, sign the jar using your organization's private key, etc.).

    You may be able to catch the exception and inspect it for more details.

    Comment


    • #3
      http://java.sun.com/j2se/1.5.0/docs/...#AllPermission is a good reference for the permissions doug mentioned.

      Comment

      Working...
      X