Merged from private branch before release 4.3.0

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/vre-management/smart-executor-client@141989 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Luca Frosini 2017-02-01 16:03:51 +00:00
parent 7270cc1e46
commit 185c1397e7
23 changed files with 59 additions and 45 deletions

View File

@ -30,6 +30,7 @@
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
<attribute name="org.eclipse.jst.component.nondependency" value=""/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/classes"/>

View File

@ -5,11 +5,21 @@
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.wst.common.project.facet.core.builder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.wst.validation.validationbuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.m2e.core.maven2Builder</name>
<arguments>
@ -17,7 +27,10 @@
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
<nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>org.eclipse.m2e.core.maven2Nature</nature>
<nature>org.eclipse.wst.common.project.facet.core.nature</nature>
</natures>
</projectDescription>

View File

@ -1,5 +1,8 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.source=1.7

View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
<wb-module deploy-name="smart-executor-client">
<wb-resource deploy-path="/" source-path="/src/main/java"/>
<wb-resource deploy-path="/" source-path="/src/main/resources"/>
</wb-module>
</project-modules>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<faceted-project>
<installed facet="java" version="1.7"/>
<installed facet="jst.utility" version="1.0"/>
</faceted-project>

View File

@ -0,0 +1,2 @@
disabled=06target
eclipse.preferences.version=1

View File

@ -1,7 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xml>
<ReleaseNotes>
<Changeset component="org.gcube.vre-management.smart-executor-client.1.3.0" date="${buildDate}">
<Changeset component="org.gcube.vre-management.smart-executor.1.4.0" date="${buildDate}">
<Change></Change>
</Changeset>
<Changeset component="org.gcube.vre-management.smart-executor-client.1.3.0" date="2016-11-07">
<Change>SmartExecutor has been passed to Authorization 2.0 (refs #4944 #2112)</Change>
<Change>Provided to plugins the possibility to define a custom notifier (refs #5089)</Change>
</Changeset>
<Changeset component="org.gcube.vre-management.smart-executor-client.1.2.0" date="2016-02-08">
<Change>Using Persistence (CouchDB) to save Scheduled Task configuration (refs #579)</Change>
<Change>Added Unscheduling feature for repetitive task (refs #521)</Change>

View File

@ -1,7 +1,5 @@
<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">
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.3 http://maven.apache.org/xsd/assembly-1.1.3.xsd">
<id>servicearchive</id>
<formats>
<format>tar.gz</format>

View File

@ -1,4 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xml>
<Resource>
<ID />
<Type>Service</Type>

View File

@ -10,7 +10,7 @@
<groupId>org.gcube.vremanagement</groupId>
<artifactId>smart-executor-client</artifactId>
<version>1.3.0-SNAPSHOT</version>
<version>1.4.0-SNAPSHOT</version>
<description>Smart Executor Service Client Library</description>
<packaging>jar</packaging>

View File

@ -5,6 +5,9 @@ import javax.xml.namespace.QName;
import org.gcube.common.calls.jaxws.GcubeService;
import org.gcube.vremanagement.executor.api.SmartExecutor;
/**
* @author Luca Frosini (ISTI - CNR)
*/
public class Constants {
/* Must be the same of generated WEB-INF/gcube-app.xml */

View File

@ -5,7 +5,7 @@ import org.gcube.vremanagement.executor.api.SmartExecutor;
import org.gcube.vremanagement.executor.client.Constants;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
* @param <S>
* @param <P>

View File

@ -20,7 +20,7 @@ import org.gcube.vremanagement.executor.client.proxies.SmartExecutorProxy;
import org.gcube.vremanagement.executor.client.util.Tuple;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class ExecutorPlugin extends AbstractPlugin<SmartExecutor, SmartExecutorProxy> {

View File

@ -22,7 +22,7 @@ import org.gcube.vremanagement.executor.client.plugins.query.filter.ServiceEndpo
import org.gcube.vremanagement.executor.client.util.Tuple;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class SmartExecutorPluginQuery implements Query<EndpointReference> {

View File

@ -9,7 +9,7 @@ import org.gcube.common.resources.gcore.ServiceEndpoint;
import org.gcube.resources.discovery.client.queries.api.SimpleQuery;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public interface EndpointDiscoveryFilter {

View File

@ -10,7 +10,7 @@ import org.gcube.resources.discovery.client.queries.api.SimpleQuery;
import org.gcube.vremanagement.executor.client.plugins.query.SmartExecutorPluginQuery;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class ListEndpointDiscoveryFilter implements EndpointDiscoveryFilter {

View File

@ -13,7 +13,7 @@ import org.gcube.resources.discovery.client.queries.api.SimpleQuery;
import org.gcube.vremanagement.executor.client.plugins.query.SmartExecutorPluginQuery;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class RandomEndpointDiscoveryFilter implements EndpointDiscoveryFilter {

View File

@ -6,7 +6,7 @@ package org.gcube.vremanagement.executor.client.plugins.query.filter;
import org.gcube.resources.discovery.client.queries.api.SimpleQuery;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public interface ServiceEndpointQueryFilter {

View File

@ -12,7 +12,7 @@ import org.gcube.resources.discovery.client.queries.api.SimpleQuery;
import org.gcube.vremanagement.executor.client.plugins.query.SmartExecutorPluginQuery;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class SpecificEndpointDiscoveryFilter implements EndpointDiscoveryFilter {

View File

@ -20,7 +20,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*/
public class DefaultSmartExecutorProxy implements SmartExecutorProxy {
@ -92,20 +92,7 @@ public class DefaultSmartExecutorProxy implements SmartExecutorProxy {
@Override
public PluginState getState(final String executionIdentifier)
throws PluginInstanceNotFoundException, ExecutorException {
Call<SmartExecutor, PluginState> call = new Call<SmartExecutor, PluginState>() {
@Override
public PluginState call(SmartExecutor endpoint) throws Exception {
logger.debug("Calling getState(String) function");
return endpoint.getState(executionIdentifier);
}
};
try {
return proxyDelegate.make(call);
} catch (Exception e) {
logger.debug("Failed to call getState(String) function");
throw again(e).asServiceException();
}
return getStateEvolution(executionIdentifier).getPluginState();
}
/** {@inheritDoc} */
@ -135,20 +122,7 @@ public class DefaultSmartExecutorProxy implements SmartExecutorProxy {
@Override
public PluginState getIterationState(final String executionIdentifier, final int iterationNumber)
throws PluginInstanceNotFoundException, ExecutorException {
Call<SmartExecutor, PluginState> call = new Call<SmartExecutor, PluginState>() {
@Override
public PluginState call(SmartExecutor endpoint) throws Exception {
logger.debug("Calling getIterationState(String, int) function");
return endpoint.getIterationState(executionIdentifier, iterationNumber);
}
};
try {
return proxyDelegate.make(call);
} catch (Exception e) {
logger.debug("Failed to call getIterationState(String, int) function");
throw again(e).asServiceException();
}
return getIterationStateEvolution(executionIdentifier, iterationNumber).getPluginState();
}
/** {@inheritDoc} */

View File

@ -6,7 +6,7 @@ package org.gcube.vremanagement.executor.client.proxies;
import org.gcube.vremanagement.executor.api.SmartExecutor;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public interface SmartExecutorProxy extends SmartExecutor {

View File

@ -4,7 +4,7 @@
package org.gcube.vremanagement.executor.client.util;
/**
* @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/
* @author Luca Frosini (ISTI - CNR)
*
*/
public class Tuple<Name,Value> {

View File

@ -1,3 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xml>
<configuration>
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">