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.

[JavaOne] Experiences with the 1.5 Language Features

This is the last session I plan on attending today, and it's titled "Experiences with the 1.5 Language Features: Tips and Techniques" by Tim Hanson and Jess Garms of BEA. Tonight looks to be a good time with the JBoss Party, Java Blogger Meetup (@ Thirsty Bear), the Pavilion Party. Times for the events are 5-9, 6-8 and 6:30-8. This conference is definitely packed, and I expect the parties to be the same. In other words, the best part of this shindig is yet to begin. ;-)

This talk is about how to make effective use of the new 1.5 Language Features in your applications.

For Each Loop: Initialization expression is evaluated once (unlike former). Major limitation of using the new for each loop is you don't have access to the index or the iterator.

Annotations: Built-in annotations - i.e. @SuppressWarnings("deprecation"). Possible values: all, deprecation, unchecked, fallthrough, path, serial, finally. This annotation is not supported in the latest version of Java 5, it is supported in Mustang and Eclipse 3.1. @Deprecated is another built-in annotations. If you use this tag, you should use the @deprecated javadoc tag as well. Last one is @Override, which is used to indicate that a method declaration is intended to override a method declaration in a superclass. If the superclass signature changes, this annotation will make sure you change it in child classes.

Annotations are especially useful for frameworks (i.e. EJBs, Web Services, etc.). Not a preprocessor, not a silver bullet.

Enums: Better than static final int. Type-safe. Utility classes: java.util.EnumMap and EnumSet. Public static final int-like behavior: Comparable, statically importable (even as an inner class).

Varargs: Special syntax for cleaning up code. Allows you to use "String... args" instead of a whole slew of methods that take multiple arguments. Use them sparingly - avoid code that casts.

Covariant Returns: Replaces three anti-patterns.

Using Generics: Example from Collections - static List Collections.singletonList(T o). There is a two-pass inferencing process to determine what T is. Other Generified classes: Class (public T newInstance()), Comparable (public int compareTo(T o)), Enum> (public Class getDeclaringClass()). You can also use wildcards with generics, which has a syntax of List instead of List. This allows you to specify subtypes, and not be tied to a strictly typed solution. Wildcards are great to use in APIs and to hide implementations from users.

I give up - this guy has been going on about Generics for far too long. Time to go hunt down some parties.

Posted in JavaOne at Jun 27 2005, 06:20:51 PM MDT 1 Comment

[JavaOne] Programming Puzzlers with the Google Guys

I'm sitting in a session titled "Yet More Programming Puzzlers" by Joshua Block and Neal Gafter. The other two sessions I chose for this time slot were Groovy and EJB 3. The main reason I chose this session is I've seen these guys in action before and they're excellent speakers. As part of this conference, I'd like to learn a bit about technology - but I'm more interested in becoming a better speaker. This is only my second of the day, with the first being the general session this morning. The afternoon has been spent networking, doing some Virtuas booth time, and presentation a short talk on AppFuse on the java.net booth.

In other news, it's pretty cool to see that BEA is going to start supporting Spring and Struts in its tools and servers.

The BEA WebLogic Workshop and other tools will be designed to allow applications to be built or blended from leading open source frameworks, including Apache Beehive, the Spring Framework and Apache Struts, and can then be deployed on BEA WebLogic Server. BEA will also certify the BEA WebLogic Workshop tools for Apache Geronimo and Apache Tomcat.

The Google Guys session? Entertaining and packed. All chairs were filled and many people were standing in the back and on the sides.

Posted in JavaOne at Jun 27 2005, 04:19:38 PM MDT 1 Comment

Made it to JavaOne

I arrived in San Francisco at 8:30 this morning, and headed downtown to the Moscone center. I've been sitting in the "General Session" room for the last couple of hours, and there's been some interesting announcements. You can get a Sun Ultra 20 Workstation for $30/month and it comes with a 90-day money-back guarantee. The guy on stage made it sound like a screaming machine, but it was also a Sun sales pitch.

Another announcement is they're dropping the "2" from J2EE and J2SE. Now we're not supposed to say the "J", but rather "Java". Now it's called "Java EE". I think the 2 needed to be dropped, but I think it'll take a while before Java EE has the same ring as J2EE. I can already see folks calling it "Java, eh".

Posted in JavaOne at Jun 27 2005, 12:02:17 PM MDT 4 Comments

[ANN] Equinox 1.4 Released

This release is mainly to support Spring 1.2.1 and Hibernate 3.0.5. The default database is now PostgreSQL because of an issue with Hibernate 3 and HSQL. All of the frameworks used in Equinox, as well as its build/test system is explained in Spring Live. Detailed release notes are below:

- Added "typeMismatch.java.util.Date" key to messages.properties (for Spring) to display a friendly error for invalid dates.
- Changed to use PostgreSQL as the default database because of an issue with HSQL and Hibernate 3.0. Read more »
- Added "clear" target to build.xml for clearing out the database.
- Added MySQL JDBC Driver and jdbc.properties.mysql for easy switching to MySQL.
- Changed UserWebTest (jWebUnit test) to get lastInsertedId from UI using HttpUnit rather than using UserManager (Richard Easterling).
- Changed spring-sandbox.jar to springmodules-validator-0.1.jar since Commons Validator support for Spring has moved to the Spring Modules project.
- Changed all Spring XML files to use new "value" and "ref" attributes.
- Dependent packages upgraded:

  • Cargo 0.5
  • Log4j 1.2.9
  • Hibernate 3.0.5
  • iBATIS 2.1.0
  • OJB 1.0.3
  • Spring 1.2.1

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 or persistence framework (or both), please enter an issue in JIRA and I'll build and upload a customized version for you.

Posted in Java at Jun 27 2005, 06:27:23 AM MDT 5 Comments

Flying all over the place

I had a tremendous amount of fun this past weekend. On Friday, I flew from Denver to New York City (JFK) to attend a good friend's wedding. Friday night was the rehearsal dinner, followed by a night on the town at Webster Hall with a bunch of old college buddies. We didn't get home until 5:00 a.m. that night. Saturday we had lunch at Gramaldis in Brooklyn, which is supposedly some of the best pizza in NYC. It was definitely cool to be right in the heart of the city, eating great pizza and sipping on cold Coronas.

The wedding was held on Saturday at the Hammond Museum in North Salem, NY. The ceremony was outside in a Japanese Garden and it couldn't have been a more perfect setting. That night we were up until 4, and I woke up at 7:30 to catch a cab, train, bus and plane to get me back home. Now I'm heading to the airport to catch a flight to JavaOne. Should be a fun week.

Posted in General at Jun 27 2005, 04:10:46 AM MDT Add a Comment