You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Dan Adams <da...@ifactory.com> on 2008/05/29 15:59:33 UTC

Eating the dog food: experiences with T5 so far

Hey all,

I've been pretty quiet the last couple months because I've been very, very focused on a high-priority project here at the factory. We recently decided to use T5 for the project (a pretty major move which I expect to extend to the rest of engineering) and I thought I'd share some of what I'm doing and how it's gone so far.

The project is a internal application that will handle ~200 users at a time during peak usage and will manage 12,000+ projects per year. It's integrating with up to 5 external systems. I wish I could give you more detailed info because it's got some sweet features but, alas, I cannot.

Notes on project infrastructure:
 * Uses Hibernate extensively
 * Uses Lucene for searching
 * We have an internal t5-based library (or 3 actually) that aids in building CMS and other administrative applications. One library provides super-slick Lucene integration for Hibernate entities. Some of this (like the @Cached annotation) has already been donated to t5. I'm very open to donating more in the future if I feel like it fits into T5 and isn't too specific to our company.
 * Testing environment is all embedded, staging is on tomcat with oracle. Deployment is on weblogic with oracle in a big cluster.

Some notes on the development environment:
 * Testng is used for testing. Selenium is used for web tests.

 * Jetty is used for the web server. On start-up (at registry creation), an embedded HSQLDB instance is started and the tables are created based on the Hibernate entities automatically. Takes 2-3 seconds.

 * All web tests are written against the Selenium interface. However, I've built some tools around this (in addition to the normal helper methods):

   * A wrapper that watches for Tapestry exception pages. If one is found it parses the exception type, message, and stack trace and rethrows it in the test (as a nested exception) so that you get 1) where and how your test failed and 2) what the exception was in the application. 99% of the time it eliminates the need to re-run the test or manually click through the pages to find out what the problem really is.

   * An unbelievably slick adapter that allows running any or all web tests in HtmlUnit instead of Selenium without ever touching the HtmlUnit API or even knowing it's there. Most of the features are supported (except for things like taking a screenshot) and the transition is seamless. The HtmlUnit tests start up and run *much* faster than Selenium which helps a ton if you are doing TDD (which we do).

   * I'm considering writing a similar Selenium adapter over PageTester to make writing page/component unit tests easier (and take advantage of things like our helper methods).

 * For component/page unit testing, we have a base class that creates a PageTester and starts an embedded HSQLDB instance as with the full Jetty integration tests. Also, any service from the t5 IoC registry can be injected into your test case class using the @Inject annotation (even on private fields).

Some things I've found difficult (off the top of my head):
 * Knowing the format for a contribution and the service I need to contribute to. Is it an ordered config or non-ordered? What type does the configuration take? etc. I normally find what I need by searching through TapestryModule for similar contributions.
 * Having an event handler not get called and not knowing why. Specifically not being able to use onValidateFromFieldname() with beaneditform is a bummer. I've had to fall back to using onValidateForm() instead.

After eating my own dog food the last couples weeks the experience has been pretty positive, especially considering the framework is still in beta. Overall it's a vast improvement over T4 in terms of development speed and the potential for efficiencies is huge. It's also just a lot of fun. Development on this project is just starting so I'm sure I'll have more comments at the end of it.

Dan Adams
Senior Software Engineer
Interactive Factory
p: 617.235.5857


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: Eating the dog food: experiences with T5 so far

Posted by Howard Lewis Ship <hl...@gmail.com>.
On Thu, May 29, 2008 at 6:59 AM, Dan Adams <da...@ifactory.com> wrote:
> Hey all,
>
> I've been pretty quiet the last couple months because I've been very, very focused on a high-priority project here at the factory. We recently decided to use T5 for the project (a pretty major move which I expect to extend to the rest of engineering) and I thought I'd share some of what I'm doing and how it's gone so far.
>
> The project is a internal application that will handle ~200 users at a time during peak usage and will manage 12,000+ projects per year. It's integrating with up to 5 external systems. I wish I could give you more detailed info because it's got some sweet features but, alas, I cannot.
>
> Notes on project infrastructure:
>  * Uses Hibernate extensively
>  * Uses Lucene for searching
>  * We have an internal t5-based library (or 3 actually) that aids in building CMS and other administrative applications. One library provides super-slick Lucene integration for Hibernate entities. Some of this (like the @Cached annotation) has already been donated to t5. I'm very open to donating more in the future if I feel like it fits into T5 and isn't too specific to our company.
>  * Testing environment is all embedded, staging is on tomcat with oracle. Deployment is on weblogic with oracle in a big cluster.
>
> Some notes on the development environment:
>  * Testng is used for testing. Selenium is used for web tests.
>
>  * Jetty is used for the web server. On start-up (at registry creation), an embedded HSQLDB instance is started and the tables are created based on the Hibernate entities automatically. Takes 2-3 seconds.
>
>  * All web tests are written against the Selenium interface. However, I've built some tools around this (in addition to the normal helper methods):
>
>   * A wrapper that watches for Tapestry exception pages. If one is found it parses the exception type, message, and stack trace and rethrows it in the test (as a nested exception) so that you get 1) where and how your test failed and 2) what the exception was in the application. 99% of the time it eliminates the need to re-run the test or manually click through the pages to find out what the problem really is.
>
>   * An unbelievably slick adapter that allows running any or all web tests in HtmlUnit instead of Selenium without ever touching the HtmlUnit API or even knowing it's there. Most of the features are supported (except for things like taking a screenshot) and the transition is seamless. The HtmlUnit tests start up and run *much* faster than Selenium which helps a ton if you are doing TDD (which we do).
>
>   * I'm considering writing a similar Selenium adapter over PageTester to make writing page/component unit tests easier (and take advantage of things like our helper methods).
>
>  * For component/page unit testing, we have a base class that creates a PageTester and starts an embedded HSQLDB instance as with the full Jetty integration tests. Also, any service from the t5 IoC registry can be injected into your test case class using the @Inject annotation (even on private fields).
>
> Some things I've found difficult (off the top of my head):
>  * Knowing the format for a contribution and the service I need to contribute to. Is it an ordered config or non-ordered? What type does the configuration take? etc. I normally find what I need by searching through TapestryModule for similar contributions.
>  * Having an event handler not get called and not knowing why. Specifically not being able to use onValidateFromFieldname() with beaneditform is a bummer. I've had to fall back to using onValidateForm() instead.

It is, after all, onValidateFromComponentId(), and the component is
usually on an entirely different page.  BeanEditor giveth, and
BeanEditor taketh away.

>
> After eating my own dog food the last couples weeks the experience has been pretty positive, especially considering the framework is still in beta. Overall it's a vast improvement over T4 in terms of development speed and the potential for efficiencies is huge. It's also just a lot of fun. Development on this project is just starting so I'm sure I'll have more comments at the end of it.
>
> Dan Adams
> Senior Software Engineer
> Interactive Factory
> p: 617.235.5857
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: Eating the dog food: experiences with T5 so far

Posted by Oliver Geisser <ol...@gmail.com>.
Hi Dan.

On Thu, May 29, 2008 at 3:59 PM, Dan Adams <da...@ifactory.com> wrote:

> Hey all,
>
> I've been pretty quiet the last couple months because I've been very, very
> focused on a high-priority project here at the factory. We recently decided
> to use T5 for the project (a pretty major move which I expect to extend to
> the rest of engineering) and I thought I'd share some of what I'm doing and
> how it's gone so far.
>
> The project is a internal application that will handle ~200 users at a time
> during peak usage and will manage 12,000+ projects per year. It's
> integrating with up to 5 external systems. I wish I could give you more
> detailed info because it's got some sweet features but, alas, I cannot.
>
> Notes on project infrastructure:
>  * Uses Hibernate extensively
>  * Uses Lucene for searching
>  * We have an internal t5-based library (or 3 actually) that aids in
> building CMS and other administrative applications

 [...]

Thanks for the insight.

Can you tell us a little bit more about your CMS approach?

Do you modify the .tml files? Or did you have developed "CMS enabled
components" which will
load their content from an external source? Or something else?

Thanks, Olli

-- 
og

Antwort: Eating the dog food: experiences with T5 so far

Posted by Christian Koeberl <ch...@porsche.co.at>.
Hi Dan!

>  * We have an internal t5-based library (or 3 actually) that aids in
> building CMS and other administrative applications. One library 
> provides super-slick Lucene integration for Hibernate entities.

We're just looking through Lucene to use it in our T5/Hibernate apps. 
We're just examining Hibernate Search (http://search.hibernate.org/) which 
looks quite good for us (I've got a small demo running with it). Maybe you 
could share some of the ideas/concepts/experiences in your Lucene 
integration.

Thanks,
Chris