See the update page on:

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

MyFaces Developer Notes

This document deals with issues that are important for MyFaces developers and custom component developers.

Component developer guidelines

(same as "SVN guidelines", see below)

SVN guidelines

Code style

See for the Apache-Wide Coding Style Guide. Everything that is not documented there should be written according to Suns Java Code Conventions at

Here is a formatter profile for eclipse 3.1: codeconventions4eclipse.xml. Import it through Window->Preferences->Java->Code Style->Formatter

Here is a formatter profile for IntelliJ IDEA 7.0 (7718): MyFacesIdeaSettings.jar. Import it through File->Import Settings ... This should add a new profile called "MyFaces"

Error and exception handling

Whenever an exception is caught, the following applies:


Except in the JSF API (javax.faces.*) classes where there must be no dependencies to additional libraries, commons-logging is used for logging. Commons-logging should be used in the recommended way, i.e. each class has its own private static logger.


Naming is a fundamental concern. The name of a class, method or field should tell as much as possible of it's meaning and usage. Avoid short names like "Helper", "calc" or "check". Use "FinancialConsultance", "calculateMyYearlyIncome" and "isMyIncomeTooLow" instead.

Special comments

Addition special comments (see 10.5.4 in CodeConv)

Version Control


Every file should start with the following copyright notice:

 * Copyright 2004 The Apache Software Foundation.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * See the License for the specific language governing permissions and
 * limitations under the License.

Class and Interface comment

Every class and interface should have a javadoc similar to this:

 * Very detailed description goes here... ;-)
 * @author Bug Rogers

SVN Settings

Developers should be setting their autoprops so that files have an svn:eol-style of 'native'. Developers working on *nix systems are "lucky" because native on *nix is what SVN calls native, but the autoprops should still be set so that keywords are replaced as well. This is described on the Struts SVN wiki page.

Issue Tracker guidelines

Closing issues

Issues should be marked as closed at the same time that an issue is marked as resolved.

MyFaces_Developer_Notes (last edited 2011-08-23 21:36:55 by LeonardoUribe)