Trouble with Alfresco? Console yourself

Everyone who has spent more than 10 minutes with Alfresco is familiar with Alfresco’s Admin Console. The node browser is an invaluable tool for troubleshooting, but it is conspicuously located as a link on the Admin Console. There are a few other consoles that you can use to help troubleshoot or manage the repository, but you have to know where to look.

What: Workflow Console
Where: http://localhost:8080/alfresco/faces/jsp/admin/workflow-console.jsp
Use: Deploy, un-deploy, and delete workflows. Inspect workflow metadata. Complete a task that’s become stuck for some reason.

What: AVM Console
Where: http://localhost:8080/alfresco/faces/jsp/admin/avm-console.jsp
Use: List stores, create stores, delete stores, create directories and branches, create snapshots, create new nodes. Basically your one-stop shop for working with the AVM Store. If one model is ever chosen over the other, it is likely to be the AVM Store, so this is tool will become even more useful in the future.

2.9 Community adds a couple of new consoles…

What: Repository Admin Console
Where: http://localhost:8080/alfresco/faces/jsp/admin/repoadmin-console.jsp
Use: Deploy, activate, and de-activate content models. If you are using dynamic data models, you’ll need this. See for more details.

What: Web Client Config Console
Where: http://localhost:8080/alfresco/faces/jsp/admin/webclientconfig-console.jsp
Use: Reload the web client configuration. Handy when placing web-client-config-custom.xml in the repository rather on the file system. See for more details.

Consoles are certainly helpful, but log files and debuggers are also essential. Tweak by setting various loggers to “debug” depending on where it is you are having trouble. The file resides in <ALFRESCO WEB ROOT>/WEB-INF/classes. For JavaScript specifically, there’s a Rhino JavaScript Debugger you can enable, but I haven’t found much use for it. In any case, to turn it on, in, change this logger to “on”:

Last, connecting the Eclipse debugger to your running instance of Tomcat is often very helpful. It allows you to step through Alfresco source code to your heart’s content. (Try that with Sharepoint!) There are a few ways to do this, but the way I do it is:

  1. Set an environment variable called JPDA_ADDRESS to 8000 and one called JPDA_TRANSPORT to dt_socket.
  2. Change the last line of Tomcat’s to look like: exec “$PRGDIR”/”$EXECUTABLE” jpda start “$@”
  3. Create and start a new Remote Java Application configuration in the Eclipse Debug dialog.
  4. Set some breakpoints, hit the web client with a web browser and get to stepping.

With the help of the consoles, the logs, and the source, you’ll be successfully hacking Alfresco in no time.

This entry was posted in Alfresco, Content Management and tagged . Bookmark the permalink.