Commit a7fef464 authored by Brian Long's avatar Brian Long
Browse files

initial checkin

parents
Loading
Loading
Loading
Loading

.gitignore

0 → 100644
+9 −0
Original line number Diff line number Diff line
# Maven
target
pom.xml.versionsBackup

# Eclipse
.project
.classpath
.settings

.vscode/settings.json

0 → 100644
+3 −0
Original line number Diff line number Diff line
{
    "java.configuration.updateBuildConfiguration": "disabled"
}
 No newline at end of file

README.md

0 → 100644
+245 −0
Original line number Diff line number Diff line
# Order of the Bee Development Kit

This project is a Maven aggregator for the components of the *proposed* Order of the Bee Development Kit.  The proposed abbreviation for this kit is the **BeeDK**.

## Purpose

The sole purpose of this project is to build all the submodule components.  It is not the Maven Parent of any Maven project.  This means this project is not to be directly used by a developer using the BeeDK, but only a developer that is developing, building, or deploying the BeeDK.

## For BeeDK Users

### Configuration

There are a couple configurations required to use the components of the BeeDK.  Those are covered in the sections below.

#### Plugin Repository

First, you will need define a reference to the repository for the BeeDK tiles.  This is the case until they find their way into the Maven Central Repository.

You will need to define a plugin repository in your `setting.xml` or your project `pom.xml`.  The following snippet is meant to be included in your `~/.m2/settings.xml` file.

> If you choose to include it in your project `pom.xml`, ignore the structure outside the `pluginRepositories` element and place that element directly under the `project` element.

```xml
<settings ...>
	...
	<profiles>
		...
		<profile>
			<id>inteligr8</id>
			<pluginRepositories>
				<pluginRepository>
					<id>inteligr8-public</id>
					<url>http://repos.inteligr8.com/nexus/repository/inteligr8-public</url>
				</pluginRepository>
			</pluginRepositories>
		</profile>
		...
	</profiles>
	...
</settings>
```

#### Archetype

Next, you will need to configure using a repository not named Maven Central for archetypes.  Defining a location for archetypes is incredibly bug-laden in the Maven Archetype plugin framework.  The only good way to achieve it is by defining an alternative `settings.xml` file.  So create a new file called `.m2/beedk-settings.xml` with the following contents.

```xml
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
		xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
		xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 https://maven.apache.org/xsd/settings-1.0.0.xsd">
	<profiles>
		<profile>
			<id>custom-archetype</id>
			<repositories>
				<repository>
					<id>archetype</id>
					<url>http://repos.inteligr8.com/nexus/repository/inteligr8-public</url>
				</repository>
			</repositories>
		</profile>
	</profiles>
	<activeProfiles>
		<activeProfile>custom-archetype</activeProfile>
	</activeProfiles>
</settings>
```

### Components

The following components are useful to users of the BeeDK.

#### Public API

| Component                             | Folder Link   | Details |
| ------------------------------------- | ------------- | ------- |
| `beedk-acs-platform-module-tile`      | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-module-tile)      | Intended to be inherited by all Alfresco Platform module projects; Includes ampification, integration testing framework, and more. |
| `beedk-acs-share-module-tile`         | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-share-module-tile)         | Intended to be inherited by all Alfresco Share module projects; Includes ampification, JS compression, integration testing framework, and more. |
| `beedk-acs-platform-webapp-tile`      | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-webapp-tile)      | Intended to be inherited by all Alfresco Platform web application projects; Includes installing AMPs, integration testing framework, and more. |
| `beedk-acs-share-webapp-tile`         | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-share-webapp-tile)         | Intended to be inherited by all Alfresco Share web application projects; Includes installing AMPs, integration testing framework, and more. |
| `beedk-ate-springboot`                | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-ate-springboot) | Intended to be inherited by all Alfresco Transform Engine Spring Boot projects; Includes dependencies. |
| `beedk-ate-springboot-test`           | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-ate-springboot-test) | Intended to be inherited by all Alfresco Transform Engine Spring Boot projects; Includes dependencies. |
| `beedk-ate-springboot-tile`           | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-ate-springboot-tile) | Intended to be inherited by all Alfresco Transform Engine Spring Boot projects; Includes Spring Boot repackaging and more. |
| `beedk-aps-ext-tile`                  | *Coming Soon* | Intended to be inherited by all Alfresco Process Service extension projects; Includes integration testing framework and more. |
| `beedk-flowable-ext-tile`             | *Coming Soon* | Intended to be inherited by all Flowable extension projects; Includes integration testing framework and more. |
| `beedk-camunda-ext-tile`              | *Coming Soon* | Intended to be inherited by all Camunda extension projects; Includes integration testing framework and more. |

#### ACS Platform Accessories

| Component                             | Folder Link   | Details |
| ------------------------------------- | ------------- | ------- |
| `beedk-acs-platform-docker-tile`      | *Coming Soon* | Intended to be inherited by any project that already includes a `beedk-acs-platform-webapp-tile` Maven Tile and wants to deliver a Docker image; Includes building and publishing the container images and more. |
| `beedk-acs-platform-sibling-it-tile`  | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-sibling-it-tile) | Intended to be inherited by any Maven project that has a sibling Alfresco Platform module or web application Maven project.  It enables integration testing with the sibling ACS Platform.  This is great for ACS Share modules, ACS Share web applications, custom Alfresco Transform Engines, and APS extensions in **all-in-one** style Maven projects. |
| `beedk-acs-platform-artifact-it-tile` | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-artifact-it-tile) | Intended to be inherited by any Maven project that does not have a sibling Alfresco Platform module or web application Maven project.  It enables integration testing with any ACS Platform as an already built Maven Artifact.  This is great for ACS Share modules, ACS Share web applications, custom Alfresco Transform Engines, APS extensions, and non-Alfresco applications in **standalone** projects. |
| `beedk-acs-search-it-tile`            | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-search-it-tile)            | Intended to be inherited by any project that already includes a `beedk-acs-platform-*-tile` Maven Tile.  It enables integration testing of the ACS Platform with the Alfresco Search Services enabled.  This is great for any project requiring non-transactional search functionality for integration testing purposes. |
| `beedk-acs-lts-it-tile`               | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-lts-it-tile)               | Intended to be inherited by any project that already includes a `beedk-acs-platform-*-tile` Maven Tile.  It enables integration testing of the ACS Platform with the Local Transform Service and the AIO Transform Engine enabled.  This is great for any project requiring basic transformation functionality for integration testing purposes. |
| `beedk-ats-it-tile`                   | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-ats-it-tile)                   | Intended to be inherited by any project that already includes a `beedk-acs-platform-*-tile` Maven Tile.  It enables integration testing of the ACS Platform with the Alfresco Transform Service (ATS) enabled.  This is great for any project requiring Alfresco Enterprise transformation functionality for integration testing purposes. |
| `beedk-ate-it-tile`                   | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-ate-it-tile)                   | Intended to be inherited by any project that already includes a `beedk-acs-platform-*-tile` Maven Tile.  It enables integration testing of the ACS Platform with a specific Alfresco Transform Engine (ATE) enabled.  This is great for any project requiring custom Alfresco transformation functionality for integration testing purposes. |

#### ACS Share Accessories

| Component                             | Folder Link   | Details |
| ------------------------------------- | ------------- | ------- |
| `beedk-acs-share-docker-tile`         | *Coming Soon* | Intended to be inherited by any project that already includes a `beedk-acs-share-webapp-tile` Maven Tile and wants to deliver a Docker image; Includes building and publishing the container images and more. |

#### ACS Share Accessories

| Component                             | Folder Link   | Details |
| ------------------------------------- | ------------- | ------- |
| `beedk-ate-docker-tile`               | *Coming Soon* | Intended to be inherited by any project that already includes a `beedk-ate-app-tile` tile and wants to deliver a Docker image. |

#### Rapid Application Development

| Component                              | Folder Link   | Details |
| -------------------------------------- | ------------- | ------- |
| `beedk-acs-platform-self-rad-tile`     | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-self-rad-tile) | Intended to be inherited by any Alfresco Platform module or web application projects; Includes startup with partial hot reloading. |
| `beedk-acs-platform-sibling-rad-tile`  | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-sibling-rad-tile) | Intended to be inherited by any Maven project that has a sibling Alfresco Platform module or web application Maven project; Includes simple startup to assist with development. |
| `beedk-acs-platform-artifact-rad-tile` | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-artifact-rad-tile) | Intended to be inherited by any Maven project that wants to use the Alfresco Platform web application; Includes simple startup to assist with development. |
| `beedk-acs-share-self-rad-tile`        | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-acs-share-self-rad-tile) | Intended to be inherited by any Alfresco Platform module or web application projects; Includes startup with partial hot reloading. |
| `beedk-ate-rad-tile`                   | [Source](/inteligr8/ootbee-beedk/src/stable/beedk-ate-rad-tile) | Intended to be inherited by any Alfresco Transform Engine projects; Includes startup with partial hot reloading. |

### Rapid Application Development

If your project includes RAD tiles, you can start the application with the following command.

```sh
mvn -Drad process-classes
```

To stop RAD and remove the Docker containers, you will need to do it through Docker commands.  This will differ between operating systems.

#### SH or BASH Shells

```sh
docker container stop `docker container ls -q --filter={artifactId}-*`
docker container rm `docker container ls -aq --filter={artifactId}-*`
```

#### Microsoft PowerShell

```PowerShell
docker container ls -q --filter={artifactId}-* | % { docker container stop $_ }
docker container ls -aq --filter={artifactId}-* | % { docker container rm $_ }
```

### Archetypes

| Archetype                   | Folder Link   | Details |
| --------------------------- | ------------- | ------- |
| `beedk-acs-platform-module` | *Coming Soon* | Generates a standalone ACS Platform module project. |
| `beedk-acs-platform-webapp` | *Coming Soon* | Generates a standalone ACS Platform webapp project. |
| `beedk-acs-share-module`    | *Coming Soon* | Generates a standalone ACS Share module project. |
| `beedk-acs-share-webapp`    | *Coming Soon* | Generates a standalone ACS Share webapp project. |
| `beedk-acs-aio`             | *Coming Soon* | Generates a parent, ACS Platform webapp, ACS Share webapp, 2 sample ACS Platform module, and 2 sample ACS Share module projects. |
| `beedk-ate-app`             | *Coming Soon* | Generates a standalone Alfresco Transform Engine project. |
| `beedk-ate-aio`             | *Coming Soon* | Generates a parent, ATE app, ACS Platform webapp, ACS Share webapp, and a sample ACS Platform module projects.  The ACS Platform module will include sample ATE configuration. |
| `beedk-activiti-ext`        | *Coming Soon* | Generates a standalone APS/Activiti extension project. |
| `beedk-flowable-ext`        | *Coming Soon* | Generates a standalone [Flowable](https://flowable.com) extension project.  Flowable is a fork of Activiti 6. |
| `beedk-camunda-ext`         | *Coming Soon* | Generates a standalone [Camunda](https://camunda.com) extension project.  Camunda is a fork of Activiti 5. |

You can use one of these Maven Archetypes to generate a new project by executing the following at the command line.

```sh
mvn -s ~/.m2/beedk-settings.xml archetype:generate
```

### Scaffolding

This is a feature that is designed to be extended in the near future.  It will include minimal engines on first release.  The goals is to "generate" resources and code for developers so they can quickly implement certain features.  Each feature supported is called a scaffolding engine.  The goal is to support several scaffold engines that would execute like the following command.

```sh
mvn -Dscaffold-webscript -Dbeedk.name=test-webscript -Dbeedk.method=get -Dbeedk.style=java
```

There is currently one scaffolding engine implemented, but it is useful across all the BeeDK Maven Tiles.

| Engine          | Options | Description |
| --------------- | ------- | ----------- |
| `scaffold`      |         | Generates the required files for the applicable Maven Tile. |

The plan is to implement the following engines (and more).

| Engine                  | Options | Description |
| ----------------------- | ------- | ----------- |
| `scaffold-webscript`    | `name`, `method` (**`get`**, `post`, ...), `style` (**`java`**, `java-ftl`, `js`) | Generates skeleton code for the configuration and implementation of a Spring Web Script; a ReST entrypoint. |
| `scaffold-behavior`     | `name`, `event` (`onUpdateProperties`, ...) | Generates skeleton code for the configuration and implementation of an Alfresco Policy Behavior; an event listener entrypoint. |
| `scaffold-job`          | `name`, `schedule` | Generates skeleton code for the configuration and implementation of a Quartz Job; a scheduled periodic execution entrypoint. |
| `scaffold-action`       | `name`  | Generates skeleton code for the configuration and implementation of an Alfresco Action; a function that may be executed through API calls or ACS Share hooks. |
| `scaffold-rendition`    | `name`  | Generates skeleton code for the configuration of an Alfresco rendition. |
| `scaffold-evaluator`    | `name`, `type` (**`component`**, `em`) | Generates skeleton code for the configuration and implementation of a Spring Surf (ACS Share) evaluator; a conditional filter on user interface components or extensibility modules. |
| `scaffold-extmodule`    | `name`, `style` (**`config`**, `webscript`) | Generates skeleton code for the configuration and implementation of a Spring Surf extensibility module. |
| `scaffold-transformer`  | `name`  | Generates skeleton code for the configuration and implementation of an Alfresco Transform Engine Spring Boot application and transformer Spring service. |

## For BeeDK Maintainers

### Build Components

You can build the components of the BeeDK by cloning this repository and executing the typical Maven commands.  There is nothing special to consider.  A brief example is provided below.

```sh
git clone git@bitbucket.org:inteligr8/ootbee-beedk.git
cd ootbee-beedk
mvn clean package
```

### Development Model

This project uses a development model with two active Git branches: `develop` and `stable`.  All changes are to be made to branches not named `stable`.  If you use neither of these branches, first merge your changes into the `develop` branch.  Those changes should then be merged into the `stable` branch.  The following sets of commands intends to demonstrate all the Maven and Git commands used from inception to delivery of each bug fix or feature request.

#### Fork & Pull Requesst

If you choose to fork the repository, then no problem.  When you want to "push" you changes to this repository, create a pull request against the `develop` branch.

#### For Direct Maintainers

```sh
git clone git@bitbucket.org:inteligr8/ootbee-beedk.git
cd ootbee-beedk
git checkout develop
git checkout -b personal
# make your changes
mvn clean package
git add .
git commit -m "your informative commit message"
git push -u origin personal
# make more changes
mvn clean verify
git add .
git commit -m "another informative commmit message"
git push origin
# development done 
git checkout develop
git merge personal
# resolve conflicts, if applicable
git push origin
git checkout stable
git merge develop
mvn versions:set
mvn clean deploy
git add pom.xml
git commit -m "vX.Y.Z poms"
git tag vX.Y.Z
git push origin
git push origin vX.Y.Z
git checkout develop
```
+9 −0
Original line number Diff line number Diff line
# Maven
/target
pom.xml.versionsBackup

# Eclipse
.settings
.project
.classpath
+52 −0
Original line number Diff line number Diff line
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
	
	<modelVersion>4.0.0</modelVersion>
 
	<groupId>com.inteligr8.ootbee</groupId>
	<artifactId>beedk-acs-allinone-archetype</artifactId>
	<version>1.0-SNAPSHOT</version>
	<packaging>maven-archetype</packaging>

	<name>Order of the Bee Development Kit: Project Scaffolding for multi-module ACS projects</name>
	<scm>
		<url>https://bitbucket.org/inteligr8/ootbee-beedk</url>
	</scm>
	<organization>
		<name>Order of the Bee</name>
		<url>https://orderofthebee.net</url>
	</organization>
	<developers>
		<developer>
			<name>Brian Long</name>
			<email>brian@inteligr8.com</email>
			<organization>Inteligr8</organization>
			<organizationUrl>https://www.inteligr8.com</organizationUrl>
			<url>https://twitter.com/brianmlong</url>
		</developer>
	</developers>
	
	<build>
		<extensions>
			<extension>
				<groupId>org.apache.maven.archetype</groupId>
				<artifactId>archetype-packaging</artifactId>
				<version>3.1.1</version>
			</extension>
		</extensions>
		<plugins>
			<plugin>
				<groupId>io.repaint.maven</groupId>
				<artifactId>tiles-maven-plugin</artifactId>
				<version>2.20</version>
				<extensions>true</extensions>
				<configuration>
					<tiles>
						<tile>com.inteligr8:maven-public-deploy-tile:[1.0.0,2.0.0)</tile>
					</tiles>
				</configuration>
			</plugin>
		</plugins>
	</build>
</project>
Loading