This section provides FAQs related to the product.
{docbook}
<para xml:id="CONTref.FAQ.HowToDeployWorkflow">
<citetitle>
<emphasis role="bold">
Q1. How to deploy a workflow?
</emphasis>
</citetitle>
</para>
{docbook}

The _addPlugin()_ function of _WorkflowServiceContainer_ service is used to register a Business Process when a workflow is implemented. Thus, if you want to use a workflow, you are required to configure the workflow service to invoke the _addPlugin()_ function by adding the _external-component-plugins_ element to the configuration file.

You have to set values for the name and location of the workflow which you want to use. There are two ways to configure the location of the workflow.

* *Deploy a workflow inside a _.war_ file* {anchor:id=CONTref.FAQ.DeployWorkflowWarFile}

You can use "war:(FOLDER_PATH)" to configure which _.jar_ files contain your workflow processes inside the _.war_ file.
	
{code:xml}<external-component-plugins>
  <target-component>org.exoplatform.services.workflow.WorkflowServiceContainer</target-component>
  <component-plugin>
    <name>deploy.predefined.processes</name>
    <set-method>addPlugin</set-method>
    <type>org.exoplatform.services.workflow.PredefinedProcessesPlugin</type>
    <init-params>
      <object-param>
        <name>predefined.processes</name>
        <description>load of default business processes</description>
        <object type="org.exoplatform.services.workflow.ProcessesConfig">
          <field name="processLocation">
            <string>war:/conf/bp</string>
          </field>
          <field name="predefinedProcess">
            <collection type="java.util.HashSet">
              <value>
                <string>/exo-ecms-ext-workflow-bp-jbpm-content-2.1.1.jar</string>
              </value>
              <value>
                <string>/exo-ecms-ext-workflow-bp-jbpm-payraise-2.1.1.jar</string>
              </value>
              <value>
                <string>/exo-ecms-ext-workflow-bp-jbpm-holiday-2.1.1.jar</string>
              </value>
            </collection>
          </field>
        </object>
      </object-param>
    </init-params>
  </component-plugin>
</external-component-plugins>{code}

* *Deploy a workflow inside a .jar file* {anchor:id=CONTref.FAQ.DeployWorkflowJarFile}


You can use _classpath\:_ to configure which _.jar_ files contain your workflow processes inside the _.jar_ file.
	
{code:xml}<external-component-plugins>
  <target-component>org.exoplatform.services.workflow.WorkflowServiceContainer</target-component>
  <component-plugin>
    <name>deploy.predefined.processes</name>
    <set-method>addPlugin</set-method>
    <type>org.exoplatform.services.workflow.PredefinedProcessesPlugin</type>
    <init-params>
      <object-param>
        <name>predefined.processes</name>
        <description>load of default business processes</description>
        <object type="org.exoplatform.services.workflow.ProcessesConfig">
          <field name="processLocation">
            <string>classpath:</string>
          </field>
          <field name="predefinedProcess">
            <collection type="java.util.HashSet">
              <value>
                <string>/exo-ecms-ext-workflow-bp-jbpm-content-myworkflow.jar</string>
              </value>
            </collection>
          </field>
        </object>
      </object-param>
    </init-params>
  </component-plugin>
</external-component-plugins>{code}
  
The notification message is displayed when you deploy a workflow on Jboss. If you use _classpath\:_ to register, you must put your workflow in the _.jar_ files inside the _gatein.ear/lib_ folder (instead of the _lib_ folder) to make it work.

{docbook}
<para>
<prompt>
<emphasis role="bold">See also</emphasis>
</prompt>
</para>
{docbook}

* [WCM Templates|#CONTref.InsideWCMTemplates]
* [WCM Explorer|#CONTref.InsideWCMExplorer]
* [Extensions|#CONTref.Extensions]
* [CMIS Usage code examples|#Dev_CMIS.Usage_code_examples]
* [Public REST APIs|#CONTref.Devref.PublicRestAPIs]
* [Public Java APIs|#CONTref.JavaServices]
* [Deprecated portlets|#CONTref.Deprecated_portlets]
* [Miscellaneous and Tips|#Adm_CMIS.Miscellaneous_tips]
