Actually, the url should be in the form: http://host:port/newapp/servlet/newapp
or if you want to "directly" access the login page: http://host:port/newapp/servlet/newapp/template/Login.vm Sorry I can't offer anymore insights to your problem.. :( Regards, Dan On Mon, 8 Apr 2002 [EMAIL PROTECTED] wrote: > > > It crossed my mind too. So I wrote a test file > /templates/app/screens/test.jsp and called the URL > > /myApp/templates/app/screens/test.jsp > > I got a username/password challenge and on authenticating, the page > appears. All files in the directory have the same permissions > > -rw-r--r-- > > It would have been much easier if only I had the right source for Velocity. > > Thanks > -Manu > > > > |--------+-----------------------> > | | "Dan K." | > | | <dantest@York| > | | U.CA> | > | | | > | | 08-04-02 | > | | 05:29 PM | > | | Please | > | | respond to | > | | "Turbine | > | | Users List" | > | | | > |--------+-----------------------> > >-----------------------------------------------------------------------| > | | > | To: Turbine Users List <[EMAIL PROTECTED]> | > | cc: (bcc: manu manickalal/PRTGROUP) | > | Subject: Re: Interesting stacktrace, please help. [sample | > | app] | > >-----------------------------------------------------------------------| > > > > > Looks right. I'd check for your directory/file permissions to see if the > web server or whatever can access them. I'm assuming under the > /templates/app directory there are subdirectories called "screens", > "navigations", "layouts" ... there should be. > > As for your two urls fetching the same page...you can't use the the one: > /templates/app/screens/Login.vm as that would be fetching the file > directly from the web server (i.e. fetches a text file). Use the first > one you mentioned. > > Regards, > Dan > > On Mon, 8 Apr 2002 [EMAIL PROTECTED] wrote: > > > > > > > Thanks Dan, > > > > The entry I have in TurbineResources.properties is > > services.VelocityService.file.resource.loader.path = > > /templates/app,/templates/flux > > > > screens/Login.vm is under /templates/app , this setting looks fine to > me. > > > > Am not sure if this is a problem, but the document root of the web server > > is also the same as the application's root (physical directory). For > > instance if > > > > /export/home/manu/public_html is the document root, it is also where the > > webapp is installed. Both the following URL's would fetch the same page. > > > > /myApp/templates/app/screens/Login.vm > > /templates/app/screens/Login.vm > > > > Thanks > > -Manu > > > > > > > > > > |--------+-----------------------> > > | | "Dan K." | > > | | <dantest@York| > > | | U.CA> | > > | | | > > | | 08-04-02 | > > | | 04:57 PM | > > | | Please | > > | | respond to | > > | | "Turbine | > > | | Users List" | > > | | | > > |--------+-----------------------> > > > >-----------------------------------------------------------------------| > > | > | > > | To: Turbine Users List <[EMAIL PROTECTED]> > | > > | cc: (bcc: manu manickalal/PRTGROUP) > | > > | Subject: Re: Interesting stacktrace, please help. [sample > | > > | app] > | > > > >-----------------------------------------------------------------------| > > > > > > > > > > Hi Manu, > > > > In turbine, velocity looks for the templates specified in the > > TurbineResources.properties file of your web app. In turbine2.1, the > > setting is like: > > > > services.VelocityService.file.resource.loader.path = /templates > > > > If there are more directories that contain your templates then you can > > include additional ones with a comma, like: > > > > services.VelocityService.file.resource.loader.path = > > /templates,/moretemplates,/evenmoretemplates > > > > The template paths specified by this setting is relative to the webapp > > root (e.g. <tomcat_root>/webapps/my_webapp). > > > > Hope this helps, > > Dan > > > > On Mon, 8 Apr 2002 [EMAIL PROTECTED] wrote: > > > > > > > > > > > In my attempts to get a grip on Turbine, I became a recipient of the > > > "Horrible" exception. > > > > > > This is from the sample app "Turbine Data Manager" > > > > > > Horrible Exception: java.lang.Exception: Screen template '/Login.vm' > not > > > found > > > at > > > > > > org.apache.turbine.services.template.TurbineTemplateService.getParsedScreen > > > TemplateName(TurbineTemplateService.java:726) > > > at > > > > > > org.apache.turbine.services.template.TurbineTemplateService.getCachedName(T > > > urbineTemplateService.java:572) > > > at > > > > > > org.apache.turbine.services.template.TurbineTemplateService.getScreenTempla > > > teName(TurbineTemplateService.java:412) > > > at > > > > > > org.apache.turbine.services.template.TurbineTemplate.getScreenTemplateName( > > > TurbineTemplate.java:92) > > > at > > > > > > org.apache.turbine.modules.screens.VelocityScreen.buildTemplate(VelocityScr > > > een.java:129) > > > at > > > > > > org.apache.turbine.modules.screens.TemplateScreen.doBuild(TemplateScreen.ja > > > va:130) > > > at org.apache.turbine.modules.Screen.build(Screen.java:99) > > > at > > > org.apache.turbine.modules.ScreenLoader.eval(ScreenLoader.java:129) > > > at > > > > > > org.apache.turbine.modules.layouts.VelocityECSLayout.doBuild(VelocityECSLay > > > out.java:100) > > > at org.apache.turbine.modules.Layout.build(Layout.java:91) > > > at > > > org.apache.turbine.modules.LayoutLoader.exec(LayoutLoader.java:123) > > > at > > > > > > org.apache.turbine.modules.pages.DefaultPage.doBuild(DefaultPage.java:166) > > > at org.apache.turbine.modules.Page.build(Page.java:90) > > > at > > org.apache.turbine.modules.PageLoader.exec(PageLoader.java:123) > > > at org.apache.turbine.Turbine.doGet(Turbine.java:447) > > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) > > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > > > > > Looking at this after having read the specifications document, makes a > > lot > > > of sense about modules. > > > > > > Turbine -> layouts -> screens -> services... > > > > > > However, when I installed the sample app on my web host (a shared > Tomcat > > > 4.0.1) I got the above Exception. Would anyone know how I could print > out > > > the actual path in which Velocity is looking for Login.vm. Following is > > my > > > attempt at doing the same. > > > > > > I tried searching mail-archive with little success. Next I debugged the > > > application, downloaded turbine2.1 source. Put in debug code in > > > TurbineTemplateService.java and found that the > > > TemplateEngineService.templateExists("screens/Login.vm") call was > > returning > > > negative and hence this Exception being thrown. > > > > > > Getting deeper, I realized that the TemplateEngineService calls > > > TurbineVelocityService, which in turn calls > Velocity.templateExists()... > > > which meant I needed the Velocity source to find which path and file > the > > > application is looking for. So I downloaded the Velocity1.2 source. > > Removed > > > velocity-1.2-dev.jar from the lib directory, compiled the source and > put > > it > > > in. It wouldn't work. I get the following trace.. > > > > > > java.lang.NoClassDefFoundError: org/apache/log/format/Formatter > > > at java.lang.Class.forName1(Native Method) > > > at java.lang.Class.forName(Class.java:134) > > > at > > > > > > org.apache.velocity.runtime.log.LogManager.createLogSystem(LogManager.java: > > > 104) > > > at > > > > > > org.apache.velocity.runtime.RuntimeInstance.initializeLogger(RuntimeInstanc > > > e.java:468) > > > at > > > > > > org.apache.velocity.runtime.RuntimeInstance.init(RuntimeInstance.java:259) > > > at > > > > > > org.apache.velocity.runtime.RuntimeSingleton.init(RuntimeSingleton.java:169 > > > ) > > > at org.apache.velocity.app.Velocity.init(Velocity.java:123) > > > at > > > > > > org.apache.turbine.services.velocity.TurbineVelocityService.initVelocity(Tu > > > rbineVelocityService.java:460) > > > at > > > > > > org.apache.turbine.services.velocity.TurbineVelocityService.init(TurbineVel > > > ocityService.java:138) > > > at > > > > > > org.apache.turbine.services.TurbineBaseService.init(TurbineBaseService.java > > > :108) > > > at > > > > > > org.apache.turbine.services.BaseInitableBroker.initClass(BaseInitableBroker > > > .java:150) > > > at > > > > > > org.apache.turbine.services.BaseServiceBroker.doInitService(BaseServiceBrok > > > er.java:232) > > > at > > > > > > org.apache.turbine.services.BaseServiceBroker.initServices(BaseServiceBroke > > > r.java:197) > > > at org.apache.turbine.Turbine.init(Turbine.java:185) > > > > > > > > > Thats when I realized that I have the wrong source for Velocity. And > > > decided to write and ask for help. Can someone point to the source of > > > velocity-1.2-dev.jar > > > > > > Thanks > > > -Manu > > > > > > > > > > > > -- > > > To unsubscribe, e-mail: < > > mailto:[EMAIL PROTECTED]> > > > For additional commands, e-mail: < > > mailto:[EMAIL PROTECTED]> > > > > > > > > > -- > > To unsubscribe, e-mail: < > > mailto:[EMAIL PROTECTED]> > > For additional commands, e-mail: < > > mailto:[EMAIL PROTECTED]> > > > > > > > > > > > > > > -- > > To unsubscribe, e-mail: < > mailto:[EMAIL PROTECTED]> > > For additional commands, e-mail: < > mailto:[EMAIL PROTECTED]> > > > > > > -- > To unsubscribe, e-mail: < > mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: < > mailto:[EMAIL PROTECTED]> > > > > > > > -- > To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
