Matt RaibleMatt Raible is a Web Developer and Java Champion. Connect with him on LinkedIn.

The Angular Mini-Book The Angular Mini-Book is a guide to getting started with Angular. You'll learn how to develop a bare-bones application, test it, and deploy it. Then you'll move on to adding Bootstrap, Angular Material, continuous integration, and authentication.

Spring Boot is a popular framework for building REST APIs. You'll learn how to integrate Angular with Spring Boot and use security best practices like HTTPS and a content security policy.

For book updates, follow @angular_book on Twitter.

The JHipster Mini-Book The JHipster Mini-Book is a guide to getting started with hip technologies today: Angular, Bootstrap, and Spring Boot. All of these frameworks are wrapped up in an easy-to-use project called JHipster.

This book shows you how to build an app with JHipster, and guides you through the plethora of tools, techniques and options you can use. Furthermore, it explains the UI and API building blocks so you understand the underpinnings of your great application.

For book updates, follow @jhipster-book on Twitter.

10+ YEARS


Over 10 years ago, I wrote my first blog post. Since then, I've authored books, had kids, traveled the world, found Trish and blogged about it all.

The Plan for AppFuse 1.9

The current plan for AppFuse 1.9 is to cram quite a bit of stuff into a single release. For example, the big "features" I'm planning on implementing are dependency downloading and the ability to use AppFuse as a single appfuse.jar.

However, there's still quite a bit of stuff on the roadmap.

After talking with the mailing list, the following seems like the best plan.

  • Fix remaining bugs in 1.9
  • Release 1.9 (hopefully in January)
  • Start 2.0 M1 with dependency downloading
  • Release 2.0 M1
  • Start 2.0 M2 with easily upgradeable version
  • Release 2.0 M2
  • Freeze feature enhancements and fix bugs
  • Release 2.0

If I can convince Virtuas to let me work on AppFuse in February and March, we might be able to release 2.0 in early April. If not, we probably won't finish it until sometime next summer.

Posted in Java at Dec 30 2005, 08:27:49 AM MST Add a Comment

Improving JSF in AppFuse

I've noticed the number of AppFuse users using JSF starting to pick up lately. This is probably mostly because Sanjiv Jivan and Thomas Gaudin (both committers) have started to use it on their projects. Thomas has been nice enough to write a couple of interesting blog entries on JSF and AppFuse. Click on the links below to read more.

Posted in Java at Dec 29 2005, 05:09:51 PM MST 1 Comment

Use Ant to auto-build your AppFuse project in Eclipse

One of the issues that AppFuse has is it's not that IDE-friendly. When I first started creating AppFuse (December 2002), Eclipse had already been released. However, I only used it as a fancy text editor, and didn't structure AppFuse to be Eclipse-friendly. Most of the unfriendliness is caused by XDoclet, but there's a way to fix that. Rather than using the default "Java Builder" to auto-build your Eclipse project, you can use Ant. Below is a set of instructions that show how to configure Eclipse 3.1 to use Ant as the builder for an AppFuse project.

Step 1: Right-click on your project and go to Properties. Select the Builder menu on the left and click the "New" button.

Builders

Step 2: Select "Ant Build" in the Configuration Type dialog.

Builders

Step 3: In the Properties window, select the appropriate locations for Buildfile and Base Directory (in the Main tab). In the Targets tab, set everything to the default target. Finally, in the Classpath tag set Ant Home to where you have Ant installed.

Builders

Personally, I haven't used this setup to work on an AppFuse project yet, but it seems quite useful. Hat tip to Erik Weibust to showing me how to do this while at The Spring Experience.

Posted in Java at Dec 29 2005, 12:26:20 PM MST 3 Comments

The future of the DisplayTag Library

From the displaytag-devel mailing list:

I am sorry if I am asking a stupid question but is there any activity going on in the project? There are no new releases for almost a year... Neither are there any news on the project page. In our project we have modified the 1.0 version a bit and would like to share these changes with the community.

Fabrizio's response:

See http://displaytag.sourceforge.net now ;)

the website was frozen to the last 1.0 release, also due an extensive refactoring to the build/documentation system (migration to maven 2, splitting of optional modules and examples, ...) but activity on the project never stopped.

1.1 is now near, and I switched the default homepage to the 1.1 documentation. Warning: it's not released yet, but nightly builds are up.

The biggest feature of 1.1 has to be the ability to do external sorting and paging.

If you're looking for Ajax support in the displaytag, look no further than AjaxTags. I haven't been able to get ajax:displayTag working in my projects because I'm using a newer version of Prototype. However, it looks like the next version of AjaxTags supports the latest version of Prototype.

In addition to AjaxTags, you can also use AjaxAnywhere. Here's the code you'll need to do that (after adding AjaxAnywhere to your project):

<aa:zone name="userTable">

<display:table name="users" class="list" requestURI="" id="userList" export="true" 
    excludedParams="*" pagesize="5" sort="list">
    <display:column property="id" sort="true" href="editUser.html"
        paramId="id" paramProperty="id" titleKey="user.id"/>
    <display:column property="firstName" sort="true" titleKey="user.firstName"/>
    <display:column property="lastName" sort="true" titleKey="user.lastName"/>
    <display:column titleKey="user.birthday" sort="true" sortProperty="birthday">
        <fmt:formatDate value="${userList.birthday}" pattern="${datePattern}"/>
    </display:column>
</display:table>

</aa:zone>

<script type="text/javascript">
    ajaxAnywhere.getZonesToReaload = function() { return "userTable" }
    ajaxAnywhere.onAfterResponseProcessing = function() { replaceLinks() }
    function replaceLinks() {
        // replace all the links in <thead> with onclick's that call AjaxAnywhere
        var sortLinks = $('userList').getElementsByTagName('thead')[0]
                                     .getElementsByTagName('a');
        ajaxifyLinks(sortLinks);
        if (document.getElementsByClassName('pagelinks').length > 0) {
            var pagelinks = document.getElementsByClassName('pagelinks')[0]
                                    .getElementsByTagName('a');
            ajaxifyLinks(pagelinks);
        }
    }
    function ajaxifyLinks(links) {
        for (i=0; i < links.length; i++) {
            links[i].onclick = function() {
                ajaxAnywhere.getAJAX(this.href); 
                return false;
            }
        }
    }
    replaceLinks();
</script>

Libraries used in above code: AjaxAnywhere 1.0.2, DisplayTag 1.0 and Prototype 1.4.0_pre4. You can also see a demo online or download the code.

Posted in Java at Dec 29 2005, 10:46:56 AM MST 26 Comments

[ANN] Equinox 1.5 Released

This release's major new feature is dependency downloading using Maven 2's Ant tasks. The main reason I used Maven 2 over Ivy is because I've heard rumors that Ant 1.7 will include dependency downloading - and they're planning on integrating the work that Maven has already done.

One of the nice things about using Maven 2's Ant Tasks, is you can download Maven 2 and generate your Eclipse or IDEA (possibly even Netbeans) project files using "mvn eclipse:eclipse" or "mvn idea:idea". You can also use Maven 2 to build and test things if you like. The only thing that doesn't currently when using Maven to test Equinox is the web tests with Cargo. I can try to get those working if there's enough demand. For now, you'll have to use Ant if you want to test the UI.

All of the frameworks used in Equinox, as well as its build/test system is explained in Spring Live. A summary of the changes are below (detailed release notes can be found in JIRA):

  • Removed packaged JARs in favor of Maven 2's Ant Tasks. Dependencies are now downloaded on-demand, greatly reducing the size of Equinox-based applications.
  • By specifying compile, test and runtime dependencies in a pom.xml file, Equinox applications can now be built with Maven 2. The only difference between building with Maven 2 and Ant (at this time) is that the M2 build does not support testing with Cargo. However, there is an M2 Cargo plugin so this shouldn't be hard to fix if you have that itch.
  • Added DWR, Script.aculo.us and Prototype to simplify Ajax development.
  • Added Beandoc support - simply run "ant beandoc" to see javadoc-style documentation of Spring context files.
  • Refactored UserManagerTest to be UserManagerImplTest; renamed UserManagerIntegrationTest to UserManagerTest.
  • Changed BaseDAOTestCase to extend AbstractTransactionalDataSourceSpringContextTests.
  • [Hibernate] Added example ehcache.xml to web/WEB-INF/classes for default cache settings.
  • [JSF] Removed client-side validation because corejsf-validator.jar causes issues with Spring's Ant-style path matching.
  • [Spring] Fixed number editor and edit logic in UserFormController.
  • [Struts] Fixed issue with installation where ContextLoaderPlugin was loading ApplicationContext a 2nd time b/c the listener was not being commented out.
  • Dependent packages upgraded:
    • Cargo 0.6
    • Hibernate 3.1
    • iBATIS 2.1.6
    • JPOX 1.1.0 Beta 4
    • MyFaces 1.1.1
    • PostgreSQL JDBC Driver 8.1 Build 404
    • Spring 1.2.6
    • Struts 1.2.8

Download. For more information about installing the various options, see the README.txt file.

Demos:

The basic Equinox download contains all the various web and persistence framework options in the "extras" folder. If you have issues replacing the web framework or persistence engine, please enter an issue in JIRA and I'll build and upload a customized version for you.

Posted in Java at Dec 28 2005, 07:14:43 AM MST 4 Comments

Struts 1.2.8 has client-side validation issues just like 1.2.7

This weekend, I upgraded AppFuse from Struts 1.2.4 to 1.2.8. After failing to upgrade to 1.2.7, I was a little leary of this release - for good reason. It turns out, the 1.2.8 release has the same client-side validation issue as 1.2.7. The good news is it's a Commons Validator issue this time, and you can fix it by upgrading to Commons Validator 1.2.0 (it ships with 1.1.4).

If you're using custom client-side validators, you might have to patch your functions. Here's what I did to mine:

- oTwoFields = eval('new ' + formName.value + '_twofields()');
+ oTwoFields = eval('new ' + retrieveFormName(form) + '_twofields()');

Also, if you'd like to use Spring MVC with Commons Validator 1.2.0, you'll need to patch springmodules-validator. Or you can just download the one from AppFuse's CVS.

Posted in Java at Dec 19 2005, 04:55:37 PM MST 2 Comments

The Ajax Experience

The Ajax Experience looks like it's going to be an excellent show.

We will have the website for the conference launched just after christmas, but here is a taste of the quality speakers that we have confirmed for the event:

  • Scott Dietzen, CTO of Zimbra
  • Alex Russell and Dylan Schiemann of the Dojo Toolkit
  • Thomas Fuchs of Script.aculo.us
  • Sam Stephenson of Prototype and 37 Signals
  • Bob Ippolito of MochiKit
  • Joe Walker of DWR
  • Douglas Crockford of JSON-RPC, and Yahoo!
  • Jonathan Hawkins of Microsoft Atlas
  • Patrick Lightbody of WebWork/Struts Ti
  • Bill Scott of Rico and Yahoo!
  • Eric Pascarello of Ajax in Action
  • Glenn Vanderburg, JavaScript expert
  • Brent Ashley, noted Ajax expert
  • Michael Mahemoff of Ajax Patterns
  • Greg Murray of the JavaServer Faces team at Sun

This is a show I'd love to attend. However, it ends the day before Mother's Day - WTF is up with that?! For those of us who happen to be family men and are planning on attending JavaOne, this sucks. If I want to attend The Ajax Experience, I'd have to fly back on Sunday and then fly back to San Fran on Monday for JavaOne. Booo hisss. Looks like I'll be missing this show.

Posted in Java at Dec 19 2005, 01:12:15 PM MST 4 Comments

RE: Oracle donates ADF Faces to Apache MyFaces

I read the news initially on the AMIS Technology blog, which points to the original news-breaker on the IT-eye Weblog. This is huge for the JSF community IMO. The main compelling feature behind component-based frameworks is components. Without components, there's not much point in them.

By christmas a website and mailing list will be available for the incubator project. You will also be able to download the source code. By New Year a subversion repository should be available with the source code. And the intention is to move out of incubator by JavaOne 2006, which I think is in May.

So why is Oracle doing this? Well it's obvious that Java needs to have a good component based framework to compete with .NET. And Oracle believes that JSF can be this Framework, but a good implementation is needed, which is what ADF Faces provides.

What does ADF Faces, or better Apache Faces Cherokee contain? More than 100 components, an Html AJAX renderkit (but it doesn't use HttpXmlRequest, but iframes), a dialog framework, personalization, skinning, and a lot more.

I wonder if Oracle has a solution for the "everything is a post" problem? ;-)

JSF is cool, and easy to be productive in, but so is Tapestry, WebWork and Spring MVC. I find it somewhat ironic that the Struts committers turned down Shale as Struts 2.0, but they voted in WebWork.

I think component-based frameworks might be the way of the future. However, after playing with OpenLaszlo for the past few weeks - I can't help but think that this is what component-based frameworks should be. Many components, easy to use, and the output is a rich-client out-of-the-box. In addition to the Flash output they have now, I've heard rumblings that OpenLaszlo may support other outputs in the future (i.e. XHTML/Ajax).

It's pretty cool to see continued excitement and innovation in Java. Competition is good, and will only make each of these frameworks stronger and easier to use.

Posted in Java at Dec 12 2005, 02:26:45 PM MST 8 Comments

The Spring Experience - what a show!

Last week, I traveled to beautiful South Florida to attend The Spring Experience conference. This show was put on by Interface21 and No Fluff Just Stuff. Keith Donald (from I21) and Jay Zimmerman (from NFJS) were the organizers and both did an excellent job. This was one of the best conferences I've attended this year, and I've been to many.

Well done gentleman, can't wait for the next one. To read my posts from the event, please see the links below:

This week, most of the Virtuas Practice Leaders are at ApacheCon. Let's hope they blog a little about the event.

Posted in Java at Dec 12 2005, 10:41:41 AM MST Add a Comment

New AppFuse Documentation: Axis, Handling Complex POJOs and Korean Translation

A few AppFuse enthusiasts have been hard at work, writing new documentation and tutorials. First of all, Mika Göckel has written a HowTo implement Axis tutorial - complete with an installation package! I tried it out last night, and it works quite well with AppFuse 1.8.2. If you're using a build from CVS, you'll need to make some modifications because web.xml is no longer generated. Hopefully we can fix that and get this "extras" package into CVS this week.

The 2nd tutorial is titled Handling complex objects with XDoclet, Hibernate and Struts. This one is written by the AppFuse committer Thomas Gaudin. Thomas has now written 5 tutorials, all of which include source code and step-by-step instructions.

Last, but certainly not least, DongGuk Lee has translated a large amount of AppFuse's documentation to Korean. I'm amazed that the QuickStart Guide and Tutorials have now been translated to 6 Languages!

Thanks for the contributions everyone - you guys rock!

Posted in Java at Dec 05 2005, 08:53:21 AM MST 5 Comments