diff options
| author | Andrew Branson <andrew.branson@cern.ch> | 2014-10-03 17:30:41 +0200 |
|---|---|---|
| committer | Andrew Branson <andrew.branson@cern.ch> | 2014-10-03 17:30:41 +0200 |
| commit | 275d0bbf555c8917be82ce4cc21eb4cabb00f4c5 (patch) | |
| tree | ddcc6b14077d90d1b970b67829f07120547dbb62 /src/main/idl | |
| parent | a139f95bfeca603333b8c0310ae09c6805e58584 (diff) | |
Huge exception overhaul: Merged ClusterStorageException with
PersistencyException. Replaced MembershipException with
InvalidCollectionModification CORBA Exception. Made all predef steps
throw more accurate exceptions when they go wrong, and let more
exceptions bubble through from underneath.
Diffstat (limited to 'src/main/idl')
| -rw-r--r-- | src/main/idl/CommonExceptions.idl | 31 | ||||
| -rw-r--r-- | src/main/idl/Entity.idl | 26 |
2 files changed, 30 insertions, 27 deletions
diff --git a/src/main/idl/CommonExceptions.idl b/src/main/idl/CommonExceptions.idl index 176b4a9..d5abb1d 100644 --- a/src/main/idl/CommonExceptions.idl +++ b/src/main/idl/CommonExceptions.idl @@ -34,12 +34,12 @@ module common
{
/**************************************************************************
- * Thrown when the directory couldn't be modified during Entity creation, or
- * Role management
+ * Thrown when the process isn't privileged enough to make the requested
+ * change, either because it is a client process, or its management objects
+ * are incorrect.
**************************************************************************/
- exception CannotManageException
+ exception CannotManage
{
- string mDescription;
};
@@ -49,18 +49,24 @@ module common * Most commonly occurs when the Activity is in a different state than the
* caller has assumed.
**************************************************************************/
- exception InvalidTransitionException
+ exception InvalidTransition
+ {
+ };
+
+ /**************************************************************************
+ * The modification to the collection could not be performed, due to rules
+ * within the collection itself.
+ **************************************************************************/
+ exception InvalidCollectionModification
{
- string mDescription;
};
/**************************************************************************
* Either the supplied data, or the relevant description, was invalid.
**************************************************************************/
- exception InvalidDataException
+ exception InvalidData
{
- string mDescription;
};
@@ -69,16 +75,14 @@ module common **************************************************************************/
exception AccessRightsException
{
- string mDescription;
};
/**************************************************************************
* The requested object was not found
**************************************************************************/
- exception ObjectNotFoundException
+ exception ObjectNotFound
{
- string mDescription;
};
@@ -87,15 +91,13 @@ module common **************************************************************************/
exception PersistencyException
{
- string mDescription;
};
/**************************************************************************
* The object already exists.
**************************************************************************/
- exception ObjectAlreadyExistsException
+ exception ObjectAlreadyExists
{
- string mDescription;
};
@@ -104,7 +106,6 @@ module common **************************************************************************/
exception ObjectCannotBeUpdated
{
- string mDescription;
};
}; //end of module common
diff --git a/src/main/idl/Entity.idl b/src/main/idl/Entity.idl index 3348b41..ff0dad3 100644 --- a/src/main/idl/Entity.idl +++ b/src/main/idl/Entity.idl @@ -64,9 +64,10 @@ module entity in string workflow,
in string collections )
raises( common::AccessRightsException,
- common::InvalidDataException,
+ common::InvalidData,
common::PersistencyException,
- common::ObjectNotFoundException );
+ common::ObjectNotFound,
+ common::InvalidCollectionModification );
/**
* Returns a chunk of XML which may be a serialized C2KLocalObject, or in the case of Outcomes is merely a fragment of XML.
@@ -90,7 +91,7 @@ module entity **/
string queryData( in string path )
raises( common::AccessRightsException,
- common::ObjectNotFoundException,
+ common::ObjectNotFound,
common::PersistencyException );
/**
@@ -128,11 +129,12 @@ module entity in string requestData
)
raises( common::AccessRightsException,
- common::InvalidTransitionException,
- common::ObjectNotFoundException,
- common::InvalidDataException,
+ common::InvalidTransition,
+ common::ObjectNotFound,
+ common::InvalidData,
common::PersistencyException,
- common::ObjectAlreadyExistsException );
+ common::ObjectAlreadyExists,
+ common::InvalidCollectionModification);
/**
@@ -150,7 +152,7 @@ module entity string queryLifeCycle( in common::SystemKey agentKey,
in boolean filter )
raises( common::AccessRightsException,
- common::ObjectNotFoundException,
+ common::ObjectNotFound,
common::PersistencyException );
};
@@ -180,16 +182,16 @@ module entity * @throws CannotManageException when an error occurs writing the data to LDAP
**/
void addRole( in string roleName )
- raises( common::ObjectNotFoundException,
- common::CannotManageException );
+ raises( common::ObjectNotFound,
+ common::CannotManage );
/** Remove this Agent from the given role
* @param the role name to remove
* @throws CannotManageException when an error occurs writing the data to LDAP
**/
void removeRole( in string roleName )
- raises( common::ObjectNotFoundException,
- common::CannotManageException );
+ raises( common::ObjectNotFound,
+ common::CannotManage );
};
}; //end of module entity
|
