Projet

Général

Profil

« Précédent | Suivant » 

Révision 96454bcd

Ajouté par Sylvain Sauvage il y a plus de 11 ans

Version 1.9-mock

This is version 1.9-mock. 1.9 because the API still have changes pending
(principally relative to the Discovery Services). “mock” because TLS
configuration is not yet available and the signatures (SigMa) are not fully
implemented.

  • All:
    - code cleaned and refactored
    - lots of bugs fixed
    - dependencies checked and trimmed
    - documentation added
    - Identity handling added
  • New library modules (Mu, Nu)
  • New signature modules (SigMa)
  • Access Layer and User interfaces (ALfA and OMeGa):
    - code refactored
    - new, better APIs
    - Identity handling added
    - use EPCglobal and DS events (no proxy types anymore)
  • New tempororay DSeTa web service (pending new DS)
  • ETa corrected and added to the IoTa-Installer
    - ETa-Callback modules are now available as web applications
    - filtering rules: if a part of an event is not allowed, now the whole
    event is deleted from the result (before only the rejectd part was)
  • CaPPa: overall refactoring of XACML handling
    - new temporary User web service
    - new Xi module: XACML Interrogation web service (was two modules: TCP and
    servlet)
  • PSi now signs its events
  • Installer, now also installs or configures:
    - ETa and its Callback modules
    - ActiveMQ
    - SigMa
    - certificate/signing key
  • Greyc letters figures:
    - new simplified figures (sans IoTa and simplified IoTa)
    - new figure for ETa modules
    - show 3rd party clients
    - data flows specified
    - TLS and link security added
    - IDs and trusted IDs added
    - color adjusted for printing
    - GREYC logo added

Voir les différences:

ETa/ETa/src/main/java/fr/unicaen/iota/eta/query/QueryOperationsWebService.java
/*
* This program is a part of the IoTa Project.
*
* Copyright © 2008-2012 Université de Caen Basse-Normandie, GREYC
* Copyright © 2011-2012 Université de Caen Basse-Normandie, GREYC
* Copyright © 2011 Orange Labs
* Copyright © 2007 ETH Zurich
*
......
* See AUTHORS for a list of contributors.
*/
/*
* Copied org.fosstrak.epcis.repository.query.QueryOperationsWebService
* Derived from org.fosstrak.epcis.repository.query.QueryOperationsWebService
*/
package fr.unicaen.iota.eta.query;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.fosstrak.epcis.model.*;
import org.fosstrak.epcis.repository.EpcisQueryControlInterface;
import org.fosstrak.epcis.soap.*;
/**
......
* underlying QueryOperationsModule and ensures that any uncaught exception is
* properly catched and wrapped into an ImplementationExceptionResponse.
*/
public class QueryOperationsWebService implements EPCISServicePortType {
public class QueryOperationsWebService extends IDedQueryOperationsWebService implements EPCISServicePortType {
private static final Log LOG = LogFactory.getLog(QueryOperationsWebService.class);
private EpcisQueryControlInterface queryModule;
public QueryOperationsWebService() {
super();
}
public QueryOperationsWebService(EpcisQueryControlInterface queryModule) {
this.queryModule = queryModule;
public QueryOperationsWebService(QueryOperationsModule queryModule) {
super(queryModule);
}
/**
......
@Override
public ArrayOfString getSubscriptionIDs(GetSubscriptionIDs req) throws ImplementationExceptionResponse,
SecurityExceptionResponse, ValidationExceptionResponse, NoSuchNameExceptionResponse {
ArrayOfString aos = new ArrayOfString();
aos.getString().addAll(queryModule.getSubscriptionIDs(req.getQueryName()));
return aos;
return iDedGetSubscriptionIDs(req, anonymous);
}
/**
......
public QueryResults poll(Poll poll) throws ImplementationExceptionResponse, QueryTooComplexExceptionResponse,
QueryTooLargeExceptionResponse, SecurityExceptionResponse, ValidationExceptionResponse,
NoSuchNameExceptionResponse, QueryParameterExceptionResponse {
// log and wrap any error that is not one of the expected exceptions
try {
return queryModule.poll(poll.getQueryName(), poll.getParams());
} catch (ImplementationExceptionResponse e) {
throw e;
} catch (QueryTooComplexExceptionResponse e) {
throw e;
} catch (QueryTooLargeExceptionResponse e) {
throw e;
} catch (SecurityExceptionResponse e) {
throw e;
} catch (ValidationExceptionResponse e) {
throw e;
} catch (NoSuchNameExceptionResponse e) {
throw e;
} catch (QueryParameterExceptionResponse e) {
throw e;
} catch (Exception e) {
String msg = "Unexpected error occurred while processing request";
LOG.error(msg, e);
ImplementationException ie = new ImplementationException();
ie.setReason(msg);
ie.setSeverity(ImplementationExceptionSeverity.ERROR);
if (poll != null) {
ie.setQueryName(poll.getQueryName());
}
throw new ImplementationExceptionResponse(msg, ie, e);
}
return iDedPoll(poll, anonymous);
}
/**
......
ImplementationExceptionResponse, QueryTooComplexExceptionResponse, SecurityExceptionResponse,
InvalidURIExceptionResponse, ValidationExceptionResponse, SubscribeNotPermittedExceptionResponse,
NoSuchNameExceptionResponse, SubscriptionControlsExceptionResponse, QueryParameterExceptionResponse {
// log and wrap any error that is not one of the expected exceptions
try {
queryModule.subscribe(subscribe.getQueryName(), subscribe.getParams(), subscribe.getDest(),
subscribe.getControls(), subscribe.getSubscriptionID());
return new VoidHolder();
} catch (DuplicateSubscriptionExceptionResponse e) {
throw e;
} catch (ImplementationExceptionResponse e) {
throw e;
} catch (QueryTooComplexExceptionResponse e) {
throw e;
} catch (SecurityExceptionResponse e) {
throw e;
} catch (InvalidURIExceptionResponse e) {
throw e;
} catch (ValidationExceptionResponse e) {
throw e;
} catch (SubscribeNotPermittedExceptionResponse e) {
throw e;
} catch (NoSuchNameExceptionResponse e) {
throw e;
} catch (SubscriptionControlsExceptionResponse e) {
throw e;
} catch (QueryParameterExceptionResponse e) {
throw e;
} catch (Exception e) {
String msg = "Unknown error occurred while processing request";
LOG.error(msg, e);
ImplementationException ie = new ImplementationException();
ie.setReason(msg);
ie.setSeverity(ImplementationExceptionSeverity.ERROR);
if (subscribe != null) {
ie.setQueryName(subscribe.getQueryName());
ie.setSubscriptionID(subscribe.getSubscriptionID());
}
throw new ImplementationExceptionResponse(msg, ie, e);
}
return iDedSubscribe(subscribe, anonymous);
}
/**
......
@Override
public VoidHolder unsubscribe(Unsubscribe unsubscribe) throws ImplementationExceptionResponse,
SecurityExceptionResponse, ValidationExceptionResponse, NoSuchSubscriptionExceptionResponse {
// log and wrap any error that is not one of the expected exceptions
try {
queryModule.unsubscribe(unsubscribe.getSubscriptionID());
return new VoidHolder();
} catch (ImplementationExceptionResponse e) {
throw e;
} catch (SecurityExceptionResponse e) {
throw e;
} catch (NoSuchSubscriptionExceptionResponse e) {
throw e;
} catch (Exception e) {
String msg = "Unknown error occurred while processing request";
LOG.error(msg, e);
ImplementationException ie = new ImplementationException();
ie.setReason(msg);
ie.setSeverity(ImplementationExceptionSeverity.ERROR);
if (unsubscribe != null) {
ie.setSubscriptionID(unsubscribe.getSubscriptionID());
}
throw new ImplementationExceptionResponse(msg, ie, e);
}
}
/**
* @return the queryModule
*/
public EpcisQueryControlInterface getQueryModule() {
return queryModule;
}
/**
* @param queryModule the queryModule to set
*/
public void setQueryModule(EpcisQueryControlInterface queryModule) {
this.queryModule = queryModule;
return iDedUnsubscribe(unsubscribe, anonymous);
}
}

Formats disponibles : Unified diff