blob: ced0ce818e3d2603fed612f5e67b2da700ae5cbd [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more contributor
license agreements. See the NOTICE.txt file distributed with this work for
additional information regarding copyright ownership. The ASF licenses this
file to you 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
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and limitations under
the License.
-->
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd">
<bean class="org.apache.oodt.commons.spring.postprocessor.SetIdBeanPostProcessor" />
<bean class="org.apache.oodt.cas.crawl.util.CasPropertyPlaceholderConfigurer">
<!-- Allow for system-level properties to override all properties below -->
<property name="systemPropertiesMode" value="2" />
<property name="location" value="src/main/resources/examples/Crawler/action-beans.properties" />
</bean>
<!-- DELETE Actions -->
<bean id="DeleteDataFile" lazy-init="true" class="org.apache.oodt.cas.crawl.action.DeleteFile">
<property name="description" value="Deletes the current data file" />
<property name="phases">
<list>
<value type="java.lang.String">postIngestSuccess</value>
</list>
</property>
</bean>
<bean id="DeleteMetadataFile" lazy-init="true" class="org.apache.oodt.cas.crawl.action.DeleteFile">
<property name="description" value="Deletes the metadata file for the current data file" />
<property name="fileExtension" value="${crawler.met.file.ext}" />
<property name="phases">
<list>
<value type="java.lang.String">postIngestSuccess</value>
</list>
</property>
</bean>
<!-- MOVE to FAILURE_DIR Actions -->
<bean id="MoveDataFileToFailureDir" lazy-init="true" class="org.apache.oodt.cas.crawl.action.MoveFile">
<property name="description" value="Moves the current data file to failure directory" />
<property name="toDir" value="${crawler.failure.dir}" />
<property name="createToDir" value="true" />
<property name="phases">
<list>
<value type="java.lang.String">postIngestFailure</value>
</list>
</property>
</bean>
<bean id="MoveMetadataFileToFailureDir" lazy-init="true" class="org.apache.oodt.cas.crawl.action.MoveFile">
<property name="description" value="Moves the metadata file for the current data file to failure directory" />
<property name="fileExtension" value="${crawler.met.file.ext}" />
<property name="toDir" value="${crawler.failure.dir}" />
<property name="createToDir" value="true" />
<property name="phases">
<list>
<value type="java.lang.String">postIngestFailure</value>
</list>
</property>
</bean>
<!-- MOVE to BACKUP_DIR Actions -->
<bean id="MoveMetadataFileToBackupDir" lazy-init="true" class="org.apache.oodt.cas.crawl.action.MoveFile">
<property name="description" value="Moves the metadata file for the current data file to success directory" />
<property name="fileExtension" value="${crawler.met.file.ext}" />
<property name="toDir" value="${crawler.backup.dir}" />
<property name="createToDir" value="true" />
<property name="phases">
<list>
<value type="java.lang.String">postIngestSuccess</value>
</list>
</property>
</bean>
<!-- Workflow Manager Actions -->
<bean id="TriggerPostIngestWorkflow" lazy-init="true" class="org.apache.oodt.cas.crawl.action.WorkflowMgrStatusUpdate">
<property name="description" value="Triggers workflow event with the name [ProductType]Ingest" />
<property name="ingestSuffix" value="Ingest" />
<property name="workflowMgrUrl" value="${crawler.workflowmgr.url}" />
<property name="phases">
<list>
<value type="java.lang.String">postIngestSuccess</value>
</list>
</property>
</bean>
<!-- File Manager Actions -->
<bean id="Unique" lazy-init="true" class="org.apache.oodt.cas.crawl.action.FilemgrUniquenessChecker">
<property name="description" value="Checks the filemgr against the PRODUCT_NAME for the current data file to make sure it has not yet been ingested" />
<property name="filemgrUrl" value="${crawler.filemgr.url}" />
<property name="phases">
<list>
<value type="java.lang.String">preIngest</value>
</list>
</property>
</bean>
</beans>