5 Replies Latest reply on Mar 14, 2007 3:20 AM by slogger

    Lost retrieving resource bandle in ActionHandler

    slogger

      I want to get ResourceBundle in my ActionHandler implementation

      code:

      public class ChangeStatus implements ActionHandler{
      
       private static final long serialVersionUID = 1L;
      
       public void execute(ExecutionContext executionContext) throws Exception {
       String tmp = (String)
       ResourceBundle resource = ResourceBundle.getBundle("org.Errors");
       }
      
      }
      


      After signal on execution I get following Exception:

      19:20:22,031 ERROR [GraphElement] action threw exception: Can't find bundle for base name org.Errors, locale en
      java.util.MissingResourceException: Can't find bundle for base name org.Errors, locale en
       at java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:836)
       at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:796)
       at java.util.ResourceBundle.getBundle(ResourceBundle.java:576)
       at rfc.actions.ChangeStatus.execute(ChangeStatus.java:19)
       at org.jbpm.graph.def.Action.execute(Action.java:123)
       at org.jbpm.graph.def.GraphElement.executeAction(GraphElement.java:235)
       at org.jbpm.graph.def.GraphElement.executeActions(GraphElement.java:212)
       at org.jbpm.graph.def.GraphElement.fireAndPropagateEvent(GraphElement.java:182)
       at org.jbpm.graph.def.GraphElement.fireEvent(GraphElement.java:166)
       at org.jbpm.graph.def.Node.enter(Node.java:301)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:585)
       at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:205)
       at org.jbpm.graph.def.Node_$$_javassist_46.enter(Node_$$_javassist_46.java)
       at org.jbpm.graph.def.Transition.take(Transition.java:119)
      
       ... more


      In other words, classloader couldn't found the resource file Errors.propperties

      I was attempt to create process archive using GPD and found Errors.propperties file in classes\org\ directory. in other words, this resource should be

      found by classloader.

      Please help! Sorry my English!