Skip to content

Commit

Permalink
Merge branch 'release/1.1.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
gruberrolandvaltech committed Jul 25, 2018
2 parents 3f849ab + ee829e5 commit b74885f
Show file tree
Hide file tree
Showing 32 changed files with 487 additions and 132 deletions.
16 changes: 16 additions & 0 deletions HISTORY
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
2018-07-25 1.1.0
- Design improvements
- AEM 6.4 support
- Moved filter classes to API
- Bundle: update Groovy Console to version 12.0.0


2018-07-19 1.0.0
- Fixes for install hook
- Bundle package that also installs Groovy Console
- Performance improvements


2018-07-19 0.9
- initial release

98 changes: 93 additions & 5 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ Table of contents
5. [Extension to Groovy Console](#groovy)
6. [JMX Interface](#jmx)
7. [Health Checks](#healthchecks)
8. [License](#license)
8. [API Documentation](#api)
9. [License](#license)
10. [Changelog](#changelog)
11. [Developers](#developers)


<a name="requirements"></a>
Expand All @@ -35,15 +38,33 @@ AECU requires Java 8 and AEM 6.3 or above. Groovy Console can be installed manua

# Installation

TODO
You can download the package from [Maven Central](http://repo1.maven.org/maven2/de/valtech/aecu/aecu.ui.apps/) or our [releases section](https://github.com/valtech/aem-easy-content-upgrade/releases). The aecu.ui.apps package will install the AECU software. It requires that you installed [Groovy Console](https://github.com/OlsonDigital/aem-groovy-console) before.

```xml
<dependency>
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu.ui.apps</artifactId>
<version>LATEST</version>
<type>zip</type>
</dependency>
```


<a name="bundleInstall"></a>

## Bundle Installation

To simplify installation we provide a bundle package that already includes the Groovy Console. This makes sure there are no compatibility issues.
The package is also available on [Maven Central](http://repo1.maven.org/maven2/de/valtech/aecu/aecu.bundle/) or our [releases section](https://github.com/valtech/aem-easy-content-upgrade/releases).

TODO
```xml
<dependency>
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu.bundle</artifactId>
<version>LATEST</version>
<type>zip</type>
</dependency>
```


<a name="execution"></a>
Expand Down Expand Up @@ -255,7 +276,60 @@ println aecu.contentUpgradeBuilder()
.run()
```

TODO
### Copy and Move Nodes

The matching nodes can be copied/moved to a new location. You can use ".." if you want to step back in path.

* doCopyResourceToRelativePath(String relativePath): copies the node to the given target path
* doMoveResourceToRelativePath(String relativePath): moves the node to the given target path

```java
println aecu.contentUpgradeBuilder()
.forChildResourcesOf("/content/we-retail/ca/en")
.filterByNodeName("jcr:content")
.doCopyResourceToRelativePath("subNode")
.doCopyResourceToRelativePath("../subNode")
.doMoveResourceToRelativePath("subNode")
.run()
```

### Delete nodes

You can delete all nodes that match your collection and filter.

* doDeleteResource(): deletes the matching nodes

```java
println aecu.contentUpgradeBuilder()
.forChildResourcesOf("/content/we-retail/ca/en")
.filterByNodeName("jcr:content")
.doDeleteResource()
.run()
```

### Print Nodes

Sometimes, you only want to print the path of the matched nodes.

* printPath(): prints the path of the matched node

```java
println aecu.contentUpgradeBuilder()
.forChildResourcesOf("/content/we-retail/ca/en")
.filterByNodeName("jcr:content")
.printPath()
.run()
```


## Run Options

At the end you can run all actions or perform a dry-run first. The dry-run will just provide output about modifications but not save any changes. The normal run saves the session, no additional "session.save()" is required.

* run(): performs all actions and saves the session
* dryRun(): only prints actions but does not perform repository changes
* run(boolean dryRun): the "dryRun" parameter defines if it should be a run or dry-run


# JMX Interface

Expand Down Expand Up @@ -296,12 +370,26 @@ For the status of older runs use AECU's history page.

<img src="docs/images/healthCheck.png">

<a name="api"></a>

# API Documentation

You can access our AECU service (AecuService class) in case you have special requirements. See the [API documentation](https://valtech.github.io/aem-easy-content-upgrade/).

<a name="license"></a>

# License

The AC Tool is licensed under the [MIT LICENSE](LICENSE).

<a name="changelog"></a>

# Changelog

Please see our [history file](HISTORY).

<a name="developers"></a>

# Developers

See our [developer zone](docs/developers.md)
See our [developer zone](docs/developers.md).
6 changes: 5 additions & 1 deletion api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu</artifactId>
<version>1.0.0</version>
<version>1.1.0</version>
</parent>

<artifactId>aecu.api</artifactId>
Expand Down Expand Up @@ -86,5 +86,9 @@
<groupId>junit-addons</groupId>
<artifactId>junit-addons</artifactId>
</dependency>
<dependency>
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@
*/
package de.valtech.aecu.core.groovy.console.bindings.filters;

import org.apache.sling.api.resource.Resource;

import java.util.List;

import javax.annotation.Nonnull;

import org.apache.sling.api.resource.Resource;

/**
* @author Roxana Muresan
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/*
* Copyright 2018 Valtech GmbH
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
* associated documentation files (the "Software"), to deal in the Software without restriction,
* including without limitation the rights to use, copy, modify, merge, publish, distribute,
* sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all copies or
* substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
* NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/

/**
* Filters are used in aecu Groovy Console binding to filter matching nodes.
*
* @author Roxana Muresan
*/
@Version("1.0")
package de.valtech.aecu.core.groovy.console.bindings.filters;

import org.osgi.annotation.versioning.Version;
26 changes: 26 additions & 0 deletions api/src/main/javadoc/overview.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>

<head>
<title>AECU API Overview</title>
</head>

<body>
This is the AEM Easy Content Upgrade (AECU) API documentation.

<p>
AECU simplifies content migrations by executing migration scripts during package installation. It is built on top of Groovy Console.
</p>
<p>
Features:
</p>
<ul>
<li>GUI to run scripts and see history of runs</li>
<li>Run mode support</li>
<li>Fallback scripts in case of errors</li>
<li>Extension of Groovy Console bindings</li>
<li>Service API</li>
<li>Health Checks</li>
</ul>
</body>
</html>
2 changes: 1 addition & 1 deletion bundle/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu</artifactId>
<version>1.0.0</version>
<version>1.1.0</version>
</parent>

<artifactId>aecu.bundle</artifactId>
Expand Down
9 changes: 6 additions & 3 deletions core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu</artifactId>
<version>1.0.0</version>
<version>1.1.0</version>
</parent>

<artifactId>aecu.core</artifactId>
Expand All @@ -24,8 +24,11 @@
<extensions>true</extensions>
<configuration>
<instructions>
<!-- Import any version of javax.inject, to allow running on multiple versions of AEM -->
<Import-Package>javax.inject;version=0.0.0,*</Import-Package>
<!--
Import any version of javax.inject, to allow running on multiple versions of AEM
Support Groovy Console 11 and 12 versions
-->
<Import-Package>javax.inject;version=0.0.0,com.icfolson.aem.groovy.console;version="[11,13)",com.icfolson.aem.groovy.console.api;version="[11,13)",com.icfolson.aem.groovy.console.constants;version="[11,13)",com.icfolson.aem.groovy.console.response;version="[11,13)",*</Import-Package>
<Sling-Model-Packages>
de.valtech.aecu.core
</Sling-Model-Packages>
Expand Down
12 changes: 10 additions & 2 deletions docs/developers.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# AEM Server Setup

By default AEM is expected to listen on localhost on port 5702. This setting can be overridden by adding parameters:
* -Daem.port=4502
* -Daem.port=5702
* -Daem.host=localhost
* -Daem.publish.port=5703
* -Daem.publish.host=localhost

You need AEM 6.3 with service pack 2.
You need AEM 6.3 with service pack 2 or AEM 6.4.

# Build and Deploy

Expand All @@ -20,6 +22,12 @@ In case you want to deploy core only you can use this command in core folder:
mvn clean install -PautoInstallBundle
```

To build and deploy on publish instance run this in the base (aem-easy-content-upgrade) or ui.apps/examples folder:

```bash
mvn clean install -PautoInstallPackagePublish
```


# Code Formatting

Expand Down
Binary file modified docs/images/historyDetails.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/historyOverview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/run.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu</artifactId>
<version>1.0.0</version>
<version>1.1.0</version>
</parent>

<artifactId>aecu.examples</artifactId>
Expand Down

This file was deleted.

6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu</artifactId>
<packaging>pom</packaging>
<version>1.0.0</version>
<version>1.1.0</version>
<name>AECU</name>
<description>AEM Easy COntent Upgrade</description>
<url>https://github.com/valtech/aem-easy-content-upgrade</url>
Expand Down Expand Up @@ -493,7 +493,7 @@
<dependency>
<groupId>com.icfolson.aem.groovy.console</groupId>
<artifactId>aem-groovy-console</artifactId>
<version>11.3.0</version>
<version>12.0.0</version>
<scope>provided</scope>
<!-- exclude dependencies -->
<exclusions>
Expand All @@ -506,7 +506,7 @@
<dependency>
<groupId>com.icfolson.aem.groovy.console</groupId>
<artifactId>aem-groovy-console</artifactId>
<version>11.3.0</version>
<version>12.0.0</version>
<type>zip</type>
<!-- exclude dependencies -->
<exclusions>
Expand Down
2 changes: 1 addition & 1 deletion ui.apps/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>de.valtech.aecu</groupId>
<artifactId>aecu</artifactId>
<version>1.0.0</version>
<version>1.1.0</version>
</parent>

<artifactId>aecu.ui.apps</artifactId>
Expand Down
Loading

0 comments on commit b74885f

Please sign in to comment.