Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'test-apps/quartz-scheduler')
-rw-r--r--test-apps/quartz-scheduler/README.TXT21
-rw-r--r--test-apps/quartz-scheduler/build.properties7
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/.classpath14
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/.project17
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/build.xml9
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/ivy.xml31
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/Service.java28
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/internal/StandardService.java47
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/MANIFEST.MF7
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/module-context.xml28
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/osgi-context.xml12
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/.classpath14
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/.project17
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/build.xml9
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/ivy.xml31
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/Service.java28
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/internal/StandardService.java47
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/MANIFEST.MF7
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/module-context.xml28
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/osgi-context.xml12
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/.classpath14
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/.project15
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/build.xml9
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/ivy.xml31
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/Service.java28
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/internal/StandardService.java47
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/MANIFEST.MF7
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/module-context.xml27
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/osgi-context.xml12
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/.classpath14
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/.project15
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/build.xml9
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/ivy.xml31
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/Service.java28
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/internal/StandardService.java47
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/MANIFEST.MF7
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/module-context.xml27
-rw-r--r--test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/osgi-context.xml12
38 files changed, 794 insertions, 0 deletions
diff --git a/test-apps/quartz-scheduler/README.TXT b/test-apps/quartz-scheduler/README.TXT
new file mode 100644
index 00000000..f303c824
--- /dev/null
+++ b/test-apps/quartz-scheduler/README.TXT
@@ -0,0 +1,21 @@
+How to build
+------------
+
+1. Run ant jar in quartz.bundle.a
+ or
+2. Run ant jar in quartz.bundle.b
+ or
+3. Run ant jar in quartz.bundle.same1
+ or
+4. Run ant jar in quartz.bundle.same2
+
+Output
+------
+
+1. com.springsource.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.a.jar
+ or
+2. com.springsource.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.b.jar
+ or
+3. com.springsource.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.same1.jar
+ or
+4. com.springsource.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.same2.jar \ No newline at end of file
diff --git a/test-apps/quartz-scheduler/build.properties b/test-apps/quartz-scheduler/build.properties
new file mode 100644
index 00000000..17e34032
--- /dev/null
+++ b/test-apps/quartz-scheduler/build.properties
@@ -0,0 +1,7 @@
+version=1.0.0
+release.type=integration
+bucket.basename=springsource.com
+ivy.cache.dir=${basedir}/../../ivy-cache
+integration.repo.dir=${basedir}/../../integration-repo
+disable.bundlor=true
+ivy.settings.file=${basedir}/../../../ivysettings.xml
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/.classpath b/test-apps/quartz-scheduler/quartz.bundle.a/.classpath
new file mode 100644
index 00000000..399b6f9a
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/.classpath
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src/main/java"/>
+ <classpathentry kind="src" path="src/main/resources"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-1.6.0.jar" sourcepath="/KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-sources-1.6.0.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-3.5.1.R35x_v20091005.jar" sourcepath="/KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-sources-3.5.1.R35x_v20091005.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-1.2.1.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-sources-1.2.1.jar"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/.project b/test-apps/quartz-scheduler/quartz.bundle.a/.project
new file mode 100644
index 00000000..da9e5f64
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/.project
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>quartz.bundle.a</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/build.xml b/test-apps/quartz-scheduler/quartz.bundle.a/build.xml
new file mode 100644
index 00000000..5014ff7a
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/build.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="quartz.bundle.a">
+
+ <property file="${basedir}/../build.properties"/>
+ <property file="${basedir}/../../../build.versions"/>
+ <property name="jar.output.file" value="${basedir}/../../../org.eclipse.virgo.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.a.jar"/>
+ <import file="${basedir}/../../../spring-build/standard/default.xml"/>
+
+</project>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/ivy.xml b/test-apps/quartz-scheduler/quartz.bundle.a/ivy.xml
new file mode 100644
index 00000000..9f19ac47
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/ivy.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?xml-stylesheet type="text/xsl" href="http://ivyrep.jayasoft.org/ivy-doc.xsl"?>
+<ivy-module
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://incubator.apache.org/ivy/schemas/ivy.xsd"
+ version="1.3">
+
+ <info organisation="org.eclipse.virgo.server.test" module="${ant.project.name}">
+ <ivyauthor name="sbrannen"/>
+ </info>
+
+ <configurations>
+ <include file="${virgo.build.dir}/common/default-ivy-configurations.xml"/>
+ </configurations>
+
+ <publications>
+ </publications>
+
+ <dependencies>
+ <dependency org="com.opensymphony.quartz" name="com.springsource.org.quartz" rev="${com.opensymphony.quartz}" conf="provided->compile"/>
+ <dependency org="org.eclipse.osgi" name="org.eclipse.osgi" rev="${org.eclipse.osgi}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.beans" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context.support" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.core" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework.osgi" name="org.springframework.osgi.core" rev="${org.springframework.osgi}" conf="provided->compile"/>
+
+ <override org="org.springframework" rev="${org.springframework}"/>
+ </dependencies>
+
+</ivy-module>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/Service.java b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/Service.java
new file mode 100644
index 00000000..5ac6b33b
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/Service.java
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.a;
+
+import org.quartz.Scheduler;
+
+/**
+ * Simple test service to serve as a scheduled job.
+ *
+ */
+public interface Service {
+
+ int getCount();
+
+ Scheduler getScheduler();
+
+ void process();
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/internal/StandardService.java b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/internal/StandardService.java
new file mode 100644
index 00000000..c438287e
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/java/quartz/bundle/a/internal/StandardService.java
@@ -0,0 +1,47 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.a.internal;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+import org.quartz.Scheduler;
+import org.springframework.beans.BeansException;
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.ApplicationContextAware;
+
+import quartz.bundle.a.Service;
+
+/**
+ */
+public class StandardService implements Service, ApplicationContextAware {
+
+ private final AtomicInteger count = new AtomicInteger(0);
+
+ private ApplicationContext applicationContext;
+
+ public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
+ this.applicationContext = applicationContext;
+ }
+
+ public int getCount() {
+ return this.count.get();
+ }
+
+ public Scheduler getScheduler() {
+ return (Scheduler) this.applicationContext.getBean("schedulerFactoryBean");
+ }
+
+ public void process() {
+ System.err.println(getClass().getName() + " called " + this.count.incrementAndGet() + " times.");
+ }
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/MANIFEST.MF b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/MANIFEST.MF
new file mode 100644
index 00000000..88ab6bf7
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/MANIFEST.MF
@@ -0,0 +1,7 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-SymbolicName: quartz.bundle.a
+Bundle-Version: 1.0.0
+Import-Bundle: com.springsource.org.quartz;version="[1.6.0,1.6.0]"
+Import-Library: org.springframework.spring;version="[2.5.5,3.1.0)"
+Export-Package: quartz.bundle.a
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/module-context.xml b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/module-context.xml
new file mode 100644
index 00000000..2dcfaca0
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/module-context.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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 id="simpleTrigger" class="org.springframework.scheduling.quartz.SimpleTriggerBean">
+ <property name="jobDetail" ref="jobDetail" />
+ <property name="startDelay" value="500" />
+ <property name="repeatInterval" value="1000" />
+ </bean>
+ <bean id="jobDetail"
+ class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
+ <property name="targetObject" ref="service" />
+ <property name="targetMethod" value="process" />
+ <property name="concurrent" value="false" />
+ </bean>
+ <bean id="schedulerFactoryBean"
+ class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
+ <property name="schedulerName" value="QuartzScheduler-A" />
+ <property name="triggers">
+ <list>
+ <ref bean="simpleTrigger" />
+ </list>
+ </property>
+ </bean>
+ <bean id="service" class="quartz.bundle.a.internal.StandardService" />
+</beans>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/osgi-context.xml b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/osgi-context.xml
new file mode 100644
index 00000000..d78e2bdf
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.a/src/main/resources/META-INF/spring/osgi-context.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<beans:beans xmlns="http://www.springframework.org/schema/osgi"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
+ xsi:schemaLocation="
+ http://www.springframework.org/schema/beans
+ http://www.springframework.org/schema/beans/spring-beans.xsd
+ http://www.springframework.org/schema/osgi
+ http://www.springframework.org/schema/osgi/spring-osgi.xsd">
+
+ <service ref="service" interface="quartz.bundle.a.Service" />
+
+</beans:beans>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/.classpath b/test-apps/quartz-scheduler/quartz.bundle.b/.classpath
new file mode 100644
index 00000000..399b6f9a
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/.classpath
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src/main/java"/>
+ <classpathentry kind="src" path="src/main/resources"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-1.6.0.jar" sourcepath="/KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-sources-1.6.0.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-3.5.1.R35x_v20091005.jar" sourcepath="/KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-sources-3.5.1.R35x_v20091005.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-1.2.1.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-sources-1.2.1.jar"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/.project b/test-apps/quartz-scheduler/quartz.bundle.b/.project
new file mode 100644
index 00000000..4abff2de
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/.project
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>quartz.bundle.b</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/build.xml b/test-apps/quartz-scheduler/quartz.bundle.b/build.xml
new file mode 100644
index 00000000..19011026
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/build.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="quartz.bundle.b">
+
+ <property file="${basedir}/../build.properties"/>
+ <property file="${basedir}/../../../build.versions"/>
+ <property name="jar.output.file" value="${basedir}/../../../org.eclipse.virgo.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.b.jar"/>
+ <import file="${basedir}/../../../spring-build/standard/default.xml"/>
+
+</project>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/ivy.xml b/test-apps/quartz-scheduler/quartz.bundle.b/ivy.xml
new file mode 100644
index 00000000..9f19ac47
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/ivy.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?xml-stylesheet type="text/xsl" href="http://ivyrep.jayasoft.org/ivy-doc.xsl"?>
+<ivy-module
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://incubator.apache.org/ivy/schemas/ivy.xsd"
+ version="1.3">
+
+ <info organisation="org.eclipse.virgo.server.test" module="${ant.project.name}">
+ <ivyauthor name="sbrannen"/>
+ </info>
+
+ <configurations>
+ <include file="${virgo.build.dir}/common/default-ivy-configurations.xml"/>
+ </configurations>
+
+ <publications>
+ </publications>
+
+ <dependencies>
+ <dependency org="com.opensymphony.quartz" name="com.springsource.org.quartz" rev="${com.opensymphony.quartz}" conf="provided->compile"/>
+ <dependency org="org.eclipse.osgi" name="org.eclipse.osgi" rev="${org.eclipse.osgi}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.beans" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context.support" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.core" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework.osgi" name="org.springframework.osgi.core" rev="${org.springframework.osgi}" conf="provided->compile"/>
+
+ <override org="org.springframework" rev="${org.springframework}"/>
+ </dependencies>
+
+</ivy-module>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/Service.java b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/Service.java
new file mode 100644
index 00000000..aed25551
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/Service.java
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.b;
+
+import org.quartz.Scheduler;
+
+/**
+ * Simple test service to serve as a scheduled job.
+ *
+ */
+public interface Service {
+
+ int getCount();
+
+ Scheduler getScheduler();
+
+ void process();
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/internal/StandardService.java b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/internal/StandardService.java
new file mode 100644
index 00000000..707d068f
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/java/quartz/bundle/b/internal/StandardService.java
@@ -0,0 +1,47 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.b.internal;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+import org.quartz.Scheduler;
+import org.springframework.beans.BeansException;
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.ApplicationContextAware;
+
+import quartz.bundle.b.Service;
+
+/**
+ */
+public class StandardService implements Service, ApplicationContextAware {
+
+ private final AtomicInteger count = new AtomicInteger(0);
+
+ private ApplicationContext applicationContext;
+
+ public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
+ this.applicationContext = applicationContext;
+ }
+
+ public int getCount() {
+ return this.count.get();
+ }
+
+ public Scheduler getScheduler() {
+ return (Scheduler) this.applicationContext.getBean("schedulerFactoryBean");
+ }
+
+ public void process() {
+ System.err.println(getClass().getName() + " called " + this.count.incrementAndGet() + " times.");
+ }
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/MANIFEST.MF b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/MANIFEST.MF
new file mode 100644
index 00000000..8c8c16ea
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/MANIFEST.MF
@@ -0,0 +1,7 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-SymbolicName: quartz.bundle.b
+Bundle-Version: 1.0.0
+Import-Bundle: com.springsource.org.quartz;version="[1.6.0,1.6.0]"
+Import-Library: org.springframework.spring;version="[2.5.5,3.1.0)"
+Export-Package: quartz.bundle.b
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/module-context.xml b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/module-context.xml
new file mode 100644
index 00000000..d0889341
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/module-context.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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 id="simpleTrigger" class="org.springframework.scheduling.quartz.SimpleTriggerBean">
+ <property name="jobDetail" ref="jobDetail" />
+ <property name="startDelay" value="500" />
+ <property name="repeatInterval" value="1000" />
+ </bean>
+ <bean id="jobDetail"
+ class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
+ <property name="targetObject" ref="service" />
+ <property name="targetMethod" value="process" />
+ <property name="concurrent" value="false" />
+ </bean>
+ <bean id="schedulerFactoryBean"
+ class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
+ <property name="schedulerName" value="QuartzScheduler-B" />
+ <property name="triggers">
+ <list>
+ <ref bean="simpleTrigger" />
+ </list>
+ </property>
+ </bean>
+ <bean id="service" class="quartz.bundle.b.internal.StandardService" />
+</beans>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/osgi-context.xml b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/osgi-context.xml
new file mode 100644
index 00000000..f8f283bb
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.b/src/main/resources/META-INF/spring/osgi-context.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<beans:beans xmlns="http://www.springframework.org/schema/osgi"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
+ xsi:schemaLocation="
+ http://www.springframework.org/schema/beans
+ http://www.springframework.org/schema/beans/spring-beans.xsd
+ http://www.springframework.org/schema/osgi
+ http://www.springframework.org/schema/osgi/spring-osgi.xsd">
+
+ <service ref="service" interface="quartz.bundle.b.Service" />
+
+</beans:beans>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/.classpath b/test-apps/quartz-scheduler/quartz.bundle.same1/.classpath
new file mode 100644
index 00000000..399b6f9a
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/.classpath
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src/main/java"/>
+ <classpathentry kind="src" path="src/main/resources"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-1.6.0.jar" sourcepath="/KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-sources-1.6.0.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-3.5.1.R35x_v20091005.jar" sourcepath="/KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-sources-3.5.1.R35x_v20091005.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-1.2.1.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-sources-1.2.1.jar"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/.project b/test-apps/quartz-scheduler/quartz.bundle.same1/.project
new file mode 100644
index 00000000..7a78f0b1
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/.project
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>quartz.bundle.same1</name>
+ <comment></comment>
+ <projects></projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments></arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/build.xml b/test-apps/quartz-scheduler/quartz.bundle.same1/build.xml
new file mode 100644
index 00000000..8cf604b8
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/build.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="quartz.bundle.same1">
+
+ <property file="${basedir}/../build.properties"/>
+ <property file="${basedir}/../../../build.versions"/>
+ <property name="jar.output.file" value="${basedir}/../../../org.eclipse.virgo.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.same1.jar"/>
+ <import file="${basedir}/../../../spring-build/standard/default.xml"/>
+
+</project>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/ivy.xml b/test-apps/quartz-scheduler/quartz.bundle.same1/ivy.xml
new file mode 100644
index 00000000..9f19ac47
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/ivy.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?xml-stylesheet type="text/xsl" href="http://ivyrep.jayasoft.org/ivy-doc.xsl"?>
+<ivy-module
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://incubator.apache.org/ivy/schemas/ivy.xsd"
+ version="1.3">
+
+ <info organisation="org.eclipse.virgo.server.test" module="${ant.project.name}">
+ <ivyauthor name="sbrannen"/>
+ </info>
+
+ <configurations>
+ <include file="${virgo.build.dir}/common/default-ivy-configurations.xml"/>
+ </configurations>
+
+ <publications>
+ </publications>
+
+ <dependencies>
+ <dependency org="com.opensymphony.quartz" name="com.springsource.org.quartz" rev="${com.opensymphony.quartz}" conf="provided->compile"/>
+ <dependency org="org.eclipse.osgi" name="org.eclipse.osgi" rev="${org.eclipse.osgi}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.beans" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context.support" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.core" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework.osgi" name="org.springframework.osgi.core" rev="${org.springframework.osgi}" conf="provided->compile"/>
+
+ <override org="org.springframework" rev="${org.springframework}"/>
+ </dependencies>
+
+</ivy-module>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/Service.java b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/Service.java
new file mode 100644
index 00000000..66f43b52
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/Service.java
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.same1;
+
+import org.quartz.Scheduler;
+
+/**
+ * Simple test service to serve as a scheduled job.
+ *
+ */
+public interface Service {
+
+ int getCount();
+
+ Scheduler getScheduler();
+
+ void process();
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/internal/StandardService.java b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/internal/StandardService.java
new file mode 100644
index 00000000..36db66ab
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/java/quartz/bundle/same1/internal/StandardService.java
@@ -0,0 +1,47 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.same1.internal;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+import org.quartz.Scheduler;
+import org.springframework.beans.BeansException;
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.ApplicationContextAware;
+
+import quartz.bundle.same1.Service;
+
+/**
+ */
+public class StandardService implements Service, ApplicationContextAware {
+
+ private final AtomicInteger count = new AtomicInteger(0);
+
+ private ApplicationContext applicationContext;
+
+ public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
+ this.applicationContext = applicationContext;
+ }
+
+ public int getCount() {
+ return this.count.get();
+ }
+
+ public Scheduler getScheduler() {
+ return (Scheduler) this.applicationContext.getBean("schedulerFactoryBean");
+ }
+
+ public void process() {
+ System.err.println(getClass().getName() + " called " + this.count.incrementAndGet() + " times.");
+ }
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/MANIFEST.MF b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/MANIFEST.MF
new file mode 100644
index 00000000..a7f5d990
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/MANIFEST.MF
@@ -0,0 +1,7 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-SymbolicName: quartz.bundle.same1
+Bundle-Version: 1.0.0
+Import-Bundle: com.springsource.org.quartz;version="[1.6.0,1.6.0]"
+Import-Library: org.springframework.spring;version="[2.5.5,3.1.0)"
+Export-Package: quartz.bundle.same1
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/module-context.xml b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/module-context.xml
new file mode 100644
index 00000000..635e5718
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/module-context.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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 id="simpleTrigger" class="org.springframework.scheduling.quartz.SimpleTriggerBean">
+ <property name="jobDetail" ref="jobDetail" />
+ <property name="startDelay" value="500" />
+ <property name="repeatInterval" value="1000" />
+ </bean>
+ <bean id="jobDetail"
+ class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
+ <property name="targetObject" ref="service" />
+ <property name="targetMethod" value="process" />
+ <property name="concurrent" value="false" />
+ </bean>
+ <bean id="schedulerFactoryBean"
+ class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
+ <property name="triggers">
+ <list>
+ <ref bean="simpleTrigger" />
+ </list>
+ </property>
+ </bean>
+ <bean id="service" class="quartz.bundle.same1.internal.StandardService" />
+</beans>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/osgi-context.xml b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/osgi-context.xml
new file mode 100644
index 00000000..0b42dcbf
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same1/src/main/resources/META-INF/spring/osgi-context.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<beans:beans xmlns="http://www.springframework.org/schema/osgi"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
+ xsi:schemaLocation="
+ http://www.springframework.org/schema/beans
+ http://www.springframework.org/schema/beans/spring-beans.xsd
+ http://www.springframework.org/schema/osgi
+ http://www.springframework.org/schema/osgi/spring-osgi.xsd">
+
+ <service ref="service" interface="quartz.bundle.same1.Service" />
+
+</beans:beans>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/.classpath b/test-apps/quartz-scheduler/quartz.bundle.same2/.classpath
new file mode 100644
index 00000000..399b6f9a
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/.classpath
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src/main/java"/>
+ <classpathentry kind="src" path="src/main/resources"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-1.6.0.jar" sourcepath="/KERNEL_IVY_CACHE/com.opensymphony.quartz/com.springsource.org.quartz/1.6.0/com.springsource.org.quartz-sources-1.6.0.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-3.5.1.R35x_v20091005.jar" sourcepath="/KERNEL_IVY_CACHE/org.eclipse.osgi/org.eclipse.osgi/3.5.1.R35x_v20091005/org.eclipse.osgi-sources-3.5.1.R35x_v20091005.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.beans/3.0.0.RELEASE/org.springframework.beans-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context/3.0.0.RELEASE/org.springframework.context-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.context.support/3.0.0.RELEASE/org.springframework.context.support-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-3.0.0.RELEASE.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework/org.springframework.core/3.0.0.RELEASE/org.springframework.core-sources-3.0.0.RELEASE.jar"/>
+ <classpathentry kind="var" path="KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-1.2.1.jar" sourcepath="/KERNEL_IVY_CACHE/org.springframework.osgi/org.springframework.osgi.core/1.2.1/org.springframework.osgi.core-sources-1.2.1.jar"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/.project b/test-apps/quartz-scheduler/quartz.bundle.same2/.project
new file mode 100644
index 00000000..c0a767dc
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/.project
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>quartz.bundle.same2</name>
+ <comment></comment>
+ <projects></projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments></arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/build.xml b/test-apps/quartz-scheduler/quartz.bundle.same2/build.xml
new file mode 100644
index 00000000..d87cd82e
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/build.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="quartz.bundle.same2">
+
+ <property file="${basedir}/../build.properties"/>
+ <property file="${basedir}/../../../build.versions"/>
+ <property name="jar.output.file" value="${basedir}/../../../org.eclipse.virgo.kernel.deployer.test/src/test/resources/quartz/quartz.bundle.same2.jar"/>
+ <import file="${basedir}/../../../spring-build/standard/default.xml"/>
+
+</project>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/ivy.xml b/test-apps/quartz-scheduler/quartz.bundle.same2/ivy.xml
new file mode 100644
index 00000000..9f19ac47
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/ivy.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?xml-stylesheet type="text/xsl" href="http://ivyrep.jayasoft.org/ivy-doc.xsl"?>
+<ivy-module
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://incubator.apache.org/ivy/schemas/ivy.xsd"
+ version="1.3">
+
+ <info organisation="org.eclipse.virgo.server.test" module="${ant.project.name}">
+ <ivyauthor name="sbrannen"/>
+ </info>
+
+ <configurations>
+ <include file="${virgo.build.dir}/common/default-ivy-configurations.xml"/>
+ </configurations>
+
+ <publications>
+ </publications>
+
+ <dependencies>
+ <dependency org="com.opensymphony.quartz" name="com.springsource.org.quartz" rev="${com.opensymphony.quartz}" conf="provided->compile"/>
+ <dependency org="org.eclipse.osgi" name="org.eclipse.osgi" rev="${org.eclipse.osgi}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.beans" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.context.support" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework" name="org.springframework.core" rev="${org.springframework}" conf="provided->compile"/>
+ <dependency org="org.springframework.osgi" name="org.springframework.osgi.core" rev="${org.springframework.osgi}" conf="provided->compile"/>
+
+ <override org="org.springframework" rev="${org.springframework}"/>
+ </dependencies>
+
+</ivy-module>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/Service.java b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/Service.java
new file mode 100644
index 00000000..1e357096
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/Service.java
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.same2;
+
+import org.quartz.Scheduler;
+
+/**
+ * Simple test service to serve as a scheduled job.
+ *
+ */
+public interface Service {
+
+ int getCount();
+
+ Scheduler getScheduler();
+
+ void process();
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/internal/StandardService.java b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/internal/StandardService.java
new file mode 100644
index 00000000..c848cde3
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/java/quartz/bundle/same2/internal/StandardService.java
@@ -0,0 +1,47 @@
+/*******************************************************************************
+ * Copyright (c) 2008, 2010 VMware Inc.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * VMware Inc. - initial contribution
+ *******************************************************************************/
+
+package quartz.bundle.same2.internal;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+import org.quartz.Scheduler;
+import org.springframework.beans.BeansException;
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.ApplicationContextAware;
+
+import quartz.bundle.same2.Service;
+
+/**
+ */
+public class StandardService implements Service, ApplicationContextAware {
+
+ private final AtomicInteger count = new AtomicInteger(0);
+
+ private ApplicationContext applicationContext;
+
+ public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
+ this.applicationContext = applicationContext;
+ }
+
+ public int getCount() {
+ return this.count.get();
+ }
+
+ public Scheduler getScheduler() {
+ return (Scheduler) this.applicationContext.getBean("schedulerFactoryBean");
+ }
+
+ public void process() {
+ System.err.println(getClass().getName() + " called " + this.count.incrementAndGet() + " times.");
+ }
+
+}
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/MANIFEST.MF b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/MANIFEST.MF
new file mode 100644
index 00000000..fbca1d02
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/MANIFEST.MF
@@ -0,0 +1,7 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-SymbolicName: quartz.bundle.same2
+Bundle-Version: 1.0.0
+Import-Bundle: com.springsource.org.quartz;version="[1.6.0,1.6.0]"
+Import-Library: org.springframework.spring;version="[2.5.5,3.1.0)"
+Export-Package: quartz.bundle.same2
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/module-context.xml b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/module-context.xml
new file mode 100644
index 00000000..6784bb07
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/module-context.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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 id="simpleTrigger" class="org.springframework.scheduling.quartz.SimpleTriggerBean">
+ <property name="jobDetail" ref="jobDetail" />
+ <property name="startDelay" value="500" />
+ <property name="repeatInterval" value="1000" />
+ </bean>
+ <bean id="jobDetail"
+ class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
+ <property name="targetObject" ref="service" />
+ <property name="targetMethod" value="process" />
+ <property name="concurrent" value="false" />
+ </bean>
+ <bean id="schedulerFactoryBean"
+ class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
+ <property name="triggers">
+ <list>
+ <ref bean="simpleTrigger" />
+ </list>
+ </property>
+ </bean>
+ <bean id="service" class="quartz.bundle.same2.internal.StandardService" />
+</beans>
diff --git a/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/osgi-context.xml b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/osgi-context.xml
new file mode 100644
index 00000000..ccf6356a
--- /dev/null
+++ b/test-apps/quartz-scheduler/quartz.bundle.same2/src/main/resources/META-INF/spring/osgi-context.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<beans:beans xmlns="http://www.springframework.org/schema/osgi"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
+ xsi:schemaLocation="
+ http://www.springframework.org/schema/beans
+ http://www.springframework.org/schema/beans/spring-beans.xsd
+ http://www.springframework.org/schema/osgi
+ http://www.springframework.org/schema/osgi/spring-osgi.xsd">
+
+ <service ref="service" interface="quartz.bundle.same2.Service" />
+
+</beans:beans>

Back to the top