Why do I get the exception "No service implements the interface org.apache.tapestry5.internal.InternalComponentResources" when trying to use the BeanEditForm component?
This can occur when you choose the wrong package for your data object, the object edited by the BeanEditForm component. If you place it in the same package as your pages, Tapestry will treat it like a page, and perform a number of transformation on it, including adding a new constructor.
Only component classes should go in the Tapestry-controlled packages (
base under your application's root package). By convention, simple data objects should go in a
data package, and Hibernate entities should go in an
I get an error about "Page did not generate any markup when rendered." but I have a template, what happened?
The most common error here is that the case of the page class did not match the case of the template. For example, you might name your class ViewOrders, but name the template vieworders.tml. The correct name for the template is ViewOrders.tml, matching the case of the Java class name.
Worse, you may find that your application works during development (under Windows, which is case insensitive) but does not work when deployed on a Linux or Unix server, which may be case sensitive.
The other cause of this may be that your template files simply are not being packaged up correctly with the rest of your application. When in doubt, use the Java
jar command to see exactly whats inside your WAR file. Your page templates should either be in the root folder of the WAR, or package with the corresponding .class file.
My application fails with the error PermGen, how do I fix this?
PermGen refers to the part of the Java memory space devoted to permanent objects, which are mostly loaded classes. When developing under Tapestry, many more classes and class loaders are created than normal; this is part of live class reloading. Because of this, you will want to increase the amount of memory Java devotes to this.
The solution is to add
-XX:MaxPermSize=512m to your command line. You may also want to increase the regular amount of heap space with
-Xmx600M. Of course, you may need to adjust the amount of memory in each category to match your actual application, but these are good starting values.
Java Virtual Machine arguments can be specified inside an Eclipse launch configuration:
Why do I sometimes get a
java.lang.NoSuchMethodError exception after reloading my page?
Tapestry's live class reloading is not perfect. It tends to use a lot of Java ClassLoaders on top of the normal ClassLoaders used by the Java Virtual Machine and the servlet container. When you change non-component classes and interfaces that are referenced by components and pages, such as to add or change a method, only the component classes are reloaded. The non-component classes are frozen as they were when they were first loaded.
Unfortunately, this is one of the areas where you must restart your application entirely in order to force the new versions of the non-component classes to be loaded into memory.