Add first simple example
diff --git a/README.adoc b/README.adoc
index 4dbbfff..afeb4f4 100644
--- a/README.adoc
+++ b/README.adoc
@@ -1,13 +1,14 @@
= Apache Winegrower
-Apache Winegrower is an application framework supporting several programming models.
-It allows you to easily create applications, with different packaging options, from standalone jar to cloud application and docker.
+Apache Winegrower is a ligthweight and powerful application framework.
-Apache Winegrower supports the following development frameworks:
+It brings the powerful OSGi model without all the issue and help of bundle classloaders.
+Winegrower fully supports the activator and service model but use an unique classloader.
-* CDI
-* Spring
-* Simplified OSGi (single classloader but all the service lifecycle and activator support)
+It supports both OSGi and regular application.
+
+Apache Winegrower provides several packaging options, like standalone jar, exploded jar, docker images.
+It's also cloud ready and provides tooling to provision your applications on cloud providers.
== Sample
diff --git a/pom.xml b/pom.xml
index cf50fbe..726811e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -53,7 +53,7 @@
<module>winegrower-core</module>
<module>winegrower-extension</module>
<module>winegrower-cepages</module>
- <!-- <module>winegrower-examples</module> -->
+ <module>winegrower-examples</module>
<!-- <module>winegrower-testing</module> -->
</modules>
diff --git a/winegrower-core/src/main/java/org/apache/winegrower/Ripener.java b/winegrower-core/src/main/java/org/apache/winegrower/Ripener.java
index b5be672..11b0c5a 100644
--- a/winegrower-core/src/main/java/org/apache/winegrower/Ripener.java
+++ b/winegrower-core/src/main/java/org/apache/winegrower/Ripener.java
@@ -219,7 +219,7 @@
latch.countDown();
}
});
- try (final Ripener framework = new Ripener.Impl(new Configuration()).start()) {
+ try (final Ripener ripener = new Ripener.Impl(new Configuration()).start()) {
try {
latch.await();
} catch (final InterruptedException e) {
diff --git a/winegrower-examples/pom.xml b/winegrower-examples/pom.xml
new file mode 100644
index 0000000..7a68cf5
--- /dev/null
+++ b/winegrower-examples/pom.xml
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE 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.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="
+ http://maven.apache.org/POM/4.0.0
+ http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.winegrower</groupId>
+ <artifactId>winegrower</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <groupId>org.apache.winegrower</groupId>
+ <artifactId>examples</artifactId>
+ <packaging>pom</packaging>
+
+ <modules>
+ <module>simple</module>
+ <!-- <module>bundle</module> -->
+ <!-- <module>shell</module> -->
+ <!-- <module>monitoring</module> -->
+ <!-- <module>cdi</module> -->
+ <!-- <module>spring</module> -->
+ </modules>
+
+</project>
\ No newline at end of file
diff --git a/winegrower-examples/simple/README.adoc b/winegrower-examples/simple/README.adoc
new file mode 100644
index 0000000..2d90cb4
--- /dev/null
+++ b/winegrower-examples/simple/README.adoc
@@ -0,0 +1,13 @@
+= Apache Winegrower - Simple example
+
+This is example is the minimum application you can create with Winegrower.
+
+Your application is a regular jar with a Winegrower activator entry point (a class annotation with `@ImplicitActivator`).
+
+NB: this simple example is not OSGi compatible, it only runs with Winegrower.
+
+== Dependencies
+
+The only dependency you need is `winegrower-core`.
+
+== Start
\ No newline at end of file
diff --git a/winegrower-examples/simple/pom.xml b/winegrower-examples/simple/pom.xml
new file mode 100644
index 0000000..f66a85c
--- /dev/null
+++ b/winegrower-examples/simple/pom.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE 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.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="
+ http://maven.apache.org/POM/4.0.0
+ http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.winegrower</groupId>
+ <artifactId>examples</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <groupId>org.apache.winegrower.examples</groupId>
+ <artifactId>simple</artifactId>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.winegrower</groupId>
+ <artifactId>winegrower-core</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>exec-maven-plugin</artifactId>
+ <version>1.6.0</version>
+ <configuration>
+ <mainClass>org.apache.winegrower.Ripener</mainClass>
+ <systemProperties>
+ <systemProperty>
+ <key>org.slf4j.simpleLogger.defaultLogLevel</key>
+ <value>DEBUG</value>
+ </systemProperty>
+ <systemProperty>
+ <key>org.slf4j.simpleLogger.logFile</key>
+ <value>System.out</value>
+ </systemProperty>
+ </systemProperties>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
\ No newline at end of file
diff --git a/winegrower-examples/simple/src/main/java/org/apache/winegrower/examples/Simple.java b/winegrower-examples/simple/src/main/java/org/apache/winegrower/examples/Simple.java
new file mode 100644
index 0000000..9b4b679
--- /dev/null
+++ b/winegrower-examples/simple/src/main/java/org/apache/winegrower/examples/Simple.java
@@ -0,0 +1,31 @@
+/**
+ * Licensed 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
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * 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.
+ */
+package org.apache.winegrower.examples;
+
+import org.apache.winegrower.api.ImplicitActivator;
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+
+@ImplicitActivator
+public class Simple implements BundleActivator {
+
+ public void start(BundleContext bundleContext) {
+ System.out.println("Starting simple winegrower application");
+ }
+
+ public void stop(BundleContext bundleContext) {
+ System.out.println("Stopping simple winegrower application");
+ }
+
+}