dataFaber 5.0

Cannot find web application MyWebApp in web app registry WebApplicationRegistry

I’m sure it happened to most people, sooner or later. The problem: you’re trying to send an email from a scenario or from a workflow, and the action fails with the following message

**** Error      Thu May 26 18:05:06 CEST 2005   1117123506889
  /atg/epub/workflow/process/WorkflowProcessManager
  Error executing action emailNotifyTaskActors[taskElementId=6,
  scenarioPathInfo=MyWebApp:/notification/notifyToPreviewApproval.jsp,
  recipientSet=permittedActors]
  on process instance 42700003; deleting the process instance
  atg.process.ProcessException: Cannot find web application MyWebApp
  in web app registry WebApplicationRegistry

It seems there’s nothing strange in the scenario or workflow editor, yet the email doesn’t get sent and the log shows the error messages. There are 2 (documented) approaches to solve the problem:

  1. configure MyWebApp in the StaticWebAppRegistry:
    create a MyWebApp/config/atg/registry/webappregistry/MyWebApp.properties file with

    $class=atg.service.webappregistry.WebApp
    properties=\
            display-name=MyWebApp,\
            appState=started,\
            context-root=/mywebapp
    

    and a MyWebApp/config/atg/registry/webappregistry/StaticWebAppRegistry.properties with

    preConfiguredWebApps+=/atg/registry/webappregistry/MyWebApp
    
  2. let NucleusServlet configure MyWebApp in the ServletContextWebAppRegistry:
    add to MyWebApp’s web.xml file a display-name tag and invoke NucleusServlet at the webapp’s startup

    <display-name>MyWebApp</display-name>
    ...
    <servlet>
      <servlet-name>NucleusServlet</servlet-name>
      <display-name>NucleusServlet</display-name>
      <servlet-class>atg.nucleus.servlet.NucleusServlet</servlet-class>
      <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
      <servlet-name>NucleusServlet</servlet-name>
      <url-pattern>/nucleus</url-pattern>
    </servlet-mapping>
    

1 Comment

  1. Will Sargent

    I ran into this one several years ago. It’s a pretty appalling hack to get emails to work.

Comments are closed