Repair CAF Project in Designer ?

Hi,
Can anyone tell me exactly what does the “Repair CAF Project” does in Designer ?

  • Regards

It fixes a variety of common problems that would prevent the project from building in your designer environment.

  • Migrate the project files from previous releases to the current
  • Cleans up the project build classpath to remove obsolete or invalid entries
  • Ensures that the ‘Server Runtime’ associated with the project is a valid one for your workspace
  • Ensures that all the expected project facets are installed and configured correctly
  • Ensures that all the expected JSF component libraries are associated with the project
  • Correct a couple common errors in the WebContent/WEB-INF/faces-config.xml
  • Rewrites some JSF expressions in faces-config.xml and your *.view files to workaround bugs in the JSF reference implementation.

Thanks Eric :slight_smile:

Thats a lot of things…

Though I did not understand the 1st point. How does it “Migrate the project files from previous releases to the current”. Wont that cause problems or code inconsistency ?

Also is there any place where I can get more info about the last 2 points

“Correct a couple common errors in the WebContent/WEB-INF/faces-config.xml”
“Rewrites some JSF expressions in faces-config.xml and your *.view files to workaround bugs in the JSF reference implementation.”

For the 1st point, this is only updating the eclipse project files and the files under .settings which are only used at design time. This was mostly because the first release of CAF was based on version 1 of the eclipse webtools (http://www.eclipse.org/webtools). Subsequent releases of eclipse WTP changed the format of those files, so our repair step migrates those files for you to the newer structure.

  • Oracle’s JSF v1.2 implementation has a bug where it doesn’t like double-quotes in managed-bean property values. The repair task will work-around this bug by rewriting those values using binding-expression syntax: For example: foo"bar"baz -> ${“foo"bar"baz”}
  • If the viewId values in navigation-rules in faces-config.xml do not start with a leading slash, then warnings are logged to the MWS server log file. The repair task will add a leading slash to all those viewId values that are missing it.
  • The JSF 1.2 Expression Language (EL) evaluator currently throws an ELException at runtime trying to parse the : (colon) symbol in ternary expressions if it is immediately followed by an alphabetic character. The repair task does a workaround for this issue by searching for such occurrences in your pages and add whitespace around the : in the ternary expression. For example: #{true ? ‘abc’:‘def’} -> #{true ? ‘abc’ : ‘def’}