Category Archives: Development

There is a lot of activity around the world to set up Wicket Community Meeting. In Copenhagen we had our first meeting a couple of month back and are slowly trying to gather people for a new meeting.

I only wish we could get as many to attend as they have in The Netherlands. At this writing there are 68! attending. What is happening in NL?

UPDATE: Now there are 82 attendees!! Martijn also asked me if I wanted to come by, but I can’t make it this time. Maybe next time.

This is the fourth beta for Apache Wicket we have prepared for your pleasure. It contains over 140 fixes to issues with previous releases and todo items we have cleared.

In this announcement:

  • Apache Wicket
  • This release
    • Portlet support
  • Migrating from 1.2
  • Downloading the release
  • Validating the release
  • Reporting bugs

Eager people click here to download the distribution, others can read further:

http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta4/

We thank you for your patience and support. Given the current list of remaining issues and the fact that we have just accepted portlet support back in, we think a fifth beta release is necessary. But that is no excuse for not giving this fourth installment a test drive!

The Wicket Team

Apache Wicket

Apache Wicket is a component oriented Java web application framework currently undergoing incubation at the Apache Software foundation. With proper mark-up/logic separation, a POJO data model, and a refreshing lack of XML, Apache Wicket makes developing web-apps simple and enjoyable again. Swap the boilerplate, complex debugging and brittle code for powerful, reusable components written with plain Java and HTML.

Our migration to a top level project is now completed and you can find our website and documentation here:

http://wicket.apache.org

This release

This release is the fourth in a series of beta releases until we feel confident to finalize Wicket 1.3. This is called a beta because we don’t have fixed all bugs, and probably haven’t found them all either.

Portlet support

A new feature in this beta4 release is the merge of Ate Douma’s portlet branch into trunk. This reintroduces portlet support in Wicket.

http://cwiki.apache.org/WICKET/portal-howto.html

Migrating from 1.2

If you are coming from Wicket 1.2, you really want to read our migration guide, found on the wiki:

http://cwiki.apache.org/WICKET/migrate-13.html

Downloading the release

You can download the release from the official Apache mirror system, and you can find it through the following link:

http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta4/

For the Maven and Ivy fans out there: update your pom’s to the following, and everything will be downloaded automatically:

<dependency>
    <groupId>org.apache.wicket</groupId>
    <artifactId>wicket</artifactId>
    <version>1.3.0-beta4</version>
</dependency>

Substitute the artifact ID with the projects of your liking to get the other projects.

Please note that we don’t prescribe a Logging implementation for SLF4J. You need to specify yourself which one you prefer. Read more about SLF4J here: http://slf4j.org

Validating the release

The release has been signed by Frank Bille, your release manager for today. The public key can be found in the KEYS file in the download area. Download the KEYS file only from the Apache website.

http://www.apache.org/dist/wicket/1.3.0-beta4/KEYS

Instructions on how to validate the release can be found here:

http://www.apache.org/dev/release-signing.html#check-integrity

Reporting bugs

In case you do encounter a bug, we would appreciate a report in our JIRA:

http://issues.apache.org/jira/browse/WICKET

The distribution

In the distribution you will find a README. The README contains instructions on how to build from source yourself and a list of all things that have been fixed, added and/or removed since the first beta release.

Release Notes – Wicket – Version 1.3.0-beta4

Bug

  • [WICKET-349] – ListView can’t undo changes to model
  • [WICKET-470] – AjaxFormComponentUpdatingBehavior won’t work for RadioChoices
  • [WICKET-497] – For stateless mounted page incorrect url is generated
  • [WICKET-520] – Escape doesn’t work for AjaxEditableLabel in Firefox
  • [WICKET-572] – replacing tr using ajax does not work in safari
  • [WICKET-611] – AbstractRequestTargetUrlCodingStrategy ignores query parameters if there is no parameter in the path
  • [WICKET-631] – Resource.getParameters() empty when resource is mounted
  • [WICKET-635] – FormTester Does Not Properly Handle DropDownChoice With Null Model
  • [WICKET-640] – modal window close button does not cancel the event after closing the window
  • [WICKET-685] – ReloadingWicketFilter not working with markup inheritance
  • [WICKET-705] – StringValue javadoc incorrect regrading conversion to checked exception
  • [WICKET-707] – Invoking a request listener on a page returns an Expired Error page
  • [WICKET-722] – IndicatingAjaxFallbackLink does not remove indicator if the link itself is added via ajax
  • [WICKET-728] – WicketTester could not handle Multipart form without upload
  • [WICKET-735] – SqlTimestampConverter and it’s Date and Time friends die on null and other breakage.
  • [WICKET-745] – AbstractAjaxTimerBehavior triggered more than expected after a new Ajax rendering
  • [WICKET-756] – FormComponent.getValue uses equals instead of == to compare NO_RAW_INPUT
  • [WICKET-775] – Buggy behaviour in FormComponentPanel.setRequired(boolean)
  • [WICKET-782] – Select doesn’t validate ‘Required’
  • [WICKET-796] – setresponsepage() does not properly redirect from ajax requests
  • [WICKET-807] – MockHttpServletRequest.addFile does not work with binary files
  • [WICKET-819] – DefaultButtonImageResource’s fontAttributes field isn’t serializable
  • [WICKET-824] – Session id encoding problem in cookie-less mode
  • [WICKET-826] – No scrolling behaviour of source code viewer in IE 6
  • [WICKET-836] – feedback panels not being updated when inside repeaters
  • [WICKET-842] – <html wicket:id=”html”> is broken again…
  • [WICKET-846] – Javadocs for AbstractDefaultAjaxBehaviorPrecondition#getSuccessScript() and #getPreconditionScript() are swapped
  • [WICKET-849] – Bad multiple select display with DatePicker and ajax debug
  • [WICKET-851] – WicketTester unusable after subsequent startPage(Page) call
  • [WICKET-856] – add dependency slf4j-log4j12 to wicket-quickstart
  • [WICKET-864] – HttpServletResponse.encodeRedirectURL() missing in WicketFilter
  • [WICKET-869] – Back button processing doesn’t work in Opera
  • [WICKET-870] – ignore white space in web.xml filter, filtermapping
  • [WICKET-871] – Markup hirarchy gets messed up when value of attribute ‘background’ is a relative path
  • [WICKET-872] – Typo in org.apache.wicket.markup.html.tree.res.tree.js causes AJAX tree node addition failures
  • [WICKET-874] – Reloading servlet doing way too much reloading
  • [WICKET-877] – stateless page + form + bookmark = trouble
  • [WICKET-878] – IllegalStateException accessing Session.get() from own Resource implementation
  • [WICKET-881] – AbstractChoice not taking into account html escape settings
  • [WICKET-882] – RefreshingView should call super.onBeforeRender after it refreshed it’s items.
  • [WICKET-883] – Modification Watcher Task Log
  • [WICKET-885] – ResourceSettings#getStringResourceLoaders throws an ArrayStoreException
  • [WICKET-886] – InlineFrame with null PageMap raises exception
  • [WICKET-887] – Unable to find InlineFrames when inside ListViews
  • [WICKET-889] – Automatic multi-window support drops URL fragment identifier
  • [WICKET-890] – Modal window causes session expires
  • [WICKET-892] – RefreshingView only gets rendered when TreeTable node is opened twice
  • [WICKET-893] – Relative urls are broken if there is a + in parameter
  • [WICKET-894] – setStripComments corrupts other HTML tags
  • [WICKET-895] – If a form includes a DataTable with AjaxEditableLabels and the form should be refresh an exception occurs when a user switches between a changed label to another
  • [WICKET-896] – wrong redirect BrowserInfoPage and mounted Pages
  • [WICKET-897] – WicketSessionFilter doesn’t work with 1.3
  • [WICKET-899] – Authentication example fails with “PasswordTextField does not support cookies”
  • [WICKET-903] – WicketServlet no longer sets application on current thread
  • [WICKET-906] – It is impossible to inject primitives
  • [WICKET-908] – There is no way to specify what exceptions to log in RequestCycle
  • [WICKET-909] – onBeforeRender not called on ModalWindow contents
  • [WICKET-913] – PopupCloseLink broken with REDIRECT_TO_RENDER strategy
  • [WICKET-914] – Tree not “redrawn” when resetting root node
  • [WICKET-922] – Inconsistent use of Button vs. IFormSubmittingComponent
  • [WICKET-923] – Back button browser problem and ajax
  • [WICKET-929] – ExceptionErrorPage only works with WebResponse
  • [WICKET-934] – textfield strings are not trimmed when performing validation (conversion).
  • [WICKET-935] – AbstractRepeater#onBeforeRender should not be final
  • [WICKET-936] – Wicket:message texts do not change when session locale chages.
  • [WICKET-937] – Wicket Contrib Date Picker Not Picking Up Date Properly In CompoundPropertyModel
  • [WICKET-938] – Second and subsequent ajax component updates fail in Safari
  • [WICKET-946] – WebRequestCodingStrategy is not synchronized
  • [WICKET-951] – the javadoc of FormComponent.updateModel() states: “.. it expect > that the object is already converted through the convert() call”, but FormComponent.updateModel() documentation bug
  • [WICKET-954] – Default button does not provide button name
  • [WICKET-956] – Bug In Wicket Listing Using DataTables
  • [WICKET-960] – FilteredAbstractColumn unary constructor expects Model instead of IModel
  • [WICKET-965] – ReloadingWicketFilter gives ClassCastException with page hierarchy involved
  • [WICKET-973] – setRenderAllowed not called in Tree items
  • [WICKET-974] – Image#getResource always returns null even if there is a resource
  • [WICKET-976] – IndexedParamUrlCodingStrategy chokes inside appendParameters() on Stateless forms
  • [WICKET-977] – Static Pages -> Passing URI to a Wicket page == 404 Error
  • [WICKET-978] – log4j.properties in quickstart archetype uses old wicket package name
  • [WICKET-981] – NPE in Component.remove(final IBehavior behavior)
  • [WICKET-984] – MockWebApplication should use PageFactory from given WebApplication.
  • [WICKET-985] – AjaxFallbackDefaultDataTable in a border fails
  • [WICKET-987] – Stripping javascript comments and whitespace breaks application when using prototype library
  • [WICKET-990] – Localizer complains about component not being added to the page when the component is a page
  • [WICKET-993] – wicket:enclosure doesn’t work with multiple child components
  • [WICKET-994] – Ajax requests may happen before DOM is ready
  • [WICKET-997] – AjaxButton using null as the form in the onSubmit() callback
  • [WICKET-999] – DynamicWebResource function as StaticResource
  • [WICKET-1001] – Misleading EnclosureResolver javadoc and wiki
  • [WICKET-1013] – spring component injection leads to deserialization error (or page expiration)
  • [WICKET-1016] – ExternalLink doesn’t use model
  • [WICKET-1027] – Form.appendDefaultButtonField() appends invalid HTML
  • [WICKET-1036] – Session size is constantly increasing on setResponsePage(getPage())
  • [WICKET-1042] – setResponsePage(PageClass) doesn’t take current pagemap into account
  • [WICKET-1046] – FeedbackMessages don’t get cleaned up in an AJAX request when renderstrategy is REDIRECT_TO_RENDER
  • [WICKET-1050] – MarkupParser.removeComment() does not properly parse to end of HTML comment

Improvement

  • [WICKET-544] – Refactor duplicate code into ConversionException
  • [WICKET-604] – ‘Wicket.Channel’ name is not accessible in ajax related classes
  • [WICKET-646] – Do not throw an error when image not found while testing
  • [WICKET-669] – AjaxEditableLabel needs Model for adding a IValidator
  • [WICKET-771] – Provide ResourceReference with ID attribute for filtering multiple includes
  • [WICKET-780] – Internal server error 500 unresolvable in Ajax Debug Window
  • [WICKET-795] – Easy access to final rendered page source
  • [WICKET-800] – PropertyVariableInterpolator should support escaping of the string ‘${’
  • [WICKET-843] – improve API documentation for getStatelessHint() method in org.apache.wicket.Component
  • [WICKET-845] – Label constructor
  • [WICKET-853] – Repaired invalid HTML markup produced by FilterToolbar
  • [WICKET-854] – ModalWindow.setTitle needs to accept a model
  • [WICKET-879] – reduce code in DatePicker.js (because it can be loaded multiple times per page)
  • [WICKET-880] – Option to align DatePicker to the left of icon
  • [WICKET-898] – JS namespace pollution in wicket-extensions
  • [WICKET-900] – [Patch]Allow to set a custom css to the calendar
  • [WICKET-907] – FeedbackMessage SUCCESS level?
  • [WICKET-927] – Deprecate Fragment constructors that dont take a markup provider
  • [WICKET-941] – Patch to fix layout and positioning issues for the maven generated wicket site
  • [WICKET-955] – Make wizard work with default button
  • [WICKET-961] – Add variables to ConversionException
  • [WICKET-962] – Ajax updates do not work on Components with wicket id that is not \d+ when within AbstractRepeater/RepeatingView
  • [WICKET-964] – provide direct access on output stream in resources
  • [WICKET-970] – Wicket Javadoc Standardization: org.apache.wicket.validation.*
  • [WICKET-971] – Wicket Javadoc Standardization: org.apache.wicket.util.watch
  • [WICKET-986] – Wicket Javadoc Standardization: org.apache.wicket.util.value
  • [WICKET-998] – Remove obsolete attribute modifier
  • [WICKET-1000] – Wicket Javadoc Standardization: org.apache.wicket.time
  • [WICKET-1004] – Label associated with an open/close tag should still work
  • [WICKET-1009] – russian resource files
  • [WICKET-1034] – Allow Custom Javascript on AJAX Busy Indication
  • [WICKET-1041] – Fix a TODO for 1.3 at AjaxFormSubmitBehavior.onError()
  • [WICKET-1044] – Clarification of when children are added to Component tree for TabbedPanel

New Feature

  • [WICKET-480] – IHeaderResponse.renderOnUnLoadJavascript(String javascript);
  • [WICKET-806] – add month/year selection
  • [WICKET-832] – [Patch] add a UrlValidator
  • [WICKET-930] – Wrap Guice-Injector with proxying for Objects
  • [WICKET-939] – Make org.apache.wicket.markup.html.image work with ajax by adding either random or autoindex or??
  • [WICKET-944] – ehcache based MarkupCache (1.3)
  • [WICKET-979] – Wants yahoo calendar to be displayed on page by default (ie no popup)
  • [WICKET-983] – Merge the portlet support branch into the trunk
  • [WICKET-1030] – add support for CalendarGroup
  • [WICKET-1031] – add facilities to execute javascript code to further customize the YUI Calendar

Task

Wish

  • [WICKET-804] – Need a “Getting Started/Creating a new Wicket project” guide

Wicket has graduated from Apache Incubator and has now become an Apache top level project. I would like to thank all the guys who made this possible and especially Martijn (our new PMC Chair). I’m trying to plan a little get-together/meeting in Copenhagen where we would also get a change to drink a glass of Champagne to celebrate it. Join us if you live near Copenhagen!

Wicket is a Java web application framework that takes simplicity, separation of concerns and ease of development to a whole new level. Wicket pages can be mocked up, previewed and later revised using standard WYSIWYG HTML design tools. Dynamic content processing and form handling is all handled in Java code using a first-class component model backed by POJO data beans that can easily be persisted using your favorite technology.

Although Wicket has recently entered the ASF Incubator, this interim release is provided outside of the ASF, solely as a service to existing Wicket users to resolve existing bugs in the Wicket product. As such, this release of the Wicket project is not endorsed or approved by the Apache Software Foundation. The Apache Software Foundation is in no way affiliated with this release. Fixed bugs in Wicket 1.2.4

  • [WICKET-29] – javascript error in wicket-ajax.js: Wicket.Log.Error is not a function
  • [WICKET-31] – Wrong source paths in build.xml
  • [WICKET-35] – WicketTester doesn’t pass PageParameters to bookmarkable pages
  • [WICKET-64] – Check/Radio fail in a GridView with item reuse strategy
  • [WICKET-143] – [PATCH]Re-render a table element via AjaxRequestTarget under IE does not works
  • [WICKET-144] – wrong handling of exceptions for Resource#respond and ComponentResourceRequestTarget#respond
  • [WICKET-179] – ListView should not call getModelObject when not visible in hierarchy

The wicket-team is pleased to announce the release of Wicket 1.2.3! This is a bug fix release for Wicket and is the last release for the 1.2 branch, which now enters maintainance mode. We will now focus on Wicket 2.0 and 1.3.

Even though it is a bug fix release some new features has also sneaked in. F.ex. JMX support, which in 1.2 is in a different project but in 2.0 will be integrated in core.

Oh, and by the way. Martijn has created a special Halloween look for the wicket website. Check it out )

(For those reading this long after halloween 2006 take a look at the screenshot below):

wicket_halloween_thumb.jpg

The [Wicket project][wicket] has released the first maintainance release for Wicket 1.2. This is the first release which has some of my patches in it. This has mostly to do with extending the WicketTester to support testing of AJAX enabled applications. But I have also done a RfcCompliantEmailValidator for wicket-extensions, which validates emails according to the RFC.

Other noticeable highlights (taken from the [Release Notes][release]:

* For improved reliability, instead of utilizing cookies and falling back on a quirky JavasScript, we now use window.name to detect whether we are in sync with the proper page map.
* AjaxFormSubmitBehavior no longer incorrectly calls onSubmit() if an error occured during form processing (this aligns it with Button.onSubmit() semantic), instead a new onError() method will be called to allow for error related ajax target processing.

[wicket]: http://www.wicketframework.org/
[release]: http://sourceforge.net/forum/forum.php?forum_id=594030

Since [trunk][trunk] went 2.0 there have been an extensive amount of failing unit tests. Many of them is because Wicket 2.0 is going to handle things differently which means some of the tests needs to be rewritten/changed to match the new behaviors. These are actually the hardest tests to fix, because they require some knowhow of the specific test.

Some of the tests fails because the ordering of the attributes when added to a tag from Wicket has changed. So all the diff tests which compares the output generated with a static html file now fails. The solution here is quite simple: Just create new static html files for comparison.

Last there were some tests that failed because you can’t add components to parent, which isn’t backed in a Markup file. Many tests just used a dummy page, with no .html file and therefore no matching wicket:id’s for the components added to that page. The solution for this is to have html files which matches the component tree in the tests. Luckily many of the tests had the exact same component hierachy (namely a Page with one component on it), so it didn’t require a new .html file for every one of them.

Yesterday I [fixed][patch] all the failing tests of the last type. I just hate failing unit tests ;-)

[trunk]: http://svn.sourceforge.net/viewcvs.cgi/wicket/trunk/
[patch]: http://svn.sourceforge.net/viewcvs.cgi/wicket?rev=6274&view=rev

I have begun extending the WicketTester to ease the testing of AJAX enabled Wicket applications
My first [patch][revision] extends the clickLink method into accepting clicks on
an AjaxLink. The method then invokes the onClick method on the AjaxLink.

This is a good way to simulate that a user clicks on an AjaxLink. At [Avaleo][avaleo] we use this
method a lot when testing that the flow is correct etc.

The next patch is going to be about actually testing that a component is added to an AjaxRequestTarget
when an AjaxEvent is fired. More on that later…

[revision]: http://svn.sourceforge.net/viewcvs.cgi/wicket?rev=6254&view=rev
[avaleo]: http://www.avaleo.net/

I have added a [patch][revision] for [Wicket 2.0][trunk] which introduces a [ClientEvent enum][clientevent]
for specifying which event on the client should fire the event.

So where you in 1.2 would write something like this:

...
Label label = new Label("label", "This is my label");
label.add(new AjaxEventBehavior("onclick") {
	public void onEvent(AjaxRequestTarget target) {
		// Do your stuff here.
	}
});
...

You now write this:

...
Label lavel = new Label(parent, "label", "This is my label");
label.add(new AjaxEventBehavior(ClientEvent.CLICK) {
	public void onEvent(AjaxRequestTarget target) {
		// Do your stuff here.
	}
});

Which eliminates the problem with misspelling the event name (like “onclck”, “click” or “onclicked”).

[revision]: http://svn.sourceforge.net/viewcvs.cgi/wicket?rev=6243&view=rev
[trunk]: http://svn.sourceforge.net/viewcvs.cgi/wicket/trunk/wicket/
[clientevent]: http://svn.sourceforge.net/viewcvs.cgi/wicket/trunk/wicket/src/java/wicket/ajax/ClientEvent.java?view=markup

The [Wicket development team][wicket] has released the next major release of Wicket.
They have put a lot of effort into making it even more easy for us to develop
professional webapplications. Some of the new features which I think is particulary
useful is the new [AJAX][ajax] support and the WicketTester. (Read the full
[release note][release])

The WicketTester is a great way to test your components without having to use a
container for it. At [Avaleo][avaleo], we have used this the last couple of month since
some of the first beta releases of 1.2 and it really speeds up writing unit tests
for all the components, pages etc that we create.

The last month I have played around with the [AJAX][ajax] implementation and I most say that
it really is nice that you don’t have to do any Javascript yourself to make it work.
At the moment we are strongly considering using [AJAX][ajax] in our application so it’s
great that Wicket provides such a clean and simple API for it.

Just to mention some of the other new features which I believe makes a difference (at least
for me at the moment):

Taken from the [release note][release]:

* Nice URL support through URL mounting
* Spring support for injecting your business logic into your web pages in a non-intrusive manner, while still being able to use the convenient Wicket idiom for creating pages (using the Java new operator).
* Improved performance by replacing OGNL with our own object graph language parser

[wicket]: http://www.wicketframework.org
[ajax]: http://en.wikipedia.org/wiki/Ajax_%28programming%29
[avaleo]: http://www.avaleo.net/
[release]: http://sourceforge.net/mailarchive/forum.php?thread_id=10467093&forum_id=46143