Monday, August 31, 2015

Responsive design

When you create a form, Form Builder encourages you to layout fields using multiple columns. This gives you more flexibility in:
  • grouping fields in a logic way;
  • making better use of the space available on the page.

This works well on well on laptops, desktops, and tablets, but not so well on mobile phones. In general, you just don't want your fields to be shown in multiple columns on mobiles, as this will require users to scroll horizontally to see fields "to the left of the page", thus greatly reducing usability.

This is why, starting with version 4.10, your multi-column forms will automatically show in 1 column when accessed from a mobile phone, or any device with narrow screen.


This is done automatically for you, using an approach referred to as responsive web design. If you're upgrading from Orbeon Forms 4.9 or earlier, you'll get this out-of-the-box: you don't need to change anything in in your forms, or set any configuration setting.

For more, see our documentation on responsive design.

Wednesday, August 26, 2015

Orbeon Forms 4.10

Today we released Orbeon Forms 4.10! The main user-visible feature is the introduction of responsive design for mobile devices such as smartphones. Form Builder also gets some nice enhancements.

Major features and enhancements
  • Form Builder
    • Control appearance switcher. Form Builder now features a general-purpose mechanism to switch between control appearances: this allows for example switching between a dropdown menu and radio buttons, adding a character counter to your fields, and more, with just one click! (blogdoc)
    • Maximum and minimum length validations. This release introduces the notion of common constraints. These are validation constraints which can be enabled via the Form Builder user interface without writing formulas by hand. As a first step, we introduce maximum length and minimum length constraints. (blogdoc)
    • Integration. You can now open the Form Builder "New" page with URL parameters which skip the initial dialog. (doc)
  • Form Runner
    • Responsive design for mobile. The Form Runner detail page now features a single-column layout on smaller devices. This also supports the Wizard view. (blogdoc)
    • Accessibility improvements. Output fields use HTML labels. (#1243)
    • Option to show a "character counter" next to a field. This new option for input fields, password fields and text areas displays a character counter next to the field, showing the current number of characters, or, if a maximum length is set, the number of remaining or extra characters. (docblog)
    • Section templates fixes. 
      • Fix execution of actions upon section templates load. (#2233)
      • Fix sending of email recipients, subjects and attachments in section templates (#2016)
    • Form Runner Home page.
      • Don't ask user for credentials more than once. (#2276)
      • Fix refresh of remote server  data when more than one remote server is configured. (#2274)
  • XForms
    • New validation functions. There are two new functions: xxf:max-length() and xxf:min-length(). (doc)
Internationalization

See Localizing Orbeon Forms for the latest localization support. Localization depends on volunteers, so please let us know if you want to help!

Other new features and bug-fixes

Including the major features and enhancements above, we closed over 60 issues since Orbeon Forms 4.9.
    Current browser support
    • Form Builder (creating forms)
      • Chrome 44 (latest stable version) and Chrome 46 dev (current dev channel)
      • Firefox 40 (latest  stable version) and the current Firefox ESR
      • IE 11
      • Safari 8
      • Form Runner (accessing form)
        • All browsers supported by Form Builder (see above)
        • IE8, IE9 and IE10
        • Safari Mobile on iOS 7 and iOS 8
        • Chrome for Android (stable channel)
      Compatibility notes
      • XBL event handlers.
        • Until this version, it was possible for event handlers to listen for events on a different XBL scope. This was not desirable and is removed in this version. Custom XBL components which rely on this will need to be updated. (#243)
      You can download the latest version of Orbeon Forms from the downloads page.
        Don't forget to grab a trial license for the PE version.

        Please send feedback:
        We hope you enjoy this release!

        Wednesday, August 12, 2015

        A dangerous Java 7 JVM option: TieredCompilation

        A while back, we had a customer with a production server exhibiting a curious problem: performance would start well after an application server restart, but over a few days, and sometimes over a single day under heavy load, response times would become longer, until the system would become unresponsive.

        Over weeks we analyzed logs files, trying to figure out whether there were unusual patterns in the user requests. We also connected monitoring tools and a profiler to the production system in order to see whether the VM was running out of memory or other resources.

        Unfortunately, in spite of a number of false leads, we could not figure out anything conclusive. It was as if the system just became slower for no good reason!

        Luckily, after a good deal of additional Googling, we figured out that the culprit was JBoss, or rather, a combination of a particular version of JBoss (JBoss AS 7.1.1.Final) and a particular version of the Java virtual machine (Java 7). [1]

        This version of JBoss forces the -XX:+TieredCompilation VM option behind the scene, and this option is the direct cause of the problem. It is supposed to improve performance, but turns out to have a very serious adverse effect instead. [2]

        Practically, the issue is solved very easily by setting PRESERVE_JAVA_OPTS=true in standalone.conf.

        Clearly, it was wrong of JBoss to set this option by default, and it seems that this was reverted in subsequent versions of the application server. But many organizations are still using JBoss AS 7.1.1.Final, even though it is more than three years old now, and we hope that this post will be useful to somebody else.


        1. Here are some useful links on this issue:  ↩

        2. This option is activated by default with Java 8, and it might be that Java 8 fixes the issues associated with it, but we haven’t tested that.  ↩