You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2017/05/08 15:31:41 UTC
[2/2] syncope git commit: [SYNCOPE-1077] Docs
[SYNCOPE-1077] Docs
Project: http://git-wip-us.apache.org/repos/asf/syncope/repo
Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/091c74b8
Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/091c74b8
Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/091c74b8
Branch: refs/heads/master
Commit: 091c74b8a6d2f317c165ede0f1219774dd6383fc
Parents: 5820eb5
Author: Francesco Chicchiriccò <il...@apache.org>
Authored: Mon May 8 17:31:13 2017 +0200
Committer: Francesco Chicchiriccò <il...@apache.org>
Committed: Mon May 8 17:31:26 2017 +0200
----------------------------------------------------------------------
core/rest-cxf/pom.xml | 5 ++
ext/elasticsearch/client-elasticsearch/pom.xml | 18 +++++
pom.xml | 42 ++++++++++++
.../reference-guide/concepts/extensions.adoc | 25 +++++++
.../workingwithapachesyncope/customization.adoc | 70 ++++++++++++++++++++
5 files changed, 160 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/syncope/blob/091c74b8/core/rest-cxf/pom.xml
----------------------------------------------------------------------
diff --git a/core/rest-cxf/pom.xml b/core/rest-cxf/pom.xml
index d5c64df..51a854a 100644
--- a/core/rest-cxf/pom.xml
+++ b/core/rest-cxf/pom.xml
@@ -84,6 +84,11 @@ under the License.
</dependency>
<dependency>
+ <groupId>joda-time</groupId>
+ <artifactId>joda-time</artifactId>
+ </dependency>
+
+ <dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-frontend-jaxrs</artifactId>
</dependency>
http://git-wip-us.apache.org/repos/asf/syncope/blob/091c74b8/ext/elasticsearch/client-elasticsearch/pom.xml
----------------------------------------------------------------------
diff --git a/ext/elasticsearch/client-elasticsearch/pom.xml b/ext/elasticsearch/client-elasticsearch/pom.xml
index 68bf4b8..08e1314 100644
--- a/ext/elasticsearch/client-elasticsearch/pom.xml
+++ b/ext/elasticsearch/client-elasticsearch/pom.xml
@@ -48,6 +48,24 @@ under the License.
<groupId>org.elasticsearch.client</groupId>
<artifactId>transport</artifactId>
</dependency>
+
+ <dependency>
+ <groupId>com.fasterxml.jackson.dataformat</groupId>
+ <artifactId>jackson-dataformat-smile</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>com.fasterxml.jackson.dataformat</groupId>
+ <artifactId>jackson-dataformat-cbor</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>com.fasterxml.jackson.datatype</groupId>
+ <artifactId>jackson-datatype-joda</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>joda-time</groupId>
+ <artifactId>joda-time</artifactId>
+ </dependency>
</dependencies>
<build>
http://git-wip-us.apache.org/repos/asf/syncope/blob/091c74b8/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 835dc1d..828bf2c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -392,6 +392,8 @@ under the License.
<commons-collection.version>4.1</commons-collection.version>
<commons-logging.version>1.1.3</commons-logging.version>
+ <joda.version>2.9.9</joda.version>
+
<h2.version>1.4.195</h2.version>
<junit.version>4.12</junit.version>
@@ -708,6 +710,24 @@ under the License.
<groupId>org.elasticsearch.client</groupId>
<artifactId>transport</artifactId>
<version>${elasticsearch.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>com.fasterxml.jackson.datatype</groupId>
+ <artifactId>jackson-dataformat-smile</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.fasterxml.jackson.datatype</groupId>
+ <artifactId>jackson-dataformat-yaml</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.fasterxml.jackson.datatype</groupId>
+ <artifactId>jackson-dataformat-cbor</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>joda-time</groupId>
+ <artifactId>joda-time</artifactId>
+ </exclusion>
+ </exclusions>
</dependency>
<dependency>
@@ -762,6 +782,12 @@ under the License.
<groupId>com.fasterxml.jackson.datatype</groupId>
<artifactId>jackson-datatype-joda</artifactId>
<version>${jackson.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>joda-time</groupId>
+ <artifactId>joda-time</artifactId>
+ </exclusion>
+ </exclusions>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
@@ -785,6 +811,16 @@ under the License.
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.dataformat</groupId>
+ <artifactId>jackson-dataformat-smile</artifactId>
+ <version>${jackson.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>com.fasterxml.jackson.dataformat</groupId>
+ <artifactId>jackson-dataformat-cbor</artifactId>
+ <version>${jackson.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>com.fasterxml.jackson.dataformat</groupId>
<artifactId>jackson-dataformat-xml</artifactId>
<version>${jackson.version}</version>
<exclusions>
@@ -800,6 +836,12 @@ under the License.
</dependency>
<dependency>
+ <groupId>joda-time</groupId>
+ <artifactId>joda-time</artifactId>
+ <version>${joda.version}</version>
+ </dependency>
+
+ <dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<version>${spring.version}</version>
http://git-wip-us.apache.org/repos/asf/syncope/blob/091c74b8/src/main/asciidoc/reference-guide/concepts/extensions.adoc
----------------------------------------------------------------------
diff --git a/src/main/asciidoc/reference-guide/concepts/extensions.adoc b/src/main/asciidoc/reference-guide/concepts/extensions.adoc
index 9182460..3397295 100644
--- a/src/main/asciidoc/reference-guide/concepts/extensions.adoc
+++ b/src/main/asciidoc/reference-guide/concepts/extensions.adoc
@@ -115,3 +115,28 @@ endif::[]
This extension adds features to all components and layers that are available, and can be taken as reference when creating
<<customization-extensions,new extensions>>.
====
+
+==== Elasticsearch
+
+[WARNING]
+This extension requires the latest JDK 8 that is available.
+
+This extension provides an alternate internal search engine for <<users-groups-and-any-objects>>, requiring an external
+https://www.elastic.co/[Elasticsearch^] cluster.
+
+[TIP]
+As search operations are central for different aspects of the <<provisioning,provisioning process>>, the global
+performances are expected to improve when using this extension.
+
+[NOTE]
+.Extension Sources
+====
+The source code of this extension is available from the Apache Syncope
+ifeval::["{snapshotOrRelease}" == "release"]
+https://github.com/apache/syncope/tree/syncope-{docVersion}/ext/elasticsearch[source tree^]
+endif::[]
+ifeval::["{snapshotOrRelease}" == "snapshot"]
+https://github.com/apache/syncope/tree/2_0_X/ext/elasticsearch[source tree^]
+endif::[]
+.
+====
http://git-wip-us.apache.org/repos/asf/syncope/blob/091c74b8/src/main/asciidoc/reference-guide/workingwithapachesyncope/customization.adoc
----------------------------------------------------------------------
diff --git a/src/main/asciidoc/reference-guide/workingwithapachesyncope/customization.adoc b/src/main/asciidoc/reference-guide/workingwithapachesyncope/customization.adoc
index 9afafa9..afbca7b 100644
--- a/src/main/asciidoc/reference-guide/workingwithapachesyncope/customization.adoc
+++ b/src/main/asciidoc/reference-guide/workingwithapachesyncope/customization.adoc
@@ -348,6 +348,76 @@ Copy `core/src/main/resources/all/saml2sp-logic.properties` to `core/src/main/re
Setup a <<keystore,keystore>> and place it under the <<properties-files-location,configuration directory>>, then review
the content of `core/src/main/resources/saml2sp-logic.properties` accordingly.
+[discrete]
+===== Enable the <<elasticsearch>> extension
+
+[WARNING]
+This extension requires the latest JDK 8 that is available.
+
+Add the following dependencies to `core/pom.xml`:
+
+[source,xml,subs="verbatim,attributes"]
+----
+<dependency>
+ <groupId>org.apache.syncope.ext.elasticsearch</groupId>
+ <artifactId>syncope-ext-elasticsearch-provisioning-java</artifactId>
+ <version>${syncope.version}</version>
+</dependency>
+<dependency>
+ <groupId>org.apache.syncope.ext.elasticsearch</groupId>
+ <artifactId>syncope-ext-elasticsearch-persistence-jpa</artifactId>
+ <version>${syncope.version}</version>
+</dependency>
+----
+
+Download
+
+ifeval::["{snapshotOrRelease}" == "release"]
+https://github.com/apache/syncope/blob/syncope-{docVersion}/ext/elasticsearch/persistence-jpa/src/main/resources/persistence.properties[persistence.properties^]
+endif::[]
+ifeval::["{snapshotOrRelease}" == "snapshot"]
+https://github.com/apache/syncope/blob/2_0_X/ext/elasticsearch/persistence-jpa/src/main/resources/persistence.properties[persistence.properties^]
+endif::[]
+
+and
+
+ifeval::["{snapshotOrRelease}" == "release"]
+https://github.com/apache/syncope/blob/syncope-{docVersion}/ext/elasticsearch/client-elasticsearch/src/main/resources/elasticsearchClientContext.xml[elasticsearchClientContext.xml^]
+endif::[]
+ifeval::["{snapshotOrRelease}" == "snapshot"]
+https://github.com/apache/syncope/blob/2_0_X/ext/elasticsearch/client-elasticsearch/src/main/resources/elasticsearchClientContext.xml[elasticsearchClientContext.xml^]
+endif::[]
+
+then save both under `core/src/main/resources`.
+
+Now, adjust the parameters in `core/src/main/resources/elasticsearchClientContext.xml` to match your
+Elasticsearch deployment.
+
+Finally, replace the following text in `core/src/main/webapp/WEB-INF/web.xml`:
+
+....
+classpath*:/coreContext.xml
+classpath*:/securityContext.xml
+classpath*:/logicContext.xml
+classpath*:/restCXFContext.xml
+classpath*:/persistenceContext.xml
+classpath*:/provisioning*Context.xml
+classpath*:/workflow*Context.xml
+....
+
+with
+
+....
+ classpath*:/coreContext.xml
+ classpath*:/elasticsearchClientContext.xml
+ classpath*:/securityContext.xml
+ classpath*:/logicContext.xml
+ classpath*:/restCXFContext.xml
+ classpath*:/persistenceContext.xml
+ classpath*:/provisioning*Context.xml
+ classpath*:/workflow*Context.xml
+....
+
[[customization-console]]
==== Console