You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by bu...@apache.org on 2005/04/27 22:31:58 UTC

DO NOT REPLY [Bug 34653] New: - ClassCastException at getMessageResources()

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=34653>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34653

           Summary: ClassCastException at getMessageResources()
           Product: Velocity
           Version: 1.5
          Platform: PC
        OS/Version: Windows 2000
            Status: NEW
          Severity: blocker
          Priority: P2
         Component: Tools
        AssignedTo: velocity-dev@jakarta.apache.org
        ReportedBy: carrillo.roberto@gmail.com
                CC: carrillo.roberto@gmail.com


I get the following exception and I dont have a clue why, I use velocity +
struts. I have an ApplicationResources.properties file in the right directory, i
have a toolbox.xml file that is being loaded well according to tomcat's log, but
still 
I get this exception. (read below)

org.apache.struts.config.impl.ModuleConfigImpl

java.lang.ClassCastException: org.apache.struts.config.impl.ModuleConfigImpl
	at org.apache.struts.util.ModuleUtils.getModuleConfig(ModuleUtils.java:78)
	at org.apache.struts.util.ModuleUtils.getModuleConfig(ModuleUtils.java:129)
	at org.apache.struts.util.RequestUtils.getModuleConfig(RequestUtils.java:1109)
	at
org.apache.velocity.tools.struts.StrutsUtils.getMessageResources(StrutsUtils.java:210)
	at
org.apache.velocity.tools.struts.MessageResourcesTool.init(MessageResourcesTool.java:59)
	at org.apache.velocity.tools.view.ViewToolInfo.getInstance(ViewToolInfo.java:133)
	at
org.apache.velocity.tools.view.servlet.ServletToolboxManager.getToolboxContext(ServletToolboxManager.java:354)
	at
org.apache.velocity.tools.view.servlet.VelocityViewServlet.createContext(VelocityViewServlet.java:519)
	at
org.apache.velocity.tools.view.servlet.VelocityViewServlet.doRequest(VelocityViewServlet.java:401)
	at
org.apache.velocity.tools.view.servlet.VelocityViewServlet.doGet(VelocityViewServlet.java:373)


Some other times (when I call a velocity template before calling for the first
struts action, I get a null pointer exception)

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-dev-help@jakarta.apache.org