exo-jcr SVN: r3568 - jcr/trunk/exo.jcr.docs/exo.jcr.docs.developer/en/src/main/docbook/en-US/modules/jcr/backup.
by do-not-reply@jboss.org
Author: areshetnyak
Date: 2010-11-25 10:11:40 -0500 (Thu, 25 Nov 2010)
New Revision: 3568
Modified:
jcr/trunk/exo.jcr.docs/exo.jcr.docs.developer/en/src/main/docbook/en-US/modules/jcr/backup/exojcr-backup-service.xml
Log:
EXOJCR-1075 : Changes for "The JCR backupset should be fully independent" was committed.
Modified: jcr/trunk/exo.jcr.docs/exo.jcr.docs.developer/en/src/main/docbook/en-US/modules/jcr/backup/exojcr-backup-service.xml
===================================================================
--- jcr/trunk/exo.jcr.docs/exo.jcr.docs.developer/en/src/main/docbook/en-US/modules/jcr/backup/exojcr-backup-service.xml 2010-11-25 15:10:12 UTC (rev 3567)
+++ jcr/trunk/exo.jcr.docs/exo.jcr.docs.developer/en/src/main/docbook/en-US/modules/jcr/backup/exojcr-backup-service.xml 2010-11-25 15:11:40 UTC (rev 3568)
@@ -587,11 +587,11 @@
</section>
<section>
- <title>Backup log contains the original configurations such as the
- RepositoryEntry or the WorkspaceEntry.</title>
+ <title>Restore a workspace or a repository using original
+ configuration</title>
- <para>Backup manager have special methods to restore with original
- configuration:</para>
+ <para>The Backup manager allows you to restore a repository or a workspace
+ using the original configuration stored into the backup log:</para>
<programlisting>/**
* Restore existing workspace. Previous data will be deleted.
@@ -663,11 +663,11 @@
</section>
<section>
- <title>Backupset portability</title>
+ <title>Backup set portability</title>
- <para>Backup configuration was stored during Backup operation into two
- locations: backup-dir directory of BackupService to support interactive
- operations via Backup API (e.g. console); into Backupset files itself for
- portability (e.g. on another server).</para>
+ <para>The Backup log is stored during the Backup operation into two
+ different locations: backup-dir directory of BackupService to support
+ interactive operations via Backup API (e.g. console) and backup set files
+ for portability (e.g. on another server).</para>
</section>
</chapter>
13 years, 5 months
exo-jcr SVN: r3567 - jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation.
by do-not-reply@jboss.org
Author: sergiykarpenko
Date: 2010-11-25 10:10:12 -0500 (Thu, 25 Nov 2010)
New Revision: 3567
Modified:
jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationException.java
Log:
EXOJCR-929: RepositoryCreationException - changes from rev. 3556 reverted
Modified: jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationException.java
===================================================================
--- jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationException.java 2010-11-25 15:07:35 UTC (rev 3566)
+++ jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationException.java 2010-11-25 15:10:12 UTC (rev 3567)
@@ -16,7 +16,6 @@
*/
package org.exoplatform.services.jcr.ext.repository.creation;
-import javax.jcr.RepositoryException;
/**
* Created by The eXo Platform SAS.
@@ -26,7 +25,7 @@
* @author <a href="karpenko.sergiy(a)gmail.com">Karpenko Sergiy</a>
* @version $Id: RepositoryCreationException.java 111 2008-11-11 11:11:11Z serg $
*/
-public class RepositoryCreationException extends RepositoryException
+public class RepositoryCreationException extends Exception
{
/**
* {@inheritDoc}
13 years, 5 months
exo-jcr SVN: r3566 - jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation.
by do-not-reply@jboss.org
Author: sergiykarpenko
Date: 2010-11-25 10:07:35 -0500 (Thu, 25 Nov 2010)
New Revision: 3566
Modified:
jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationServiceImpl.java
Log:
EXOJCR-929: NameNotFoundException catching added to extractDataSourceNames(..)
Modified: jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationServiceImpl.java
===================================================================
--- jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationServiceImpl.java 2010-11-25 14:51:34 UTC (rev 3565)
+++ jcr/trunk/exo.jcr.component.ext/src/main/java/org/exoplatform/services/jcr/ext/repository/creation/RepositoryCreationServiceImpl.java 2010-11-25 15:07:35 UTC (rev 3566)
@@ -59,6 +59,7 @@
import java.util.concurrent.ConcurrentHashMap;
import javax.jcr.RepositoryException;
+import javax.naming.NameNotFoundException;
import javax.naming.NamingException;
import javax.sql.DataSource;
import javax.xml.stream.XMLStreamException;
@@ -101,7 +102,7 @@
private final InitialContextInitializer initialContextInitializer;
/**
- * Store of reserved repository names. <tokenname, repositoryname>
+ * Store of reserved repository names. {tokenname, repositoryname}
*/
private final Map<String, String> pendingRepositories = new ConcurrentHashMap<String, String>();
@@ -151,7 +152,7 @@
public Serializable execute(Serializable[] args) throws Throwable
{
String repositoryName = (String)args[0];
- return reserveRepoName(repositoryName);
+ return reserveRepositoryNameLocally(repositoryName);
}
});
@@ -176,7 +177,7 @@
(RepositoryEntry)(getObject(RepositoryEntry.class, stringRepositoryEntry
.getBytes(Constants.DEFAULT_ENCODING)));
- createRepo(backupId, rEntry, rToken);
+ createRepositoryLocally(backupId, rEntry, rToken);
return null;
}
finally
@@ -306,7 +307,7 @@
{
try
{
- createRepo(backupId, rEntry, rToken);
+ createRepositoryLocally(backupId, rEntry, rToken);
}
finally
{
@@ -370,11 +371,11 @@
}
else
{
- return reserveRepoName(repositoryName);
+ return reserveRepositoryNameLocally(repositoryName);
}
}
- protected String reserveRepoName(String repositoryName) throws RepositoryCreationException
+ protected String reserveRepositoryNameLocally(String repositoryName) throws RepositoryCreationException
{
// check does repository already created
try
@@ -407,7 +408,7 @@
}
}
- protected void createRepo(String backupId, RepositoryEntry rEntry, String rToken)
+ protected void createRepositoryLocally(String backupId, RepositoryEntry rEntry, String rToken)
throws RepositoryConfigurationException, RepositoryCreationException
{
// check does token registered
@@ -587,6 +588,10 @@
+ " repository contains already binded datasource " + dbSourceName + ".");
}
}
+ catch (NameNotFoundException e)
+ {
+ // skip this exception
+ }
catch (NamingException e)
{
throw new RepositoryConfigurationException(e.getMessage(), e);
13 years, 5 months
exo-jcr SVN: r3564 - in jcr/branches: 1.14-IMPR and 1 other directory.
by do-not-reply@jboss.org
Author: tolusha
Date: 2010-11-25 09:51:27 -0500 (Thu, 25 Nov 2010)
New Revision: 3564
Added:
jcr/branches/1.14-IMPR/
jcr/branches/1.14-IMPR/pom.xml
Removed:
jcr/branches/1.14-IMPR/pom.xml
Log:
[maven-release-plugin] copy for branch 1.14-IMPR
Copied: jcr/branches/1.14-IMPR (from rev 3560, jcr/tags/1.14.0-Beta02)
Deleted: jcr/branches/1.14-IMPR/pom.xml
===================================================================
--- jcr/tags/1.14.0-Beta02/pom.xml 2010-11-25 13:33:35 UTC (rev 3560)
+++ jcr/branches/1.14-IMPR/pom.xml 2010-11-25 14:51:27 UTC (rev 3564)
@@ -1,471 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
- Copyright (C) 2009 eXo Platform SAS.
-
- This is free software; you can redistribute it and/or modify it
- under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of
- the License, or (at your option) any later version.
-
- This software is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with this software; if not, write to the Free
- Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-
--->
-<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/maven-v4_0_0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <groupId>org.exoplatform</groupId>
- <artifactId>foundation-parent</artifactId>
- <version>7</version>
- </parent>
-
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>jcr-parent</artifactId>
- <version>1.14.0-Beta02</version>
- <packaging>pom</packaging>
- <name>eXo JCR</name>
-
- <scm>
- <connection>scm:svn:http://anonsvn.jboss.org/repos/exo-jcr/jcr/branches/1.14-CNK</connection>
- <developerConnection>scm:svn:https://svn.jboss.org/repos/exo-jcr/jcr/branches/1.14-CNK</developerConnection>
- <url>http://fisheye.jboss.org/browse/exo-jcr/jcr/branches/1.14-CNK</url>
- </scm>
-
- <properties>
- <exo.product.name>exo-jcr</exo.product.name>
- <exo.product.specification>1.14</exo.product.specification>
- <org.exoplatform.kernel.version>2.3.0-Beta02</org.exoplatform.kernel.version>
- <org.exoplatform.core.version>2.4.0-Beta02</org.exoplatform.core.version>
- <org.exoplatform.ws.version>2.2.0-Beta02</org.exoplatform.ws.version>
- <org.exoplatform.doc-style.version>1</org.exoplatform.doc-style.version>
- </properties>
-
- <dependencyManagement>
- <dependencies>
- <dependency>
- <groupId>org.exoplatform.kernel</groupId>
- <artifactId>exo.kernel.commons</artifactId>
- <version>${org.exoplatform.kernel.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.kernel</groupId>
- <artifactId>exo.kernel.commons.test</artifactId>
- <version>${org.exoplatform.kernel.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.kernel</groupId>
- <artifactId>exo.kernel.component.command</artifactId>
- <version>${org.exoplatform.kernel.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.kernel</groupId>
- <artifactId>exo.kernel.container</artifactId>
- <version>${org.exoplatform.kernel.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.kernel</groupId>
- <artifactId>exo.kernel.component.common</artifactId>
- <version>${org.exoplatform.kernel.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.kernel</groupId>
- <artifactId>exo.kernel.component.cache</artifactId>
- <version>${org.exoplatform.kernel.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.core</groupId>
- <artifactId>exo.core.component.document</artifactId>
- <version>${org.exoplatform.core.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.core</groupId>
- <artifactId>exo.core.component.organization.api</artifactId>
- <version>${org.exoplatform.core.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.core</groupId>
- <artifactId>exo.core.component.security.core</artifactId>
- <version>${org.exoplatform.core.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.core</groupId>
- <artifactId>exo.core.component.script.groovy</artifactId>
- <version>${org.exoplatform.core.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.ws</groupId>
- <artifactId>exo.ws.rest.core</artifactId>
- <version>${org.exoplatform.ws.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.ws</groupId>
- <artifactId>exo.ws.rest.ext</artifactId>
- <version>${org.exoplatform.ws.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.ws</groupId>
- <artifactId>exo.ws.commons</artifactId>
- <version>${org.exoplatform.ws.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.ws</groupId>
- <artifactId>exo.ws.frameworks.json</artifactId>
- <version>${org.exoplatform.ws.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.ws</groupId>
- <artifactId>exo.ws.frameworks.servlet</artifactId>
- <version>${org.exoplatform.ws.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.component.ext</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.component.core</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.framework.command</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.component.ftp</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.component.webdav</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.framework.web</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.framework.ftpclient</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.cluster.testclient</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.applications.fckeditor</artifactId>
- <version>${project.version}</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.applications.browser</artifactId>
- <version>${project.version}</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.applications.rest</artifactId>
- <version>${project.version}</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>org.exoplatform.jcr</groupId>
- <artifactId>exo.jcr.connectors.localadapter</artifactId>
- <type>rar</type>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>commons-lang</groupId>
- <artifactId>commons-lang</artifactId>
- <version>2.4</version>
- </dependency>
- <dependency>
- <groupId>commons-chain</groupId>
- <artifactId>commons-chain</artifactId>
- <version>1.0</version>
- </dependency>
- <dependency>
- <groupId>org.jibx</groupId>
- <artifactId>jibx-run</artifactId>
- <version>1.2.1</version>
- </dependency>
- <dependency>
- <groupId>picocontainer</groupId>
- <artifactId>picocontainer</artifactId>
- <version>1.1</version>
- </dependency>
- <dependency>
- <groupId>xml-apis</groupId>
- <artifactId>xml-apis</artifactId>
- <version>1.0.b2</version>
- </dependency>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-api</artifactId>
- <version>1.5.8</version>
- </dependency>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j12</artifactId>
- <version>1.5.8</version>
- </dependency>
- <dependency>
- <groupId>stax</groupId>
- <artifactId>stax-api</artifactId>
- <version>1.0.1</version>
- </dependency>
- <dependency>
- <groupId>javax.jcr</groupId>
- <artifactId>jcr</artifactId>
- <version>1.0</version>
- </dependency>
- <dependency>
- <groupId>javax.servlet</groupId>
- <artifactId>servlet-api</artifactId>
- <version>2.4</version>
- </dependency>
- <dependency>
- <groupId>javax.annotation</groupId>
- <artifactId>jsr250-api</artifactId>
- <version>1.0</version>
- </dependency>
- <dependency>
- <groupId>javax.ws.rs</groupId>
- <artifactId>jsr311-api</artifactId>
- <version>1.0</version>
- </dependency>
- <dependency>
- <groupId>javax.transaction</groupId>
- <artifactId>jta</artifactId>
- <version>1.0.1B</version>
- </dependency>
- <dependency>
- <groupId>javax.resource</groupId>
- <artifactId>connector-api</artifactId>
- <version>1.5</version>
- </dependency>
- <dependency>
- <groupId>jtidy</groupId>
- <artifactId>jtidy</artifactId>
- <version>4aug2000r7-dev</version>
- </dependency>
- <dependency>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-core</artifactId>
- <version>2.4.1</version>
- </dependency>
- <dependency>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-spellchecker</artifactId>
- <version>2.4.1</version>
- </dependency>
- <dependency>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-memory</artifactId>
- <version>2.4.1</version>
- </dependency>
- <dependency>
- <groupId>com.sun.xml.stream</groupId>
- <artifactId>sjsxp</artifactId>
- <version>1.0</version>
- </dependency>
- <dependency>
- <groupId>commons-dbcp</groupId>
- <artifactId>commons-dbcp</artifactId>
- <version>1.2.2</version>
- <exclusions>
- <exclusion>
- <groupId>commons-pool</groupId>
- <artifactId>commons-pool</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
- <dependency>
- <groupId>commons-pool</groupId>
- <artifactId>commons-pool</artifactId>
- <version>1.5.4</version>
- </dependency>
- <dependency>
- <groupId>commons-beanutils</groupId>
- <artifactId>commons-beanutils</artifactId>
- <version>1.8.0</version>
- </dependency>
- <dependency>
- <groupId>commons-logging</groupId>
- <artifactId>commons-logging</artifactId>
- <version>1.1</version>
- </dependency>
- <dependency>
- <groupId>javax.xml.stream</groupId>
- <artifactId>stax-api</artifactId>
- <version>1.0</version>
- </dependency>
- <dependency>
- <groupId>xpp3</groupId>
- <artifactId>xpp3</artifactId>
- <version>1.1.3.4.O</version>
- </dependency>
- <dependency>
- <groupId>concurrent</groupId>
- <artifactId>concurrent</artifactId>
- <version>1.3.4</version>
- </dependency>
- <dependency>
- <groupId>commons-collections</groupId>
- <artifactId>commons-collections</artifactId>
- <version>3.2</version>
- </dependency>
- <dependency>
- <groupId>org.apache.ws.commons</groupId>
- <artifactId>ws-commons-util</artifactId>
- <version>1.0.1</version>
- </dependency>
- <dependency>
- <groupId>org.apache.jackrabbit</groupId>
- <artifactId>jackrabbit-jcr-tests</artifactId>
- <version>1.6.0</version>
- <classifier>sources</classifier>
- </dependency>
- <dependency>
- <groupId>hsqldb</groupId>
- <artifactId>hsqldb</artifactId>
- <version>1.8.0.7</version>
- </dependency>
- <dependency>
- <groupId>jgroups</groupId>
- <artifactId>jgroups</artifactId>
- <version>2.6.13.GA</version>
- </dependency>
- <dependency>
- <groupId>commons-fileupload</groupId>
- <artifactId>commons-fileupload</artifactId>
- <version>1.2.1</version>
- </dependency>
- <dependency>
- <groupId>com.sun.xml.bind</groupId>
- <artifactId>jaxb-impl</artifactId>
- <version>2.1.7</version>
- </dependency>
- <dependency>
- <groupId>javax.resource</groupId>
- <artifactId>connector</artifactId>
- <version>1.5</version>
- </dependency>
- <dependency>
- <groupId>commons-io</groupId>
- <artifactId>commons-io</artifactId>
- <version>1.3</version>
- </dependency>
- <dependency>
- <groupId>org.jboss.cache</groupId>
- <artifactId>jbosscache-core</artifactId>
- <version>3.2.6.GA</version>
- </dependency>
- <dependency>
- <groupId>jboss.jbossts</groupId>
- <artifactId>jbossjts</artifactId>
- <version>4.6.1.GA</version>
- </dependency>
- <dependency>
- <groupId>jboss.jbossts</groupId>
- <artifactId>jbossts-common</artifactId>
- <version>4.6.1.GA</version>
- </dependency>
- <dependency>
- <groupId>org.aspectj</groupId>
- <artifactId>aspectjrt</artifactId>
- <version>1.6.8</version>
- </dependency>
- </dependencies>
- </dependencyManagement>
- <dependencies>
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j12</artifactId>
- <scope>test</scope>
- </dependency>
- </dependencies>
- <build>
- <resources>
- <resource>
- <directory>src/main/java</directory>
- <includes>
- <include>**/*.xml</include>
- <include>**/*.xsl</include>
- <include>**/*.properties</include>
- <include>**/*.ion</include>
- <include>**/*.conf</include>
- <include>**/*.config</include>
- </includes>
- </resource>
- <resource>
- <directory>src/main/resources</directory>
- <includes>
- <include>**/*.xml</include>
- <include>**/*.xsl</include>
- <include>**/*.properties</include>
- <include>**/login.conf</include>
- <include>**/*.ion</include>
- <include>**/*.conf</include>
- <include>**/*.config</include>
- </includes>
- </resource>
- </resources>
- <testResources>
- <testResource>
- <directory>src/test/java</directory>
- <includes>
- <include>**/*.properties</include>
- <include>**/*.xml</include>
- <include>**/*.txt</include>
- <include>**/*.conf</include>
- <include>**/*.config</include>
- </includes>
- </testResource>
- <testResource>
- <directory>src/test/resources</directory>
- <includes>
- <include>**/*.properties</include>
- <include>**/*.xml</include>
- <include>**/*.txt</include>
- <include>**/*.conf</include>
- <include>**/*.config</include>
- </includes>
- </testResource>
- </testResources>
- </build>
- <modules>
- <module>exo.jcr.component.core</module>
- <module>exo.jcr.component.statistics</module>
- <module>exo.jcr.component.ext</module>
- <module>exo.jcr.component.ftp</module>
- <module>exo.jcr.component.webdav</module>
- <module>exo.jcr.connectors.localadapter</module>
- <module>exo.jcr.framework.command</module>
- <module>exo.jcr.framework.web</module>
- <module>exo.jcr.framework.ftpclient</module>
- <module>applications</module>
- <module>exo.jcr.docs</module>
- <module>packaging/module</module>
- </modules>
-</project>
Copied: jcr/branches/1.14-IMPR/pom.xml (from rev 3563, jcr/tags/1.14.0-Beta02/pom.xml)
===================================================================
--- jcr/branches/1.14-IMPR/pom.xml (rev 0)
+++ jcr/branches/1.14-IMPR/pom.xml 2010-11-25 14:51:27 UTC (rev 3564)
@@ -0,0 +1,471 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ This is free software; you can redistribute it and/or modify it
+ under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of
+ the License, or (at your option) any later version.
+
+ This software is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this software; if not, write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+
+-->
+<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/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.exoplatform</groupId>
+ <artifactId>foundation-parent</artifactId>
+ <version>7</version>
+ </parent>
+
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>jcr-parent</artifactId>
+ <version>1.14.0-Beta02</version>
+ <packaging>pom</packaging>
+ <name>eXo JCR</name>
+
+ <scm>
+ <connection>scm:svn:http://anonsvn.jboss.org/repos/exo-jcr/jcr/branches/1.14-IMPR</connection>
+ <developerConnection>scm:svn:https://svn.jboss.org/repos/exo-jcr/jcr/branches/1.14-IMPR</developerConnection>
+ <url>http://fisheye.jboss.org/browse/exo-jcr/jcr/branches/1.14-IMPR</url>
+ </scm>
+
+ <properties>
+ <exo.product.name>exo-jcr</exo.product.name>
+ <exo.product.specification>1.14</exo.product.specification>
+ <org.exoplatform.kernel.version>2.3.0-Beta02</org.exoplatform.kernel.version>
+ <org.exoplatform.core.version>2.4.0-Beta02</org.exoplatform.core.version>
+ <org.exoplatform.ws.version>2.2.0-Beta02</org.exoplatform.ws.version>
+ <org.exoplatform.doc-style.version>1</org.exoplatform.doc-style.version>
+ </properties>
+
+ <dependencyManagement>
+ <dependencies>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.commons</artifactId>
+ <version>${org.exoplatform.kernel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.commons.test</artifactId>
+ <version>${org.exoplatform.kernel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.component.command</artifactId>
+ <version>${org.exoplatform.kernel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.container</artifactId>
+ <version>${org.exoplatform.kernel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.component.common</artifactId>
+ <version>${org.exoplatform.kernel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.component.cache</artifactId>
+ <version>${org.exoplatform.kernel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.core</groupId>
+ <artifactId>exo.core.component.document</artifactId>
+ <version>${org.exoplatform.core.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.core</groupId>
+ <artifactId>exo.core.component.organization.api</artifactId>
+ <version>${org.exoplatform.core.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.core</groupId>
+ <artifactId>exo.core.component.security.core</artifactId>
+ <version>${org.exoplatform.core.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.core</groupId>
+ <artifactId>exo.core.component.script.groovy</artifactId>
+ <version>${org.exoplatform.core.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.rest.core</artifactId>
+ <version>${org.exoplatform.ws.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.rest.ext</artifactId>
+ <version>${org.exoplatform.ws.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.commons</artifactId>
+ <version>${org.exoplatform.ws.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.frameworks.json</artifactId>
+ <version>${org.exoplatform.ws.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.frameworks.servlet</artifactId>
+ <version>${org.exoplatform.ws.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.ext</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.core</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.framework.command</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.ftp</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.webdav</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.framework.web</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.framework.ftpclient</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.cluster.testclient</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.applications.fckeditor</artifactId>
+ <version>${project.version}</version>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.applications.browser</artifactId>
+ <version>${project.version}</version>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.applications.rest</artifactId>
+ <version>${project.version}</version>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.connectors.localadapter</artifactId>
+ <type>rar</type>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>2.4</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-chain</groupId>
+ <artifactId>commons-chain</artifactId>
+ <version>1.0</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jibx</groupId>
+ <artifactId>jibx-run</artifactId>
+ <version>1.2.1</version>
+ </dependency>
+ <dependency>
+ <groupId>picocontainer</groupId>
+ <artifactId>picocontainer</artifactId>
+ <version>1.1</version>
+ </dependency>
+ <dependency>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ <version>1.0.b2</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ <version>1.5.8</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <version>1.5.8</version>
+ </dependency>
+ <dependency>
+ <groupId>stax</groupId>
+ <artifactId>stax-api</artifactId>
+ <version>1.0.1</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.jcr</groupId>
+ <artifactId>jcr</artifactId>
+ <version>1.0</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <version>2.4</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.annotation</groupId>
+ <artifactId>jsr250-api</artifactId>
+ <version>1.0</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.ws.rs</groupId>
+ <artifactId>jsr311-api</artifactId>
+ <version>1.0</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.transaction</groupId>
+ <artifactId>jta</artifactId>
+ <version>1.0.1B</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.resource</groupId>
+ <artifactId>connector-api</artifactId>
+ <version>1.5</version>
+ </dependency>
+ <dependency>
+ <groupId>jtidy</groupId>
+ <artifactId>jtidy</artifactId>
+ <version>4aug2000r7-dev</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-core</artifactId>
+ <version>2.4.1</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-spellchecker</artifactId>
+ <version>2.4.1</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-memory</artifactId>
+ <version>2.4.1</version>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.xml.stream</groupId>
+ <artifactId>sjsxp</artifactId>
+ <version>1.0</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-dbcp</groupId>
+ <artifactId>commons-dbcp</artifactId>
+ <version>1.2.2</version>
+ <exclusions>
+ <exclusion>
+ <groupId>commons-pool</groupId>
+ <artifactId>commons-pool</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>commons-pool</groupId>
+ <artifactId>commons-pool</artifactId>
+ <version>1.5.4</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-beanutils</groupId>
+ <artifactId>commons-beanutils</artifactId>
+ <version>1.8.0</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ <version>1.1</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.xml.stream</groupId>
+ <artifactId>stax-api</artifactId>
+ <version>1.0</version>
+ </dependency>
+ <dependency>
+ <groupId>xpp3</groupId>
+ <artifactId>xpp3</artifactId>
+ <version>1.1.3.4.O</version>
+ </dependency>
+ <dependency>
+ <groupId>concurrent</groupId>
+ <artifactId>concurrent</artifactId>
+ <version>1.3.4</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ <version>3.2</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons</groupId>
+ <artifactId>ws-commons-util</artifactId>
+ <version>1.0.1</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.jackrabbit</groupId>
+ <artifactId>jackrabbit-jcr-tests</artifactId>
+ <version>1.6.0</version>
+ <classifier>sources</classifier>
+ </dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <version>1.8.0.7</version>
+ </dependency>
+ <dependency>
+ <groupId>jgroups</groupId>
+ <artifactId>jgroups</artifactId>
+ <version>2.6.13.GA</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-fileupload</groupId>
+ <artifactId>commons-fileupload</artifactId>
+ <version>1.2.1</version>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.xml.bind</groupId>
+ <artifactId>jaxb-impl</artifactId>
+ <version>2.1.7</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.resource</groupId>
+ <artifactId>connector</artifactId>
+ <version>1.5</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <version>1.3</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.cache</groupId>
+ <artifactId>jbosscache-core</artifactId>
+ <version>3.2.6.GA</version>
+ </dependency>
+ <dependency>
+ <groupId>jboss.jbossts</groupId>
+ <artifactId>jbossjts</artifactId>
+ <version>4.6.1.GA</version>
+ </dependency>
+ <dependency>
+ <groupId>jboss.jbossts</groupId>
+ <artifactId>jbossts-common</artifactId>
+ <version>4.6.1.GA</version>
+ </dependency>
+ <dependency>
+ <groupId>org.aspectj</groupId>
+ <artifactId>aspectjrt</artifactId>
+ <version>1.6.8</version>
+ </dependency>
+ </dependencies>
+ </dependencyManagement>
+ <dependencies>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ <build>
+ <resources>
+ <resource>
+ <directory>src/main/java</directory>
+ <includes>
+ <include>**/*.xml</include>
+ <include>**/*.xsl</include>
+ <include>**/*.properties</include>
+ <include>**/*.ion</include>
+ <include>**/*.conf</include>
+ <include>**/*.config</include>
+ </includes>
+ </resource>
+ <resource>
+ <directory>src/main/resources</directory>
+ <includes>
+ <include>**/*.xml</include>
+ <include>**/*.xsl</include>
+ <include>**/*.properties</include>
+ <include>**/login.conf</include>
+ <include>**/*.ion</include>
+ <include>**/*.conf</include>
+ <include>**/*.config</include>
+ </includes>
+ </resource>
+ </resources>
+ <testResources>
+ <testResource>
+ <directory>src/test/java</directory>
+ <includes>
+ <include>**/*.properties</include>
+ <include>**/*.xml</include>
+ <include>**/*.txt</include>
+ <include>**/*.conf</include>
+ <include>**/*.config</include>
+ </includes>
+ </testResource>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <includes>
+ <include>**/*.properties</include>
+ <include>**/*.xml</include>
+ <include>**/*.txt</include>
+ <include>**/*.conf</include>
+ <include>**/*.config</include>
+ </includes>
+ </testResource>
+ </testResources>
+ </build>
+ <modules>
+ <module>exo.jcr.component.core</module>
+ <module>exo.jcr.component.statistics</module>
+ <module>exo.jcr.component.ext</module>
+ <module>exo.jcr.component.ftp</module>
+ <module>exo.jcr.component.webdav</module>
+ <module>exo.jcr.connectors.localadapter</module>
+ <module>exo.jcr.framework.command</module>
+ <module>exo.jcr.framework.web</module>
+ <module>exo.jcr.framework.ftpclient</module>
+ <module>applications</module>
+ <module>exo.jcr.docs</module>
+ <module>packaging/module</module>
+ </modules>
+</project>
13 years, 5 months
exo-jcr SVN: r3562 - in jcr/trunk/applications: exo.jcr.applications.backupconsole.dist and 6 other directories.
by do-not-reply@jboss.org
Author: dkuleshov
Date: 2010-11-25 09:41:22 -0500 (Thu, 25 Nov 2010)
New Revision: 3562
Added:
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/pom.xml
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/
jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties
Modified:
jcr/trunk/applications/pom.xml
Log:
EXOJCR-1076: Backup console binary distribution module added to applications, applications pom.xml modified for consistency
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,56 @@
+echo off
+if %1 NEQ "-u" goto :help
+set user=%2
+set pass=%3
+set auth=%4
+set host=%5
+SHIFT
+SHIFT
+SHIFT
+SHIFT
+SHIFT
+set comm=%*
+
+if %auth% == "-b" set newarg="http://%user%:%pass%@%host% %comm%"
+if %auth% == "-f" set newarg="http://%host%/portal/rest form POST /portal/login?username=%user%&password=%pass% %comm%"
+
+jcrbackup.cmd %newarg%
+
+exit
+:help
+echo " -u <user> <password> <form_of_authentication> <host:port> <command> "
+echo " "
+echo " <form_of_authentication> : -b - is used for basic authentication "
+echo " -f - is used for form authentication "
+echo " "
+echo " <command> : start <repo[/ws]> <backup_dir> [<incr>] "
+echo " stop <backup_id> "
+echo " status <backup_id> "
+echo " restores <repo[/ws]> "
+echo " restore <repo[/ws]> <backup_id> <pathToConfigFile> "
+echo " list [completed] "
+echo " info "
+echo " drop [force-close-session] <repo[/ws]> "
+echo " help "
+echo " "
+echo " start : start backup of repository or workspace "
+echo " stop : stop backup "
+echo " status : information about the current or completed backup by 'backup_id' "
+echo " restores : information about the last restore on specific repository or workspace "
+echo " restore : restore the repository or workspace from specific backup "
+echo " list : information about the current backups (in progress) "
+echo " list completed : information about the completed (ready to restore) backups "
+echo " info : information about the service backup "
+echo " drop : delete the repository or workspace "
+echo " help : print help information about backup console "
+echo " "
+echo " <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace "
+echo " <backup_dir> : path to folder for backup on remote server "
+echo " <backup_id> : the identifier for backup "
+echo " <incr> : incremental job period "
+echo " <pathToConfigFile> : path (local) to repository or workspace configuration "
+echo " force-close-session : close opened sessions on repository or workspace "
+
+
+
+
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,55 @@
+#!/bin/bash
+
+args=("$@")
+
+if [ "$1" != "-u" ]
+then
+echo " -u <user> <password> <form_of_authentication> <host:port> <command> "
+echo " "
+echo " <form_of_authentication> : -b - is used for basic authentication "
+echo " -f - is used for form authentication "
+echo " "
+echo " <command> : start <repo[/ws]> <backup_dir> [<incr>] "
+echo " stop <backup_id> "
+echo " status <backup_id> "
+echo " restores <repo[/ws]> "
+echo " restore <repo[/ws]> <backup_id> <pathToConfigFile> "
+echo " list [completed] "
+echo " info "
+echo " drop [force-close-session] <repo[/ws]> "
+echo " help "
+echo " "
+echo " start : start backup of repository or workspace "
+echo " stop : stop backup "
+echo " status : information about the current or completed backup by 'backup_id' "
+echo " restores : information about the last restore on specific repository or workspace "
+echo " restore : restore the repository or workspace from specific backup "
+echo " list : information about the current backups (in progress) "
+echo " list completed : information about the completed (ready to restore) backups "
+echo " info : information about the service backup "
+echo " drop : delete the repository or workspace "
+echo " help : print help information about backup console "
+echo " "
+echo " <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace "
+echo " <backup_dir> : path to folder for backup on remote server "
+echo " <backup_id> : the identifier for backup "
+echo " <incr> : incremental job period "
+echo " <pathToConfigFile> : path (local) to repository or workspace configuration "
+echo " force-close-session : close opened sessions on repository or workspace "
+exit 1
+fi
+
+user="$2"
+pass="$3"
+host=${5#*"http://"}
+if [ "$4" = "-f" ]
+then
+ newargs="http://$host/portal/rest form POST /portal/login?username=$user&password=$pass ${args[@]:5}"
+else
+ if [ "$4" = "-b" ]
+ then
+ newargs="http://$user:$pass@$host ${args[@]:5}"
+ fi
+fi
+
+./jcrbackup.sh $newargs
Property changes on: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh
___________________________________________________________________
Name: svn:executable
+ *
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1 @@
+java -jar exo.jcr.applications.backupconsole.dist-binary.jar %*
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+java -jar exo.jcr.applications.backupconsole.dist-binary.jar $*
Property changes on: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh
___________________________________________________________________
Name: svn:executable
+ *
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/pom.xml
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/pom.xml (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/pom.xml 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,128 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ This is free software; you can redistribute it and/or modify it
+ under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of
+ the License, or (at your option) any later version.
+
+ This software is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this software; if not, write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+
+-->
+<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/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>jcr-applications-parent</artifactId>
+ <version>1.14.0-CR1-SNAPSHOT</version>
+ </parent>
+ <artifactId>exo.jcr.applications.backupconsole.dist</artifactId>
+ <name>eXo JCR :: Applications :: Backup Console Binary Distribution</name>
+ <properties>
+ <childDelegation>true</childDelegation>
+ <enforcer.skip>true</enforcer.skip>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.applications.backupconsole</artifactId>
+ <version>1.14.0-CR1-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.core</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.ext</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.commons</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.frameworks.json</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.commons</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.container</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jibx</groupId>
+ <artifactId>jibx-run</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.ws.rs</groupId>
+ <artifactId>jsr311-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <scope>runtime</scope>
+ </dependency>
+ <!-- dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency -->
+ </dependencies>
+ <build>
+ <outputDirectory>target</outputDirectory>
+ <plugins>
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>jar-with-dependensies</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <primaryArtifact>false</primaryArtifact>
+ <finalName>${project.artifactId}</finalName>
+ <descriptors>
+ <descriptor>${basedir}/src/main/assemblies/binary-assembly.xml</descriptor>
+ </descriptors>
+ <archive>
+ <manifest>
+ <addClasspath>true</addClasspath>
+ <classpathPrefix>/</classpathPrefix>
+ <mainClass>org.exoplatform.jcr.backupconsole.BackupConsole</mainClass>
+ </manifest>
+ </archive>
+ </configuration>
+ </execution>
+ <execution>
+ <id>bundle</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>${basedir}/src/main/assemblies/zip-bundle-assembly.xml</descriptor>
+ </descriptors>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,73 @@
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ This is free software; you can redistribute it and/or modify it
+ under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of
+ the License, or (at your option) any later version.
+
+ This software is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this software; if not, write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+
+-->
+<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
+ <id>binary</id>
+ <formats>
+ <format>jar</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <dependencySets>
+ <dependencySet>
+ <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
+ <outputDirectory>/</outputDirectory>
+ <unpack>true</unpack>
+ <useProjectArtifact>false</useProjectArtifact>
+ <scope>compile</scope>
+ <useTransitiveDependencies>false</useTransitiveDependencies>
+ </dependencySet>
+ <dependencySet>
+ <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
+ <outputDirectory>/</outputDirectory>
+ <unpack>true</unpack>
+ <scope>test</scope>
+ <includes>
+ <include>org.slf4j:slf4j-log4j12</include>
+ </includes>
+ <useTransitiveDependencies>false</useTransitiveDependencies>
+ </dependencySet>
+ <dependencySet>
+ <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
+ <outputDirectory>/</outputDirectory>
+ <unpack>true</unpack>
+ <!-- useTransitiveDependencies>true</useTransitiveDependencies -->
+ <!-- useTransitiveFiltering>true</useTransitiveFiltering -->
+ <includes>
+ <!-- eXo Deserializer deps -->
+ <include>picocontainer:picocontainer</include>
+ <!-- eXo logging deps -->
+ <include>org.slf4j:*</include>
+ <include>log4j:log4j</include>
+ <include>commons-logging:commons-logging</include>
+ <!-- runtime deps of exo.ws.commons -->
+ <include>javax.xml.stream:stax-api</include>
+ <include>xpp3:xpp3</include>
+ </includes>
+ </dependencySet>
+ </dependencySets>
+ <fileSets>
+ <fileSet>
+ <directory>${basedir}/src/main/resources</directory>
+ <outputDirectory>/</outputDirectory>
+ </fileSet>
+ </fileSets>
+</assembly>
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,49 @@
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ This is free software; you can redistribute it and/or modify it
+ under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of
+ the License, or (at your option) any later version.
+
+ This software is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this software; if not, write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+
+-->
+<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
+ <id>bundle</id>
+ <formats>
+ <format>zip</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <files>
+ <file>
+ <source>target/${project.artifactId}-binary.jar</source>
+ <destName>${project.artifactId}-binary.jar</destName>
+ </file>
+ <file>
+ <source>${basedir}/src/main/doc/readme.txt</source>
+ <destName>readme.txt</destName>
+ </file>
+ </files>
+ <fileSets>
+ <fileSet>
+ <directory>${basedir}/bin</directory>
+ <outputDirectory>/</outputDirectory>
+ <includes>
+ <include>*.cmd</include>
+ <include>*.sh</include>
+ </includes>
+ </fileSet>
+ </fileSets>
+</assembly>
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,76 @@
+jcrbackup.cmd and jcrbackup.sh - suitable for Standalone and flexible for various authentication ways shell scripts
+
+ <url_basic_authentication> | <url_form_authentication> <command>
+
+ <url_basic_authentication>: http(s)//login:password@host:port/<context>
+ <url_form_authentication> : http(s)//host:port/<context> <form_auth_parm>
+
+ <form_auth_part> : form <method> <form_path>
+ <method> : POST or GET
+ <form_path> : /path/path?<paramName1>=<paramValue1>&<paramName2>=<paramValue2>...
+
+ Example of <url_form_authentication> - http://127.0.0.1:8080/portal/rest form POST "/portal/login?username=root&password=gtn"
+
+ <command> : start <repo[/ws]> <backup_dir> [<incr>]
+ stop <backup_id>
+ status <backup_id>
+ restores <repo[/ws]>
+ restore <repo[/ws]> <backup_id> <pathToConfigFile>
+ list [completed]
+ info
+ drop [force-close-session] <repo[/ws]>
+ help
+
+ start : start backup of repository or workspace
+ stop : stop backup
+ status : information about the current or completed backup by 'backup_id'
+ restores : information about the last restore on specific repository or workspace
+ restore : restore the repository or workspace from specific backup
+ list : information about the current backups (in progress)
+ list completed : information about the completed (ready to restore) backups
+ info : information about the service backup
+ drop : delete the repository or workspace
+ help : print help information about backup console
+
+ <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace
+ <backup_dir> : path to folder for backup on remote server
+ <backup_id> : the identifier for backup
+ <incr> : incremental job period
+ <pathToConfigFile> : path (local) to repository or workspace configuration
+ force-close-session : close opened sessions on repository or workspace
+
+
+exobackup.sh and exobackup.cmd - suitable for use with GateIn based products like Platform
+
+ -u <user> <password> <form_of_authentication> <host:port> <command>
+
+ <form_of_authentication> : -b - is used for basic authentication
+ -f - is used for form authentication
+
+ <command> : start <repo[/ws]> <backup_dir> [<incr>]
+ stop <backup_id>
+ status <backup_id>
+ restores <repo[/ws]>
+ restore <repo[/ws]> <backup_id> <pathToConfigFile>
+ list [completed]
+ info
+ drop [force-close-session] <repo[/ws]>
+ help
+
+ start : start backup of repository or workspace
+ stop : stop backup
+ status : information about the current or completed backup by 'backup_id'
+ restores : information about the last restore on specific repository or workspace
+ restore : restore the repository or workspace from specific backup
+ list : information about the current backups (in progress)
+ list completed : information about the completed (ready to restore) backups
+ info : information about the service backup
+ drop : delete the repository or workspace
+ help : print help information about backup console
+
+ <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace
+ <backup_dir> : path to folder for backup on remote server
+ <backup_id> : the identifier for backup
+ <incr> : incremental job period
+ <pathToConfigFile> : path (local) to repository or workspace configuration
+ force-close-session : close opened sessions on repository or workspace
Added: jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties
===================================================================
--- jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties (rev 0)
+++ jcr/trunk/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties 2010-11-25 14:41:22 UTC (rev 3562)
@@ -0,0 +1,25 @@
+# Set root logger level to DEBUG and its only appender to A1.
+#log4j.rootLogger=INFO, file
+#log4j.rootLogger=DEBUG, file
+#log4j.rootLogger=DEBUG, stdout, file
+log4j.rootLogger=ERROR, stdout, file
+
+#log4j.logger.org.apache.jackrabbit.test=DEBUG
+#log4j.logger.org.exoplatform=DEBUG
+log4j.logger.org.hibernate=ERROR
+
+# 'stdout' is set to be a ConsoleAppender.
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+
+# 'stdout' uses PatternLayout
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{dd.MM.yyyy HH:mm:ss} *%-5p* [%t] %c{1}: %m (%F, line %L)\n
+
+# 'file' is set to be a FileAppender.
+log4j.appender.file=org.apache.log4j.FileAppender
+#log4j.appender.file.File=jcr.log
+log4j.appender.file.File=nul
+
+# 'file' uses PatternLayout.
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{dd.MM.yyyy HH:mm:ss} *%-5p* [%t] %c{1}: %m (%F, line %L)\n
Modified: jcr/trunk/applications/pom.xml
===================================================================
--- jcr/trunk/applications/pom.xml 2010-11-25 14:33:17 UTC (rev 3561)
+++ jcr/trunk/applications/pom.xml 2010-11-25 14:41:22 UTC (rev 3562)
@@ -36,6 +36,7 @@
<modules>
<module>exo.jcr.cluster.testclient</module>
<module>exo.jcr.applications.backupconsole</module>
+ <module>exo.jcr.applications.backupconsole.dist</module>
<module>exo.jcr.applications.browser</module>
<module>exo.jcr.applications.config</module>
<module>exo.jcr.applications.fckeditor</module>
13 years, 5 months
exo-jcr SVN: r3561 - in jcr/branches/1.12.x/applications: exo.jcr.applications.backupconsole.dist and 6 other directories.
by do-not-reply@jboss.org
Author: dkuleshov
Date: 2010-11-25 09:33:17 -0500 (Thu, 25 Nov 2010)
New Revision: 3561
Added:
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/pom.xml
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/
jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties
Modified:
jcr/branches/1.12.x/applications/pom.xml
Log:
JCR-1499: Backup console binary distribution module added to applications, applications pom.xml changed for consistency
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.cmd 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,56 @@
+echo off
+if %1 NEQ "-u" goto :help
+set user=%2
+set pass=%3
+set auth=%4
+set host=%5
+SHIFT
+SHIFT
+SHIFT
+SHIFT
+SHIFT
+set comm=%*
+
+if %auth% == "-b" set newarg="http://%user%:%pass%@%host% %comm%"
+if %auth% == "-f" set newarg="http://%host%/portal/rest form POST /portal/login?username=%user%&password=%pass% %comm%"
+
+jcrbackup.cmd %newarg%
+
+exit
+:help
+echo " -u <user> <password> <form_of_authentication> <host:port> <command> "
+echo " "
+echo " <form_of_authentication> : -b - is used for basic authentication "
+echo " -f - is used for form authentication "
+echo " "
+echo " <command> : start <repo[/ws]> <backup_dir> [<incr>] "
+echo " stop <backup_id> "
+echo " status <backup_id> "
+echo " restores <repo[/ws]> "
+echo " restore <repo[/ws]> <backup_id> <pathToConfigFile> "
+echo " list [completed] "
+echo " info "
+echo " drop [force-close-session] <repo[/ws]> "
+echo " help "
+echo " "
+echo " start : start backup of repository or workspace "
+echo " stop : stop backup "
+echo " status : information about the current or completed backup by 'backup_id' "
+echo " restores : information about the last restore on specific repository or workspace "
+echo " restore : restore the repository or workspace from specific backup "
+echo " list : information about the current backups (in progress) "
+echo " list completed : information about the completed (ready to restore) backups "
+echo " info : information about the service backup "
+echo " drop : delete the repository or workspace "
+echo " help : print help information about backup console "
+echo " "
+echo " <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace "
+echo " <backup_dir> : path to folder for backup on remote server "
+echo " <backup_id> : the identifier for backup "
+echo " <incr> : incremental job period "
+echo " <pathToConfigFile> : path (local) to repository or workspace configuration "
+echo " force-close-session : close opened sessions on repository or workspace "
+
+
+
+
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,55 @@
+#!/bin/bash
+
+args=("$@")
+
+if [ "$1" != "-u" ]
+then
+echo " -u <user> <password> <form_of_authentication> <host:port> <command> "
+echo " "
+echo " <form_of_authentication> : -b - is used for basic authentication "
+echo " -f - is used for form authentication "
+echo " "
+echo " <command> : start <repo[/ws]> <backup_dir> [<incr>] "
+echo " stop <backup_id> "
+echo " status <backup_id> "
+echo " restores <repo[/ws]> "
+echo " restore <repo[/ws]> <backup_id> <pathToConfigFile> "
+echo " list [completed] "
+echo " info "
+echo " drop [force-close-session] <repo[/ws]> "
+echo " help "
+echo " "
+echo " start : start backup of repository or workspace "
+echo " stop : stop backup "
+echo " status : information about the current or completed backup by 'backup_id' "
+echo " restores : information about the last restore on specific repository or workspace "
+echo " restore : restore the repository or workspace from specific backup "
+echo " list : information about the current backups (in progress) "
+echo " list completed : information about the completed (ready to restore) backups "
+echo " info : information about the service backup "
+echo " drop : delete the repository or workspace "
+echo " help : print help information about backup console "
+echo " "
+echo " <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace "
+echo " <backup_dir> : path to folder for backup on remote server "
+echo " <backup_id> : the identifier for backup "
+echo " <incr> : incremental job period "
+echo " <pathToConfigFile> : path (local) to repository or workspace configuration "
+echo " force-close-session : close opened sessions on repository or workspace "
+exit 1
+fi
+
+user="$2"
+pass="$3"
+host=${5#*"http://"}
+if [ "$4" = "-f" ]
+then
+ newargs="http://$host/portal/rest form POST /portal/login?username=$user&password=$pass ${args[@]:5}"
+else
+ if [ "$4" = "-b" ]
+ then
+ newargs="http://$user:$pass@$host ${args[@]:5}"
+ fi
+fi
+
+./jcrbackup.sh $newargs
Property changes on: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/exobackup.sh
___________________________________________________________________
Name: svn:executable
+ *
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.cmd 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1 @@
+java -jar exo.jcr.applications.backupconsole.dist-binary.jar %*
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+java -jar exo.jcr.applications.backupconsole.dist-binary.jar $*
Property changes on: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/bin/jcrbackup.sh
___________________________________________________________________
Name: svn:executable
+ *
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/pom.xml
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/pom.xml (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/pom.xml 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,128 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ This is free software; you can redistribute it and/or modify it
+ under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of
+ the License, or (at your option) any later version.
+
+ This software is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this software; if not, write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+
+-->
+<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/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>jcr-applications-parent</artifactId>
+ <version>1.12.6-GA-SNAPSHOT</version>
+ </parent>
+ <artifactId>exo.jcr.applications.backupconsole.dist</artifactId>
+ <name>eXo JCR :: Applications :: Backup Console Binary Distribution</name>
+ <properties>
+ <childDelegation>true</childDelegation>
+ <enforcer.skip>true</enforcer.skip>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.applications.backupconsole</artifactId>
+ <version>1.12.6-GA-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.core</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.jcr</groupId>
+ <artifactId>exo.jcr.component.ext</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.commons</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.ws</groupId>
+ <artifactId>exo.ws.frameworks.json</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.commons</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.exoplatform.kernel</groupId>
+ <artifactId>exo.kernel.container</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jibx</groupId>
+ <artifactId>jibx-run</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.ws.rs</groupId>
+ <artifactId>jsr311-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <scope>runtime</scope>
+ </dependency>
+ <!-- dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency -->
+ </dependencies>
+ <build>
+ <outputDirectory>target</outputDirectory>
+ <plugins>
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>jar-with-dependensies</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <primaryArtifact>false</primaryArtifact>
+ <finalName>${project.artifactId}</finalName>
+ <descriptors>
+ <descriptor>${basedir}/src/main/assemblies/binary-assembly.xml</descriptor>
+ </descriptors>
+ <archive>
+ <manifest>
+ <addClasspath>true</addClasspath>
+ <classpathPrefix>/</classpathPrefix>
+ <mainClass>org.exoplatform.jcr.backupconsole.BackupConsole</mainClass>
+ </manifest>
+ </archive>
+ </configuration>
+ </execution>
+ <execution>
+ <id>bundle</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>${basedir}/src/main/assemblies/zip-bundle-assembly.xml</descriptor>
+ </descriptors>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/binary-assembly.xml 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,73 @@
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ This is free software; you can redistribute it and/or modify it
+ under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of
+ the License, or (at your option) any later version.
+
+ This software is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this software; if not, write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+
+-->
+<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
+ <id>binary</id>
+ <formats>
+ <format>jar</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <dependencySets>
+ <dependencySet>
+ <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
+ <outputDirectory>/</outputDirectory>
+ <unpack>true</unpack>
+ <useProjectArtifact>false</useProjectArtifact>
+ <scope>compile</scope>
+ <useTransitiveDependencies>false</useTransitiveDependencies>
+ </dependencySet>
+ <dependencySet>
+ <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
+ <outputDirectory>/</outputDirectory>
+ <unpack>true</unpack>
+ <scope>test</scope>
+ <includes>
+ <include>org.slf4j:slf4j-log4j12</include>
+ </includes>
+ <useTransitiveDependencies>false</useTransitiveDependencies>
+ </dependencySet>
+ <dependencySet>
+ <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
+ <outputDirectory>/</outputDirectory>
+ <unpack>true</unpack>
+ <!-- useTransitiveDependencies>true</useTransitiveDependencies -->
+ <!-- useTransitiveFiltering>true</useTransitiveFiltering -->
+ <includes>
+ <!-- eXo Deserializer deps -->
+ <include>picocontainer:picocontainer</include>
+ <!-- eXo logging deps -->
+ <include>org.slf4j:*</include>
+ <include>log4j:log4j</include>
+ <include>commons-logging:commons-logging</include>
+ <!-- runtime deps of exo.ws.commons -->
+ <include>javax.xml.stream:stax-api</include>
+ <include>xpp3:xpp3</include>
+ </includes>
+ </dependencySet>
+ </dependencySets>
+ <fileSets>
+ <fileSet>
+ <directory>${basedir}/src/main/resources</directory>
+ <outputDirectory>/</outputDirectory>
+ </fileSet>
+ </fileSets>
+</assembly>
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/assemblies/zip-bundle-assembly.xml 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,49 @@
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ This is free software; you can redistribute it and/or modify it
+ under the terms of the GNU Lesser General Public License as
+ published by the Free Software Foundation; either version 2.1 of
+ the License, or (at your option) any later version.
+
+ This software is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this software; if not, write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+
+-->
+<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
+ <id>bundle</id>
+ <formats>
+ <format>zip</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <files>
+ <file>
+ <source>target/${project.artifactId}-binary.jar</source>
+ <destName>${project.artifactId}-binary.jar</destName>
+ </file>
+ <file>
+ <source>${basedir}/src/main/doc/readme.txt</source>
+ <destName>readme.txt</destName>
+ </file>
+ </files>
+ <fileSets>
+ <fileSet>
+ <directory>${basedir}/bin</directory>
+ <outputDirectory>/</outputDirectory>
+ <includes>
+ <include>*.cmd</include>
+ <include>*.sh</include>
+ </includes>
+ </fileSet>
+ </fileSets>
+</assembly>
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/doc/readme.txt 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,76 @@
+jcrbackup.cmd and jcrbackup.sh - suitable for Standalone and flexible for various authentication ways shell scripts
+
+ <url_basic_authentication> | <url_form_authentication> <command>
+
+ <url_basic_authentication>: http(s)//login:password@host:port/<context>
+ <url_form_authentication> : http(s)//host:port/<context> <form_auth_parm>
+
+ <form_auth_part> : form <method> <form_path>
+ <method> : POST or GET
+ <form_path> : /path/path?<paramName1>=<paramValue1>&<paramName2>=<paramValue2>...
+
+ Example of <url_form_authentication> - http://127.0.0.1:8080/portal/rest form POST "/portal/login?username=root&password=gtn"
+
+ <command> : start <repo[/ws]> <backup_dir> [<incr>]
+ stop <backup_id>
+ status <backup_id>
+ restores <repo[/ws]>
+ restore <repo[/ws]> <backup_id> <pathToConfigFile>
+ list [completed]
+ info
+ drop [force-close-session] <repo[/ws]>
+ help
+
+ start : start backup of repository or workspace
+ stop : stop backup
+ status : information about the current or completed backup by 'backup_id'
+ restores : information about the last restore on specific repository or workspace
+ restore : restore the repository or workspace from specific backup
+ list : information about the current backups (in progress)
+ list completed : information about the completed (ready to restore) backups
+ info : information about the service backup
+ drop : delete the repository or workspace
+ help : print help information about backup console
+
+ <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace
+ <backup_dir> : path to folder for backup on remote server
+ <backup_id> : the identifier for backup
+ <incr> : incremental job period
+ <pathToConfigFile> : path (local) to repository or workspace configuration
+ force-close-session : close opened sessions on repository or workspace
+
+
+exobackup.sh and exobackup.cmd - suitable for use with GateIn based products like Platform
+
+ -u <user> <password> <form_of_authentication> <host:port> <command>
+
+ <form_of_authentication> : -b - is used for basic authentication
+ -f - is used for form authentication
+
+ <command> : start <repo[/ws]> <backup_dir> [<incr>]
+ stop <backup_id>
+ status <backup_id>
+ restores <repo[/ws]>
+ restore <repo[/ws]> <backup_id> <pathToConfigFile>
+ list [completed]
+ info
+ drop [force-close-session] <repo[/ws]>
+ help
+
+ start : start backup of repository or workspace
+ stop : stop backup
+ status : information about the current or completed backup by 'backup_id'
+ restores : information about the last restore on specific repository or workspace
+ restore : restore the repository or workspace from specific backup
+ list : information about the current backups (in progress)
+ list completed : information about the completed (ready to restore) backups
+ info : information about the service backup
+ drop : delete the repository or workspace
+ help : print help information about backup console
+
+ <repo[/ws]> : /<repository-name>[/<workspace-name>] the repository or workspace
+ <backup_dir> : path to folder for backup on remote server
+ <backup_id> : the identifier for backup
+ <incr> : incremental job period
+ <pathToConfigFile> : path (local) to repository or workspace configuration
+ force-close-session : close opened sessions on repository or workspace
Added: jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties
===================================================================
--- jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties (rev 0)
+++ jcr/branches/1.12.x/applications/exo.jcr.applications.backupconsole.dist/src/main/resources/log4j.properties 2010-11-25 14:33:17 UTC (rev 3561)
@@ -0,0 +1,25 @@
+# Set root logger level to DEBUG and its only appender to A1.
+#log4j.rootLogger=INFO, file
+#log4j.rootLogger=DEBUG, file
+#log4j.rootLogger=DEBUG, stdout, file
+log4j.rootLogger=ERROR, stdout, file
+
+#log4j.logger.org.apache.jackrabbit.test=DEBUG
+#log4j.logger.org.exoplatform=DEBUG
+log4j.logger.org.hibernate=ERROR
+
+# 'stdout' is set to be a ConsoleAppender.
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+
+# 'stdout' uses PatternLayout
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{dd.MM.yyyy HH:mm:ss} *%-5p* [%t] %c{1}: %m (%F, line %L)\n
+
+# 'file' is set to be a FileAppender.
+log4j.appender.file=org.apache.log4j.FileAppender
+#log4j.appender.file.File=jcr.log
+log4j.appender.file.File=nul
+
+# 'file' uses PatternLayout.
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{dd.MM.yyyy HH:mm:ss} *%-5p* [%t] %c{1}: %m (%F, line %L)\n
Modified: jcr/branches/1.12.x/applications/pom.xml
===================================================================
--- jcr/branches/1.12.x/applications/pom.xml 2010-11-25 13:33:35 UTC (rev 3560)
+++ jcr/branches/1.12.x/applications/pom.xml 2010-11-25 14:33:17 UTC (rev 3561)
@@ -36,6 +36,7 @@
<modules>
<module>exo.jcr.cluster.testclient</module>
<module>exo.jcr.applications.backupconsole</module>
+ <module>exo.jcr.applications.backupconsole.dist</module>
<module>exo.jcr.applications.browser</module>
<module>exo.jcr.applications.config</module>
<module>exo.jcr.applications.fckeditor</module>
13 years, 5 months
exo-jcr SVN: r3560 - ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl.
by do-not-reply@jboss.org
Author: aparfonov
Date: 2010-11-25 08:33:35 -0500 (Thu, 25 Nov 2010)
New Revision: 3560
Modified:
ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java
Log:
EXOJCR-1079
Modified: ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java
===================================================================
--- ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java 2010-11-25 13:31:31 UTC (rev 3559)
+++ ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java 2010-11-25 13:33:35 UTC (rev 3560)
@@ -427,10 +427,8 @@
else if (ExceptionMapperComponentPlugin.class.isAssignableFrom(plugin.getClass()))
{
Set<Class<? extends ExceptionMapper<?>>> emaps = ((ExceptionMapperComponentPlugin)plugin).getExceptionMappers();
- for (Class<? extends ExceptionMapper<?>> mapper : emaps){
+ for (Class<? extends ExceptionMapper<?>> mapper : emaps)
providers.addExceptionMapper(mapper);
-System.out.println("\n>>>>>>>>>>>>>>>>> ADD <<<<<<<<<<<<<<<<<\n\n");
- }
}
}
13 years, 5 months
exo-jcr SVN: r3559 - in ws/trunk: exo.ws.rest.core/src/test/resources/conf/standalone and 1 other directories.
by do-not-reply@jboss.org
Author: aparfonov
Date: 2010-11-25 08:31:31 -0500 (Thu, 25 Nov 2010)
New Revision: 3559
Added:
ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/ExceptionMapperComponentPlugin.java
Modified:
ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java
ws/trunk/exo.ws.rest.core/src/test/resources/conf/standalone/test-configuration.xml
ws/trunk/exo.ws.rest.ext/src/test/resources/conf/standalone/test-configuration.xml
Log:
EXOJCR-1079
Added: ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/ExceptionMapperComponentPlugin.java
===================================================================
--- ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/ExceptionMapperComponentPlugin.java (rev 0)
+++ ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/ExceptionMapperComponentPlugin.java 2010-11-25 13:31:31 UTC (rev 3559)
@@ -0,0 +1,80 @@
+/**
+ * Copyright (C) 2010 eXo Platform SAS.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.exoplatform.services.rest.impl;
+
+import org.exoplatform.container.component.BaseComponentPlugin;
+import org.exoplatform.container.xml.InitParams;
+import org.exoplatform.container.xml.ValueParam;
+import org.exoplatform.services.log.ExoLogger;
+import org.exoplatform.services.log.Log;
+import org.exoplatform.services.rest.method.MethodInvokerFilter;
+
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.Set;
+
+import javax.ws.rs.ext.ExceptionMapper;
+
+/**
+ * @author <a href="mailto:andrew00x@gmail.com">Andrey Parfonov</a>
+ * @version $Id$
+ */
+public class ExceptionMapperComponentPlugin extends BaseComponentPlugin
+{
+ /** Logger. */
+ private static final Log LOG = ExoLogger.getLogger("exo.ws.rest.core.ExceptionMapperComponentPlugin");
+
+ /** List of {@link MethodInvokerFilter}. */
+ private Set<Class<? extends ExceptionMapper<?>>> emaps = new HashSet<Class<? extends ExceptionMapper<?>>>();
+
+ /**
+ * @param params initialize parameters from configuration
+ * @see InitParams
+ */
+ @SuppressWarnings("unchecked")
+ public ExceptionMapperComponentPlugin(InitParams params)
+ {
+ if (params != null)
+ {
+ Iterator<ValueParam> i = params.getValueParamIterator();
+ while (i.hasNext())
+ {
+ ValueParam v = i.next();
+ try
+ {
+ emaps.add((Class<? extends ExceptionMapper<?>>)Class.forName(v.getValue()));
+ }
+ catch (ClassNotFoundException e)
+ {
+ LOG.error("Failed load class " + v.getValue(), e);
+ }
+ }
+ }
+ }
+
+ /**
+ * @return get collection of classes ExceptionMapper supplied from
+ * configuration
+ */
+ public Set<Class<? extends ExceptionMapper<?>>> getExceptionMappers()
+ {
+ return emaps;
+ }
+}
Property changes on: ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/ExceptionMapperComponentPlugin.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Modified: ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java
===================================================================
--- ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java 2010-11-25 13:19:34 UTC (rev 3558)
+++ ws/trunk/exo.ws.rest.core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java 2010-11-25 13:31:31 UTC (rev 3559)
@@ -52,8 +52,8 @@
import javax.ws.rs.WebApplicationException;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
+import javax.ws.rs.core.StreamingOutput;
import javax.ws.rs.core.Response.ResponseBuilder;
-import javax.ws.rs.core.StreamingOutput;
import javax.ws.rs.ext.ExceptionMapper;
/**
@@ -424,6 +424,14 @@
for (Class<? extends ResponseFilter> filter : filters)
providers.addResponseFilter(filter);
}
+ else if (ExceptionMapperComponentPlugin.class.isAssignableFrom(plugin.getClass()))
+ {
+ Set<Class<? extends ExceptionMapper<?>>> emaps = ((ExceptionMapperComponentPlugin)plugin).getExceptionMappers();
+ for (Class<? extends ExceptionMapper<?>> mapper : emaps){
+ providers.addExceptionMapper(mapper);
+System.out.println("\n>>>>>>>>>>>>>>>>> ADD <<<<<<<<<<<<<<<<<\n\n");
+ }
+ }
}
}
Modified: ws/trunk/exo.ws.rest.core/src/test/resources/conf/standalone/test-configuration.xml
===================================================================
--- ws/trunk/exo.ws.rest.core/src/test/resources/conf/standalone/test-configuration.xml 2010-11-25 13:19:34 UTC (rev 3558)
+++ ws/trunk/exo.ws.rest.core/src/test/resources/conf/standalone/test-configuration.xml 2010-11-25 13:31:31 UTC (rev 3559)
@@ -149,5 +149,18 @@
</init-params>
-->
</component-plugin>
+ <component-plugin>
+ <name>ws.rs.exception.mapper</name>
+ <set-method>addPlugin</set-method>
+ <type>org.exoplatform.services.rest.impl.ExceptionMapperComponentPlugin</type>
+ <!--
+ <init-params>
+ <value-param>
+ <name>name</name>
+ <value>mapper name</value>
+ </value-param>
+ </init-params>
+ -->
+ </component-plugin>
</external-component-plugins>
</configuration>
Modified: ws/trunk/exo.ws.rest.ext/src/test/resources/conf/standalone/test-configuration.xml
===================================================================
--- ws/trunk/exo.ws.rest.ext/src/test/resources/conf/standalone/test-configuration.xml 2010-11-25 13:19:34 UTC (rev 3558)
+++ ws/trunk/exo.ws.rest.ext/src/test/resources/conf/standalone/test-configuration.xml 2010-11-25 13:31:31 UTC (rev 3559)
@@ -72,13 +72,7 @@
<set-method>addPlugin</set-method>
<type>org.exoplatform.services.rest.impl.provider.JAXBContextComponentPlugin</type>
<init-params>
- <!-- ======== example ======= -->
<value-param>
- <name>book</name>
- <value>org.exoplatform.services.rest.generated.Book</value>
- </value-param>
- <!-- ======================== -->
- <value-param>
<name>wadl.application</name>
<value>org.exoplatform.services.rest.wadl.research.Application</value>
</value-param>
13 years, 5 months