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.

Java powers ready.gov!

I'm sure you've heard of the new ready.gov website by now. I found out on one of the first pages that it's written using JSPs. I like the site design too - looks good. I don't know that I'll read it, but it's good to see such a professional looking site.

Posted in Java at Feb 19 2003, 10:49:05 PM MST Add a Comment

JSP 1.2 <-> JSP 2.0

Here's something that I need: A way to convert JSP 1.2 pages to JSP 2.0 pages. Basically, this only really involves changing all the <c:out value="${...}" /> tags to be simply ${...}. I have a couple motivations for this. The first is that Wrox wants struts-resume and security-example to be written using JSP 2.0 (it is a JSP 2.0 book after all). However, I'm afraid that most developers won't be able to use 2.0 for quite some time, considering that the J2EE 1.4 (with JSP 2.0) won't be released until this summer. So I'd like a way to create a JSP 1.2 version and a JSP 2.0 version of my these applications from the same source code. What would be best - to write the source in JSP 1.2 and then parse it for <c:out /> tags and strip them accordingly? I'd rather write the source in JSP 2.0 and then add in the <c:out /> tags using Ant, since it'd be much simpler. Then again, I've already written a fair amount using JSTL with 1.2. Comments and suggestions are encouraged!

Posted in Java at Feb 19 2003, 04:45:02 PM MST 2 Comments

ModelJ Code Generator

ModelJ looks like an interesting tool if you're using Struts, EJBs and JBoss.

ModelJ is a RAD (Rapid Application Development) tool that uses code generation to create complete J2EE designs using the Struts and EJB frameworks. With ModelJ, you are only a few steps away from a complete application readily deployable to JBoss, the leading open-source J2EE Application Server. ModelJ uses proven design patterns to ensure a robust, easy-to-maintain design.

Posted in Java at Feb 18 2003, 08:16:16 AM MST Add a Comment

Keep your JVM Running with JSW

Carlos's post about Java Service Wrapper might be just what I'm looking for. This site seems to have stabalized a bit thanks to Keith's Perl script that checks for OutOfMemory errors (I can see that Tomcat gets restarted a few times a day). I think it's Roller, but I'm running a November version of it, so that's probably the issue. I plan on upgrading this weekend and then we'll see what happens. In the meantime, I'm going to let Keith know about JSW, seems like a very useful tool. Thanks for the tip Carlos!

Posted in Java at Feb 18 2003, 07:09:22 AM MST Add a Comment

StrutsCX: Updated

I received the following e-mail from Berny, the author of StrutsCX.

Thanks Matt for hosting a StrutsCX sample. As the author of StrutsCX I do have some news for you: There is a new release with support of FOP/PDF, client side XSLT, XSL pipelineing and included Struts Validator. Check out http://it.cappuccinonet.com/strutscx.

Would be great if you could update on the latest version. Would you mind if I put a link on the StrutsCX Homepage to the Demo?

Thanks,
Berny

I actually upgraded my demo site when I received his e-mail on Saturday, but didn't get around to returning his e-mail until today. I dig the Validator stuff - only seems to be server-side though.

Posted in Java at Feb 17 2003, 08:26:00 PM MST Add a Comment

Easy Windows Authentication with Tomcat 4.x

The original blog entry by Robert Rasmussen has disappeared from the Internet (cannot find server) so I'm reproducing it here via Google's caching feature. I've made a few changes to pretty up the formatting, but that's about it.


I've been pulled into a little internal project, and one of the requirements is that users should be able to authenticate with their Windows login and password. IIS may or may not be in the picture.

Since the server is a Windows 2000 machine, this turns out to be extremely simple to do thanks to Andy Armstrong's JAAS login modules.

Once you've downloaded the login modules, set your classpath accordingly and make sure that the directory holding NTSystem.dll is in your %PATH% variable. Next, in the "Sample config" folder you'll find a tagish.login file and a java.security.sample file. The last line in the .sample file is significant, and it needs to be in your $JAVA_HOME/jre/lib/security folder (in a file named java.security). You should copy the tagish.login file there as well. If your users will always be logging into the same domain (which is the case in my situation), just set the defaultDomain property in tagish.login, like this:

NTLogin
{
    com.tagish.auth.win32.NTSystemLogin required returnNames=true returnSIDs=false defaultDomain=YOUR_DOMAIN_HERE;
};

Now, all you need to do to use Windows authentication in your webapps is to make one addition to your server.xml file (or to your specific context's definition):

<Realm className="org.apache.catalina.realm.JAASRealm" debug="99"
       appName="NTLogin"
       userClassNames="com.tagish.auth.win32.NTPrincipal"
       roleClassNames="com.tagish.auth.win32.NTPrincipal" />

I'll admit this config is slightly hokey. If you look at the Catalina JAASCallbackHandler (which is hardwired to JAASRealm), the way that I have the realm configured above pretty much counts on the User principal (in effect, the user name) being the first principal returned. This is evil, but it works. It would be nice if either Catalina allowed a pluggable CallbackHandler so that I could take advantage of the NTPrincipal.getType() method or if Andy's code returned subclasses of NTPrincipal like UserPrincipal or GroupPrincipal that I could specify in server.xml.

Once you've got this all configured, the various groups your users belong to equate to role names (so if I belong to an administrators group, my authenticated user will be in role "administrators"), and you can configure security in your webapps using these roles.


Posted in Java at Feb 17 2003, 04:11:52 PM MST 19 Comments

Comparative analysis of Struts vs. WebWork vs. Barracuda vs. Maverick?

Does anyone know of a comparative analysis of Struts, WebWork, Barracuda and Maverick. I'd love to find a paragraph or two that I could quote in my chapter on Struts. I'm not at all attempting to say that Struts is better than any of these - I just want to give a fair shake to each one. The reason I'm writing this chapter on Struts is because that's what I'm most familiar with.

Thanks,

Matt

Posted in Java at Feb 17 2003, 09:34:44 AM MST 4 Comments

Struts 1.1 RC1 To Be Released Soon

The Struts Committers are voting on a release plan for a 1.1 Release Candidate. Lots of +1's so far, so I'd expect it in the next couple of days. The release plan says tomorrow is the code freeze date.

Posted in Java at Feb 17 2003, 09:08:26 AM MST Add a Comment

Struts Training (Darn Cheap too)

If you're looking to learn more about advanced features of Struts, you might want to checkout BaseBeans's upcoming training. I received the following e-mail in my Inbox this evening.

Announce: "*Best Practices in Struts -  Web Training*" by Cekvenich, 
Husted, and Turner and a presentation by Momjian on PostgreSQL. (each a 
published author)

Struts 1.1 might be released in March, so every Saturday at 10:30 AM 
Easter, watch and hear presentation via WebEx.com.

Meeting #	Date	 Title
616291003	1-Mar	 MVC Intermediate Setup
614301419	8-Mar	 MVC View for CMS/Contact
611367121	15-Mar 	 MVC – Ted Advanced + DAO Lab
611903740	22-Mar	 MVC – Bruce pgSQL + Multi Row Lab
611213868	29-Mar	 MVC - Turner + Options/Nested
(once you connect via PC, telecom phone is 1-408-964-1050)

This presentation is almost FREE (other than the cost of WebEx), the 
sooner you register, the cheaper it is.

A week of training by others could be $2400! Plus travel costs. Plus 
they did not get voted best, baseBeans.com did!

Register and pay at: http://www.basebeans.com/do/classReservation
Cost of all 5 sessions + labs (8 hours for each session) is .... $155 if 
you pre-register, or $275 if you late register and $475 if you register 
in March.

Labs (on your own time, hours each) include: Multi Row Updates, 
Validation, Tiles, Navigation, EL, Nested, Options, CRUD, etc. full 
agenda was published.

Each lab is at least 8 hours and required, if you do not do the labs, 
the next presentation will not make sense, no pretenders here. No money 
back for this, other baseBeans.com presentations are money back!

I'd sign up, but Saturdays are reserved for Julie and Abbie.

Posted in Java at Feb 16 2003, 07:34:22 PM MST Add a Comment

Wrox Chapters: Round II

I, like Dave, have been working my butt off all weekend to try and get my Wrox Chapters edited and returned by tomorrow. Can you imagine my jealousy when I say his post this morning saying he was done?! That bastard!! ;-)

As you can see, I've returned to mismanaging my time (i.e. blogging). I've finished the 2nd drafts of my Wrox Professional JSP chapters. The reviewers seemed to like my 1st drafts, especially the Performance and Debugging chapter, but that did not stop them from making hundreds of comments and thus burning two perfectly good weekends.

Dave - you had two weekends!! I'm even more jealous now! I only got one - think it had something to do with me turning my first chapter in a week late, and the second one in 3 weeks late!? Probably...

Oh well, I just finished my security chapter, and while it did eat up my entire weekend - I greatly enhanced it to be a much better chapter. Just as an indicator - it went from 21 pages to 40! Now it has a lot more examples and includes how-to's for configuring Tomcat's Realms (MemoryRealm, JDBCRealm, JNDIRealm and JAASRealm) and for implementing "Remember Me" functionality. The realm stuff was pretty cool - I setup OpenLDAP and was able to get that working with a JNDIRealm and also hooked a JAASRealm into the workgroup that my Windows machines belong to. As for the Remember Me feature, I figured out that I didn't need half the code I was using - which is always a good thing - making it much simpler to implement and understand. Tomorrow I'm taking the day off in hopes of finishing the Struts chapter. Wish me luck!

Posted in Java at Feb 16 2003, 07:21:25 PM MST 2 Comments