Matt RaibleMatt Raible is a writer with a passion for software. 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.

Riding in the Rain

Last night's ride home was an invigorating experience. 30 minutes into my ride it began to rain. Then the lightning came. It made me feel so so alive as I strained my muscles to go faster and I gritted my teeth to block out the cold. 20 minutes later I caught a tailwind and a smile molested my face. 15 minutes after that a double rainbow appeared and I giggled like a little school girl. It was won of my best riding-home experiences and a great feeling of accomplishment flooded my body as I stumbled into our living room. Very wet, but very alive.

Posted in General at Apr 22 2003, 06:44:25 AM MDT Add a Comment

Locking Records in Webapps

Our tester, Roberto, started working at my day job today. This means that I've been hacking and interacting with Bugzilla all day. It's great to have someone to validate our code meets the requirements (BTW, all our requirements are kept in Bugzilla - how's that for dynamic requirements?!) So, as far as satisfying my desire to be a productive American, today has been a good day. After I ride home (~20 miles) tonight, I'll feel on top of the world. Anyway, back to the point of this post.

One of the bugs that Roberto entered was that a user could login using two separate browser sessions (same user), and blah, blah, blah. I'm sure anyone who's worked with webapps has seen this. You open a page up in both browsers, click "Save" in the first, and then "Save" in the second. The second browser overwrites the first one's changes. I've seen this bug many times, but I've never solved it, nor even tried.

I'm curious to know if any of you have solved this? I think Hibernate has a way of locking an object - but will that solve this issue? I'm willing to implement a quick solution, otherwise, I'll argue the bugs validity until I'm blue in the face. Hmmm, I wonder if I can simply use Struts' Tokens feature to solve this problem? Please hook me up if you've solved this problem in your webapps.

Posted in Java at Apr 21 2003, 05:07:24 PM MDT 4 Comments

[ANNOUNCE] Hibernate 2.0rc1

Powered By HIBERNATE Hibernate2 is now functionally complete! Get it at the usual place. The release notes are below.

Hibernate Changelog
===================
Changes in version 2.0 beta 5 (21.4.2003)
-----------------------------------------
* Informix support (Steve Molitor)
* fixed a bug parsing "select new ... " queries
* deprecated "object" type in favor of  mappings
* added Session.contains()
* added extra DBCP config options (?)
* SessionFactory.close() now unbinds from JNDI
* added Session.evict()
* got rid of an unnecessary SQL DELETE issued when an empty collection was dereferenced
* where attribute of collection mappings no longer ignored for deletion
* improved logging
* support polymorphic associations to "embedded" composite id classes
* various bugfixes to collection filter parameter binding
* fixed some problems with proxies introduced in earlier beta versions
* fixed bug with self-reference in the case of identity column id generation
* added hibernate.cglib.use_reflection_optimizer property
* added nonstrict-read-write cache
* fixed an SQL-generation bug in new Criteria API
* added CompositeUserType
* sequence and table id generators now aware of default-schema
* added update and insert attributes to  element
* fixed a bug with expressions like elements(foo.bar.baz) in where clause
* more efficient Set initialization (two-phase load)
* removed support for hibernate.query.imports and added  mapping element
* fixed problem in DBCP connection validation and added new config properties

I'm proud to say that this blog is now Powered By Hibernate (thanks to Dave of course)!

Posted in Java at Apr 21 2003, 05:51:32 AM MDT Add a Comment

Cool idea - highlight entries by category with CSS

This sounds like a cool idea - and should be easy to get working with Roller. However, I'm stumped on making this work. Hopefully someone can help me out with the following macro:

#foreach( $entry in $entries )
#if ($entry.getCategory().startsWith("Java"))
<div style="border-left: 2px solid red">
#else
<div style="border-left: 2px solid blue">
#end

Once I get this working, making my category menu use the same colors will be a great way to indicate which categories I've posted to.

Posted in Roller at Apr 20 2003, 05:45:03 PM MDT 1 Comment

Recovered iPhoto Pictures

I managed to recover my iPhoto pictures by holding down Shift+Option while opening iPhoto, and then rebuilding the library. Unfortunately, my Album information was not repaired so I don't know what's up there. I'm thinking about blowing away my ~/Library/iApps/iPhoto folder and seeing if that helps. I also lost all my subscriptions in NetNewsWire. Damn. I'm glad I don't use a Mac to do my critical dev work on - I don't know if I could handle losing stuff so much.

Posted in Mac OS X at Apr 20 2003, 05:20:25 PM MDT Add a Comment

Happy Easter Everyone!

Abbie's Big Smile
Abbie wanted me to tell you all Happy Easter, so here's a big smile for y'all!

Posted in General at Apr 20 2003, 02:10:16 PM MDT Add a Comment

Upgrading to Roller 0.9.7

I'm starting the upgrade to Roller 0.9.7. Don't stand by with too much earnest - if I get interrupted by Julie and Abbie - they have priority. I'll let you know when I'm done.

Later: I might as well keep a record of what I do to upgrade so it'll be easier next time - and maybe I'll eventually write a script to do it all.

1. I dumped the mysql database from this site using mysqldump. I then created a database locally and imported it.

2. I ran the 0.9.6 to 0.9.7 upgrade script for mysql. I encountered a few errors as I was partially on 0.9.7 already.

3. I edited the log4j.properties file to e-mail me errors and to cut down on Velocity and Hibernate logging. I also got rid of the "R" appender, as that was writing a roller.log file that is essentially the same as Tomcat's log file. I also added timestamping to the log messages.

# Properties for configuring Log4j for this application
# This is the configuring for logging displayed in the Application Server
log4j.rootCategory=INFO, stdout, mail

log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout

# Pattern to output the caller's file name and line number.
log4j.appender.stdout.layout.ConversionPattern=%d %C{1}.%M(%L) | %m%n

# Configuration for receiving e-mails when ERROR messages occur.
log4j.appender.mail=org.apache.log4j.net.SMTPAppender
[email protected]
[email protected]
log4j.appender.mail.SMTPHost=localhost
log4j.appender.mail.Threshold=ERROR
log4j.appender.mail.BufferSize=1
log4j.appender.mail.Subject=[www] Roller Application Error

log4j.appender.mail.layout=org.apache.log4j.PatternLayout
log4j.appender.mail.layout.ConversionPattern=%d [%t] %c %x - %m%n

# If programmed properly the most messages would be at DEBUG 
# and the least at FATAL.

# Options are: DEBUG, INFO, WARN, ERROR, FATAL
log4j.logger.org.roller=ERROR
log4j.logger.org.apache.velocity=ERROR
log4j.logger.org.apache.commons=ERROR
log4j.logger.org.apache.struts=ERROR

# All hibernate log output of "info" level or higher goes to stdout.
# For more verbose logging, change the "info" to "debug" on the last line.
log4j.logger.net.sf.hibernate.ps.PreparedStatementCache=ERROR
log4j.logger.net.sf.hibernate=ERROR

4. Whoa! There's a new look to the index.jsp page. I corrected a small bug in the link around the combined rss badge.

5. I changed oscache.properties to have a "cache.path" that was prudent for my installation.

6. Added home.jsp and changed "main" forward in struts-config.xml to have a path="/home.jsp" so users will be directed to this page, rather than the index.jsp.

7. Onto synchronizing my current web.xml with the new one. Added <welcome-file-list>, <error-page>'s and security settings for my private weblog. Sweet, JSTL has been added so I don't have to add these taglibs or jars. I changed the <form-error-page> to "/login.jsp?error=true". Funny thing is, I never see the login page anymore since I'm using the "Remember Me" feature.

8. Added all custom images from my about page to the "images" directory. Also moved my custom favicon.ico from backed up directory to new roller installation directory.

9. Next, I synched up the settings from my roller-config.xml file with the new one. FYI, e-mailing comments is off by default.

10. Now I guess I need to convert all my pages to use the new macros. I'll do this after upgrading the codebase here. It's kindof a pain to upgrade the codebase, as you've already seen. One of my problems is I have symlinks all over the place in my "roller" directory, so rather than re-creating them, I just upload a .jar of roller, unzip it, and cp -r roller/* webapps/roller/. over my last installation. Crossing my fingers now.

After upgrading code: It looks like I changed the wrong forward, rather than "main", I should've changed "home.page" to home.jsp. I'll let you know if I spot anything crazy while attempting to do my macro migration.

Update: After the macro migration, the only issue I've found (so far) is that #showWebsiteTitle() adds spaces on both ends, and since I'm writing this using JavaScript (for the title image), it's screwing things up. I reverted back to $macros.showWebsiteTitle() and everything works as expected. Now I just have to figure out how to get trackback setup. I tried this, but it didn't work for me. Also, I can't seem to get #showAllNewsfeeds(true 1) to work.

Posted in Roller at Apr 20 2003, 11:10:26 AM MDT 3 Comments

Broadband is back!

Finally, my internet connection is fixed. They replaced all the equipment yesterday (bridge, antenna on roof) and now everything is humming along like lightning. Sweet - good to see you again my friend.

Posted in General at Apr 19 2003, 05:09:15 PM MDT Add a Comment

A Good Job vs. Good Pay

I did the interview with the University of Miami this morning. I was interviewed by a roundtable of folks and the questions weren't too bad - there were some fun ones and some technical ones (i.e. the classic, "what's the difference b/w an interface and an abstract class"). The people sounded very cool and it'd probably be a great team to work on. The pay, however, is not very good at all. However, they said they'd try to work on that. The itneresting thing I've learned is that the best paying jobs are usually the worst jobs. At least that's how it's been for me. I don't know if people just expect more from you, and portray this in the form of micro-management or what, but it sucks to have a job you don't like.

My current job? I love it. Not only because we're using all the cool technologies I like (Ant, Struts, Hibernate, XDoclet, etc.), but also because the people are very cool. Our 8:30 a.m. meetings are actually fun to attend. We poke fun at each other and there's lots of laughter in the room. Today has been an especially good day - I got club level seats to the Rockies Game (baseball) tonight, and also got invited to a pre-release viewing of Matrix Reloaded. Now those are what I call benefits! And, unfortunately, I'm also making the same rate I made six months after I graduated from college. Back then, I couldn't believe how much I was making, and now it's enough to support Julie, Abbie and I (and I'm the only one who works), so it's not too bad.

The problem is the gig at U of M pays around 1/2 of what I'm making now. It'd be an awesome job though. It sounds like they have great people and I'm sure the perks are good (maybe free tuition for my masters?). Look at me talking like I already got the job - I probably just jinxed myself - especially since I gave them the URL to this site. Oh well, if you guys are reading - it sounds like an awesome position, but I don't know if I can support my family on that salary. In fact, I've had such little luck finding a decent paying job in Florida, Julie has started considering a non-move. That is, we might stay in Denver. Jobs here seem to be picking up, and my current contract doesn't seem to have any end in site. They're even talking about putting us on a project developing mobile apps in Java.

Miami is calling though, especially on this cold April afternoon. Now I'm off to freeze my ass off at the Rockies' game. Good thing they're club level seats so we can just sit inside if it's too cold.

Posted in General at Apr 18 2003, 04:35:00 PM MDT 2 Comments

No Dice on Comments

I tried Dave's suggestion for comments, but no dice. Here's what I have:

   #set( $comments = $entry.comments )
   <comments>
   #foreach( $comment in $comments )
   <comment id="$comment.id">
      <author>$comment.name</author> 
      <email />
      <url />
      <timestamp>$comment.postTime</timestamp>
      <body>
         $comment.content
      </body>
   </comment>
   #end
   </comments>

It looks like this Velocity template expects to be a part of something great that exposes the $entry variable. Is it possible to simply pass in an entryid and have the XML generated for that. That's what I really want.

BTW, isn't it lovely how it tries to process the template above? Doesn't seem to for Dave - oh well.

Posted in Roller at Apr 18 2003, 02:43:21 PM MDT 2 Comments