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.
You searched this site for "jsf". 312 entries found.

You can also try this same search on Google.

Java Server Faces Resources

James Holmes has put together an impressive list of JSF resources. Very cool - thanks James! Now the question is, when do you start developing your apps in JSF vs. JSP? When do you start developing your apps in JSP 2.0? Obviously, when the J2EE 1.4 spec if finalized and Tomcat 5 comes out - right?! Well then, giddyup - I'm ready!!

Posted in Java at Jun 03 2003, 02:43:29 PM MDT Add a Comment

Good JavaServer Faces Article

The latest issue of Java Developers Journal has an excellent article on developing with JavaServer Faces. I read it on the plane last week and thoroughly enjoyed it. I like it so much, that if I had my laptop with me, I probably wouldn't tried porting one of my sample apps to use JSF.

However, the magazine I had did not have any code samples in it - even though it referred to Figure 1, Figure 2, etc. So naturally, I was excited to see the online version and the downloadable source code. I might be a little ignorant (being from Montana and all ;-), but this download does nothing for me. It's a 3K zip file with one file in it - that has no extension. If I view it with Notepad, I get some text, but lots of garbage too. This would be a much better article if it included a simple WAR file. An example app that cannot be downloaded and run (or built and then run) is worth nothing to me.

Posted in Java at May 29 2003, 08:35:01 AM MDT Add a Comment

JSP Plugin for Eclipse?

Does anyone know of a good JSP Plugin for Eclipse? I've found that the available XML and JSP Editors are not very good, and I resort to HomeSite (which I love) for most of my regular text editing. I'd love to find a tool that does code completion for JSPs. I suppose I could use Dreamweaver, but they don't have a copy here in the office. BTW, I found the Lomboz plugin, but it doesn't appear to be latest-eclipse-release compliant.

Posted in Java at Mar 12 2003, 01:28:39 PM MST 17 Comments

Struts-JSF Demo

I've setup another demo - this time it's the struts-example app ported to use JSF and Struts. Nothing ground breaking here that I can tell, and after looking at the code, I don't know what to think of JSF. It seems to make it much harder to code a JSP page.

<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
<%@ taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
<%@ taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
<%@ taglib prefix="s" uri="http://jakarta.apache.org/struts/tags-faces" %>

<f:use_faces>
<s:html locale="true">
<head>
  <title><
    <s:message key="registration.title.edit"/>
    </title>
  <s:base/>
  <s:stylesheet path="/stylesheet.css"/>
</head>
<body bgcolor="white">

<s:errors/>

<s:form action="/saveRegistration" focus="username"
         onsubmit="return validateRegistrationForm(this);">

  <h:input_hidden id="action" modelReference="registrationForm.action"/>

  <h:panel_grid
           columns="2"
        panelClass="form-background"
       headerClass="form-header"
     columnClasses="form-prompt,form-field">
.
.
.

Ugh, a whole new set of Tag Libraries to learn? Seems like JSF is a lot of bloat, while JSP 2.0 has been made things simpler. One interesting thing is the use of the single-letter (i.e. "h", "s") for the tag libraries. I suggested this a while ago on the struts-dev list, and it looks like it's been implemented. Bravo! I doubt I'm the reason for it, but it's always nice to see your ideas implemented.

I apologize that this site was down most of the day today. It seems that the monitoring/restarting scripts were not running and this should/will be fixed shortly. I need a gig where I can restart this site when it goes down. Anyone know of a way to telnet/ssh via an HTTP Proxy?

Posted in Java at Mar 07 2003, 03:38:29 PM MST 1 Comment

Struts and JSF - Sample app is on its way!

Craig McClanahan just sent the following message to the struts-dev mailing list after creating a new struts-faces directory (and sub-directories in Struts' CVS tree.

Yep ... it's here ... the promised integration library that lets you use the recently published EA3 release of JavaServer Faces with a recent Struts 1.1 build (see the README.txt for details). Unfortunately, the CVS commit for the actual code was too big for the mailing list -- essentially, it's all the files in the "contrib/struts-faces" subdirectory.

My plan is to publish nightly builds of this code (it's EA quality) but *not* to incorporate it into any formal 1.1 release. More info in an announcement message to come shortly.

Craig

You and I both know the best way to learn JSF (and JSP 2.0) is to start using it on a project. Whether it's your own, an open source project, or a paid project - it's truly the fastest way to enlightenment. I was lucky in my quest to learn Hibernate - I had two concurrent projects (struts-resume and paid) using it.

As far as computers are concerned, I've had a pretty bad day. After writing a long e-mail (about as long as this post), I kicked back in my chair to hit send and kicked the power cord out of the socket! Doh! This actually happens about once a day, but usually I'm coding and testing and I'm saving every 30 seconds. Secondly, I had this post all written and formatted about 10 minutes ago, and Phoenix crashed when I switched tabs to copy/paste something. Damn thing - it's been crashing a lot lately. It might be time to revert back to IE (am now) or Mozilla.

Posted in Java at Mar 06 2003, 08:53:38 PM MST Add a Comment

Java Server Faces Demos!

Dave points out that there's a new Java Server Faces spec available.

The Server Side also reports that Sun has released Java Server Faces (JSF) Early Access 3, a tutorial, and a public draft of the JSF spec.

If you're like me, you just care about the code and how it looks. So I've taken the five war's that are distributed with this release and installed them on this site. If I get too many OutOfMemory errors, I'll remove them - but hopefully they can stay up for a day or two.

Posted in Java at Mar 05 2003, 10:28:34 PM MST Add a Comment

RE: Who reads them anyways....

Laurent Michalkovic has an interesting post on the fact that no one reads the specs. I read them two years ago, that's right - in December of 2001. I read all of the ones that that interested me at the time: JSP 1.2, Servlet 2.4, J2EE 1.3 and EJB 2.0. I downloaded them all and printed them out and read them. It was boring and cost me around $150 just in printer cartridges. They had good information, they're just dry. Luckily, I was very motivated to read them. I was studying for the Web Component Developer exam from Sun, so the JSP 1.2 and Servlet 2.4 specs were essential reading. I read J2EE 1.3 and EJB 2.0 shortly thereafter while studying to become a BEA Certified Developer. Interesting thing about the BEA exam, I ended up concentrating on WebLogic-specific stuff to pass the exam. Not much on standards, mostly questions on server configuration, clustering, etc.

I've skimmed through the latest ones, but I haven't read them page-by-page cover-to-cover. Besides, the mere size of each will scare you off:

  • Servlet 2.4: 309 pages
  • JSP 2.0: 458 pages
  • J2EE 1.4: 242 pages
  • JSTL 1.0: 219 pages
  • JSF 1.0 EA: 117 pages

That's a heckuva lot of reading. When studying for these certifications, I also picked up Professional Java Server Programming J2EE, 1.3 Edition by Wrox. I actually thought this was a great book and I learned a lot more from it than I did from reading the specs.

Interestingly enough (or maybe not at all), I also bought (and read) J2EE Applications and BEA WebLogic Server. However, the BEA Documentation site turned out to be a better resource than that book!

Posted in Java at Feb 15 2003, 11:14:08 PM MST Add a Comment

Integrating JSP/JSF and XML/XSLT: The Best of Both Worlds

I saw this nugget a few minutes ago on the struts-user mailing list. Maybe I'll even read it... ;-)

For those of you wondering how JSP technologies, including JSP 2.0, JSTL, Struts and the upcoming JavaServer Faces (JSF) 1.0, can work together with XML and XSLT, there is a new article at TheServerSide.com about this subject.

http://www.theserverside.com/resources/article.jsp?l=BestBothWorlds

The article presents the natural evolution of server-side Java programming from basic servlet programming to JSP 2.0 with JSTL and JSF, shows the limitations of the current JSF rendering architecture and how XML technologies can solve them.

The article comes with sample code that shows how to hookup an XSLT transformer with a JSP filter, and includes an experimental XML renderer for JSF.

Posted in Java at Feb 12 2003, 12:40:53 PM MST 1 Comment

JSP 2.0 and Servlets 2.4 Research

I'm going to record a few items from my JSP 2.0 and Servlet 2.4 research tonight. I hope you don't mind.

From JSR 152 (JSP 2.0):

We plan to incorporate two main new features into JSP, and a few incremental features. Additionally we expect to incorporate erratas and clarifications as well as opportunistic improvements.

The two key features are the use of JSP to author custom actions, and adding expression language support into the container. The main goal of this JSR is to deliver these new features into the JSP specification in a timely manner. This goal will likely limit what other features can be incorporated.

So (to me) this means that if you know JSTL, you already know half of JSP 2.0. And the best part of JSP 2.0? One main theme of this update of the JSP specification is that we want to simplify, not complicate, the view of a JSP that most users, specially page authors, have.

From JSR 154 (Servlet 2.4):

Servlet 2.4 will be a relatively small upgrade to the existing API. Since the technology is highly popular, we have a large number of small requests for enhancement to the API that we would like to be able to accommodate. Over and above that, Servlet 2.4 will address the following areas in a portable manner:-

* Modularization of the deployment format

The goal is to achieve a level of modularity with the deployment format which is not currently possible using the current DTD based deployment descriptor. The intent is to enable this modularity to manage the organization of deployment information of related technologies that use the web container as the underlying platform. These frameworks include dependencies on other J2EE components, JSP technology, JavaServer Faces, JAXM, JAX-RPC and other frameworks that build on servlet semantics.

Hmmm, this almost sounds like the module idea in Struts. Does this mean they want to allow sub-applications (or modules) within a web application? After a little research, it appears that the 2.4 spec will allow you to add new namespaces to your web.xml file, and therefore, you can extend the deployment descriptor for your own needs. Look for vendors to use this, as well as UI Frameworks like JSF. The top of your web.xml will resemble the following on 2.4 container:

<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://
    java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4">

Also on the list:

* Enhancements to the security model
     - Provide a facility for logging out of web applications portably
     - Clarify, possibly by adding API or deployment syntax, the relationship between HTTP session state and authentication state

* Smallish enhancements to the filter and listener models
     - Provision of deployment syntax for declaring API dependencies between elements in a filter chain
     - Addition of request and response level listeners and event notifications.

Cool, sounds like good stuff. Logging out of web applications portably? You mean there's more we can do than invalidate the session? I wonder what else there is to logging out? Maybe it'll remember the last page the user was on? No such luck (but you can do that with Cookies). It appears that there's a strong effort to encourage vendors to implement single sign-on for webapps. Tomcat is the only one I know that does this now. HttpSession has a new logout method - if the servlet container implements single signon, the logout logs the client out of all web applications on the servlet container and invalidates all sessions associated with the same client. I guess this is cool if you have more than one webapp on your server. Now we just need an API to allow webapps to talk to each other on the same container. I guess you could call this HTTP, but I want something better than that. Another interesting item I found is that you'll be able to use a servlet as your welcome-file, which is currently not allowed in the 2.3 spec.

So how do these new specs influence how you write your webapps? It doesn't seem like there's much that's new, and certainly no ground-breaking features. So learn Struts, so you'll have a headstart on JSF, and learn JSTL, so you'll know the expression language used in JSP 2.0. If you've been put off by writing tag libraries, it'll be easier with JSP 2.0, as you'll be able to use JSP fragments as a type of tag library. Lastly, if you're not using container-managed authentication (i.e. BASIC, FORM), you might want to consider it. The thing I like most about container-managed authentication is that you can bookmark pages in an app, and then get right back to them by entering a login/password - this is how it should be vs. login -> main menu -> bookmarked page. You can use filters to restore any session or request information that is needed for the bookmarked page.

Pheww, boy am I lucky! I copy-pasted this post before I tried to submit it, and whaddya know, Chimera crashed after I hit the "Post to Weblog" button!

Posted in Java at Nov 29 2002, 07:09:23 PM MST 4 Comments

JSF Chat now at 11:00 a.m. MDT tomorrow.

It looks like they decided 6:00 AM was too early for me - now at 11:00 AM PDT - that's 12:00 noon for you mountain timers.

Posted in Java at Oct 07 2002, 05:15:14 PM MDT Add a Comment