[asterisk-scf-commits] asterisk-scf/integration/slice.git branch "rtp-ipv6" created.
Commits to the Asterisk SCF project code repositories
asterisk-scf-commits at lists.digium.com
Sun May 8 09:56:48 CDT 2011
branch "rtp-ipv6" has been created
at 941c14fc79f8c2e47957b2db994a9412734a49d0 (commit)
- Log -----------------------------------------------------------------
commit 941c14fc79f8c2e47957b2db994a9412734a49d0
Author: Joshua Colp <jcolp at digium.com>
Date: Sun May 8 11:57:15 2011 -0300
Add support for IPv6.
diff --git a/AsteriskSCF/Media/RTP/MediaRTPIf.ice b/AsteriskSCF/Media/RTP/MediaRTPIf.ice
index b0cee7f..8687f30 100644
--- a/AsteriskSCF/Media/RTP/MediaRTPIf.ice
+++ b/AsteriskSCF/Media/RTP/MediaRTPIf.ice
@@ -43,6 +43,11 @@ module V1
* A sequence of formats that the RTP media service is expected to transport.
*/
AsteriskSCF::Media::V1::FormatSeq formats;
+
+ /**
+ * Whether IPv6 is to be used or not.
+ */
+ bool ipv6 = false;
};
/**
@@ -66,6 +71,13 @@ module V1
};
/**
+ * Exception thrown when an invalid address is passed in.
+ */
+ exception InvalidAddress
+ {
+ };
+
+ /**
* Interface to an RTP stream sink.
*/
interface StreamSinkRTP extends AsteriskSCF::Media::V1::StreamSink
@@ -73,11 +85,13 @@ module V1
/**
* Method which changes the IP address and port that media will be sent to.
*
- * @param address A string representation of the IP address.
+ * @param address A string representation of the address.
*
* @param port An integer containing the port.
+ *
+ * @throws InvalidAddress when the address passed in is invalid.
*/
- void setRemoteDetails(string address, int port);
+ void setRemoteDetails(string address, int port) throws InvalidAddress;
/**
* Method which retrieves the remote IP address.
@@ -146,11 +160,11 @@ module V1
/**
* Method which creates a new RTP session and returns a proxy to it.
*
- * @param formats The media formats the session is expected to carry.
+ * @param params Parameters to configure the RTP session with.
*
* @return RTPSession* A proxy to the new RTP session.
*/
- RTPSession* allocate(AsteriskSCF::Media::V1::FormatSeq formats);
+ RTPSession* allocate(RTPServiceLocatorParams params);
};
}; /* end module V1 */
commit c06dbbefb20ab2f3bb3b2fbdf1eb714d304af928
Author: David M. Lee <dlee at digium.com>
Date: Fri May 6 11:16:25 2011 -0500
More long-instead-of-int changes.
ints weren't large enough to hold size_t for 64-bit systems.
diff --git a/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice b/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
index 1d2d978..e3081ec 100644
--- a/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
+++ b/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
@@ -78,7 +78,7 @@ module V1
* that are still executing work but are marked for destruction as soon as they
* finish.
*/
- void stateChanged(Pool tpool, int activeThreads, int idleThreads, int zombieThreads);
+ void stateChanged(Pool tpool, long activeThreads, long idleThreads, long zombieThreads);
/**
* Indicates that the Pool's queue has had work added to it.
commit 1580f446b72d71abf9d49ec938d4b58e96d65792
Merge: 98b9c73 1443edd
Author: Mark Michelson <mmichelson at digium.com>
Date: Fri May 6 11:07:55 2011 -0500
Merge branch 'master' of git.asterisk.org:asterisk-scf/release/slice
commit 98b9c735d7af93117d6320c5df05d200659f5161
Author: Mark Michelson <mmichelson at digium.com>
Date: Fri May 6 11:07:36 2011 -0500
Use long instead of int for sizes of queues.
diff --git a/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice b/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
index c3e9c9f..1d2d978 100644
--- a/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
+++ b/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
@@ -88,7 +88,7 @@ module V1
* @param wasEmpty True if the Queue was empty prior to the addition of
* new Work. False otherwise.
*/
- void queueWorkAdded(Pool tpool, int newWorkCount, bool wasEmpty);
+ void queueWorkAdded(Pool tpool, long newWorkCount, bool wasEmpty);
/**
* Indicates that the Pool's queue is empty
diff --git a/AsteriskSCF/System/WorkQueue/WorkQueueIf.ice b/AsteriskSCF/System/WorkQueue/WorkQueueIf.ice
index d4ad1a3..d5ba6a3 100644
--- a/AsteriskSCF/System/WorkQueue/WorkQueueIf.ice
+++ b/AsteriskSCF/System/WorkQueue/WorkQueueIf.ice
@@ -43,7 +43,7 @@ module V1
* @param wasEmpty True if the queue was empty prior
* to the addition of the work. False otherwise.
*/
- void workAdded(int numNewWork, bool wasEmpty);
+ void workAdded(long numNewWork, bool wasEmpty);
/**
* Indicates that suspended work may be resumed
@@ -134,7 +134,7 @@ module V1
*
* @return The number of Work objects in the Queue
*/
- int getSize();
+ long getSize();
/**
* Set a new QueueListener
@@ -254,7 +254,7 @@ module V1
* @return The number of SuspendableWork objects in the
* SuspendableQueue
*/
- int getSize();
+ long getSize();
/**
* Set a new QueueListener
commit 1443edddb16e1ac462e51a1accbac8f225117356
Author: Ken Hunt <ken.hunt at digium.com>
Date: Mon Dec 20 21:01:23 2010 -0600
- Changes for asynchronous routing support.
- Changes to support replication in routing service.
- Component test interface.
diff --git a/AsteriskSCF/Core/Routing/RoutingIf.ice b/AsteriskSCF/Core/Routing/RoutingIf.ice
index 4dc6993..85ab304 100644
--- a/AsteriskSCF/Core/Routing/RoutingIf.ice
+++ b/AsteriskSCF/Core/Routing/RoutingIf.ice
@@ -18,8 +18,8 @@
#include <AsteriskSCF/Core/Endpoint/EndpointIf.ice>
-module AsteriskSCF
-{
+module AsteriskSCF
+{
module Core
{
@@ -92,8 +92,9 @@ module V1
*
* @throws InvalidParamsException if the destination contains invalid information.
*/
+ ["amd"]
idempotent Endpoint::V1::EndpointSeq lookup(string destination)
- throws DestinationNotFoundException, InvalidParamsException;
+ throws DestinationNotFoundException, InvalidParamsException;
};
@@ -129,7 +130,7 @@ module V1
* @throws InvalidParamsException if any parameters are invalid.
*/
void addEndpointLocator(string id, RegExSeq destinationIdRangeList, EndpointLocator *locator)
- throws LocatorAlreadyRegisteredException, InvalidParamsException;
+ throws LocatorAlreadyRegisteredException, InvalidParamsException;
/**
* Method which unregisters an EndpointLocator.
@@ -153,7 +154,7 @@ module V1
* @throws InvalidParamsException if any parameters are invalid.
*/
void setEndpointLocatorDestinationIds(string id, RegExSeq deviceIdRangeList)
- throws DestinationNotFoundException, InvalidParamsException;
+ throws DestinationNotFoundException, InvalidParamsException;
};
@@ -183,8 +184,8 @@ module V1
*/
enum OperationResult
{
- SUCCESS,
- FAILURE
+ SUCCESS,
+ FAILURE
};
/**
@@ -197,58 +198,58 @@ module V1
*/
interface RoutingEvents
{
- /**
- * Notification that a lookup was attempted.
- *
- * @param destinationId The destination being looked up.
- *
- * @param result Indicates whether or not the attempt was successful.
- */
- void lookupEvent(string destinationId, OperationResult result);
-
- /**
- * Notification that an attempt to add an EndpointLocator was made.
- *
- * @param id The identifier of the EndpointLocator being added.
- *
- * @param destinationIdRangeList A set of regular expressions that define the endpoints available.
- *
- * @param result Indicates whether or not the attempt was successful.
- */
- void addEndpointLocatorEvent(string id, RegExSeq destinationIdRangeList, OperationResult result);
-
- /**
- * Notification that an attempt was made to remove an EndpointLocator.
- *
- * @param id The identifier of the EndpointLocator being removed.
- *
- * @param result Indicates whether or not the attempt was successful.
- */
- void removeEndpointLocatorEvent(string id, OperationResult result);
-
- /**
- * Notification that an attempt was made to modify the range of destinationIds
- * accessible from a given EndpointLocator.
- *
- * @param id The destination being looked up.
- *
- * @param destinationIdRangeList A list of regular expressions to be representative of the new valid ids.
- *
- * @param result Indicates whether or not the attempt was successful.
- */
- void setEndpointLocatorDestinationIdsEvent(string id, RegExSeq destinationIdRangeList, OperationResult result);
-
- /**
- * Called when the EndpointLocator cache has been cleared by an administrative action.
- */
- void clearEndpointLocatorsEvent();
-
- /**
- * Called when an administration operation has set the routing service policy.
- *
- * @param policy The new policy.
- */
- void setPolicyEvent(string policy);
+ /**
+ * Notification that a lookup was attempted.
+ *
+ * @param destinationId The destination being looked up.
+ *
+ * @param result Indicates whether or not the attempt was successful.
+ */
+ void lookupEvent(string destinationId, OperationResult result);
+
+ /**
+ * Notification that an attempt to add an EndpointLocator was made.
+ *
+ * @param id The identifier of the EndpointLocator being added.
+ *
+ * @param destinationIdRangeList A set of regular expressions that define the endpoints available.
+ *
+ * @param result Indicates whether or not the attempt was successful.
+ */
+ void addEndpointLocatorEvent(string id, RegExSeq destinationIdRangeList, EndpointLocator *locator, OperationResult result);
+
+ /**
+ * Notification that an attempt was made to remove an EndpointLocator.
+ *
+ * @param id The identifier of the EndpointLocator being removed.
+ *
+ * @param result Indicates whether or not the attempt was successful.
+ */
+ void removeEndpointLocatorEvent(string id, OperationResult result);
+
+ /**
+ * Notification that an attempt was made to modify the range of destinationIds
+ * accessible from a given EndpointLocator.
+ *
+ * @param id The destination being looked up.
+ *
+ * @param destinationIdRangeList A list of regular expressions to be representative of the new valid ids.
+ *
+ * @param result Indicates whether or not the attempt was successful.
+ */
+ void setEndpointLocatorDestinationIdsEvent(string id, RegExSeq destinationIdRangeList, OperationResult result);
+
+ /**
+ * Called when the EndpointLocator cache has been cleared by an administrative action.
+ */
+ void clearEndpointLocatorsEvent();
+
+ /**
+ * Called when an administration operation has set the routing service policy.
+ *
+ * @param policy The new policy.
+ */
+ void setPolicyEvent(string policy);
};
};
diff --git a/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice b/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
index b8e4d4c..e2629dc 100644
--- a/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
+++ b/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
@@ -62,12 +62,12 @@ module V1
*/
class ResponseCode
{
- /**
- * ISDN cause code @see http://tools.ietf.org/html/rfc3398
- *
- * Default value is normal clearing
- */
- int isdnCode = 34;
+ /**
+ * ISDN cause code @see http://tools.ietf.org/html/rfc3398
+ *
+ * Default value is normal clearing
+ */
+ int isdnCode = 34;
};
/**
@@ -80,51 +80,51 @@ module V1
*/
class SessionInfo
{
- /**
- * A proxy to the endpoint that initiated the current session.
- */
- SessionEndpoint* caller;
+ /**
+ * A proxy to the endpoint that initiated the current session.
+ */
+ SessionEndpoint* caller;
- /**
- * The duration of the 'connected' time for this session.
- */
- long connectedTime = 0;
+ /**
+ * The duration of the 'connected' time for this session.
+ */
+ long connectedTime = 0;
- /**
- * A textual description of the current state of the session. For
- * example: pending, connected, hanging up.
- */
- string currentState;
+ /**
+ * A textual description of the current state of the session. For
+ * example: pending, connected, hanging up.
+ */
+ string currentState;
- /**
- * A proxy to the endpoint handling the destination session.
- */
- SessionEndpoint* destination;
+ /**
+ * A proxy to the endpoint handling the destination session.
+ */
+ SessionEndpoint* destination;
- /**
- * A textual description of this Session's role in the
- * current communications.
- */
- string role;
+ /**
+ * A textual description of this Session's role in the
+ * current communications.
+ */
+ string role;
- /**
- * When the session was initiated.
- */
- AsteriskSCF::System::Time::V1::TimeMarker startTime;
+ /**
+ * When the session was initiated.
+ */
+ AsteriskSCF::System::Time::V1::TimeMarker startTime;
};
/**
* Indication visitor class.
*/
["visitor"] local class IndicationVisitor
- {
+ {
};
/**
* Basic indication class. Meant to be extended.
*/
["visitor:IndicationVisitor"] unsliceable class Indication
- {
+ {
};
/**
@@ -286,21 +286,21 @@ module V1
*/
interface Session
{
- /**
- * Registers an instance of SessionListener with the current
- * session.
- *
- * @param listener an instance of a SessionListener object.
- *
- * @return a SessionInfo object containing the current state of the session.
- * This allows "listeners" to be configured with a some initial state
- * to give context to future notifications.
- *
- * @see SessionListener
- *
- * @see SessionInfo
- */
- SessionInfo addListener(SessionListener* listener);
+ /**
+ * Registers an instance of SessionListener with the current
+ * session.
+ *
+ * @param listener an instance of a SessionListener object.
+ *
+ * @return a SessionInfo object containing the current state of the session.
+ * This allows "listeners" to be configured with a some initial state
+ * to give context to future notifications.
+ *
+ * @see SessionListener
+ *
+ * @see SessionInfo
+ */
+ SessionInfo addListener(SessionListener* listener);
/**
* Request that an indication be performed on a session.
@@ -315,83 +315,83 @@ module V1
*/
void indicate(Indication event) throws IndicationException;
- /**
- * Method which retrieves a proxy to the endpoint object that created the current session.
- *
- * @return The endpoint object that created the current session.
- *
- * @see SessionEndpoint
- */
- SessionEndpoint* getEndpoint();
-
- /**
- * Method which retrieves information about the current session's state.
- *
- * @return A SessionInfo instance with up to date information.
- *
- * @see SessionInfo
- */
- SessionInfo getInfo();
-
- /**
- * Retrieve a media session instance, if available, for the current session.
- * A media session object may not be available at the time this is called.
- * For example, in SIP before media details are known.
- *
- * @return An AsteriskSCF media session for the current session. May be a
- * nil reference if the media part of the session has not been initialized.
- */
- AsteriskSCF::Media::V1::Session* getMediaSession();
-
- /**
- * Removes a listener from the current list. Once removed, a listener
- * no longer is notified of changes to the session.
- *
- * @param listener A proxy to the listener to the remove.
- */
- void removeListener(SessionListener* listener);
-
- /**
- * Start a session dialogue with a peer.
- */
- void start();
-
- /**
- * End the dialogue with the peer, sending the
- * provided response code if appropriate.
- *
- * @param response Code identifying the reason the dialog stopped.
- */
- void stop(ResponseCode response);
-
- /**
- * Gets the bridge object this Session is associated with.
- *
- * @return A proxy to the bridge the session is presently in.
- *
- * @throws NotBridged if the session is not currently in a bridge.
- */
- Bridge* getBridge() throws NotBridged;
-
- /**
- * Set the Bridge for this session.
- *
- * @param bridge A proxy to the Bridge object this Session should be associated with.
- *
- * @param listener A proxy to the Listener to add to the Session.
- *
- * @return A current copy of the session information.
- */
- SessionInfo setBridge(Bridge* newBridge, SessionListener* listener);
-
- /**
- * Removes this Session from it's associated Bridge.
- *
- * @param listener Removes the specified listener from the Session.
- *
- * @throws NotBridged if the session is not currently in a bridge.
- */
- void removeBridge(SessionListener* listener) throws NotBridged;
+ /**
+ * Method which retrieves a proxy to the endpoint object that created the current session.
+ *
+ * @return The endpoint object that created the current session.
+ *
+ * @see SessionEndpoint
+ */
+ SessionEndpoint* getEndpoint();
+
+ /**
+ * Method which retrieves information about the current session's state.
+ *
+ * @return A SessionInfo instance with up to date information.
+ *
+ * @see SessionInfo
+ */
+ SessionInfo getInfo();
+
+ /**
+ * Retrieve a media session instance, if available, for the current session.
+ * A media session object may not be available at the time this is called.
+ * For example, in SIP before media details are known.
+ *
+ * @return An AsteriskSCF media session for the current session. May be a
+ * nil reference if the media part of the session has not been initialized.
+ */
+ AsteriskSCF::Media::V1::Session* getMediaSession();
+
+ /**
+ * Removes a listener from the current list. Once removed, a listener
+ * no longer is notified of changes to the session.
+ *
+ * @param listener A proxy to the listener to the remove.
+ */
+ void removeListener(SessionListener* listener);
+
+ /**
+ * Start a session dialogue with a peer.
+ */
+ void start();
+
+ /**
+ * End the dialogue with the peer, sending the
+ * provided response code if appropriate.
+ *
+ * @param response Code identifying the reason the dialog stopped.
+ */
+ void stop(ResponseCode response);
+
+ /**
+ * Gets the bridge object this Session is associated with.
+ *
+ * @return A proxy to the bridge the session is presently in.
+ *
+ * @throws NotBridged if the session is not currently in a bridge.
+ */
+ Bridge* getBridge() throws NotBridged;
+
+ /**
+ * Set the Bridge for this session.
+ *
+ * @param bridge A proxy to the Bridge object this Session should be associated with.
+ *
+ * @param listener A proxy to the Listener to add to the Session.
+ *
+ * @return A current copy of the session information.
+ */
+ SessionInfo setBridge(Bridge* newBridge, SessionListener* listener);
+
+ /**
+ * Removes this Session from it's associated Bridge.
+ *
+ * @param listener Removes the specified listener from the Session.
+ *
+ * @throws NotBridged if the session is not currently in a bridge.
+ */
+ void removeBridge(SessionListener* listener) throws NotBridged;
};
/**
@@ -399,10 +399,10 @@ module V1
*/
exception EndpointUnreachableException
{
- /**
- * String containing the destination endpoint that is unreachable.
- */
- string destination;
+ /**
+ * String containing the destination endpoint that is unreachable.
+ */
+ string destination;
};
/**
@@ -411,8 +411,8 @@ module V1
exception SessionCreationException
{
/**
- * String containing the endpoint that could not create the session.
- */
+ * String containing the endpoint that could not create the session.
+ */
string destination;
};
@@ -421,10 +421,10 @@ module V1
*/
exception SourceTerminatedPreBridgingException
{
- /**
- * String containing the endpoint that was terminated.
- */
- string sourceEndpointId;
+ /**
+ * String containing the endpoint that was terminated.
+ */
+ string sourceEndpointId;
};
/**
@@ -433,13 +433,13 @@ module V1
exception BridgingException
{
/**
- * String containing the endpoint of the incoming session.
- */
+ * String containing the endpoint of the incoming session.
+ */
string sourceEndpointId;
/**
- * String containing the endpoint of the outgoing session.
- */
+ * String containing the endpoint of the outgoing session.
+ */
string destination;
};
@@ -461,79 +461,87 @@ module V1
*/
interface SessionRouter
{
- /**
- * Attempts to establish an end-to-end communication between an
- * existing session and destination identified by an address or ID.
- *
- * @param source The initiating session.
- *
- * @param destination The identifier for the destination.
- *
- * @throws DestinationNotFoundException if the given destination could not be found.
- *
- * @throws EndpointUnreachableException if the destination endpoint could not be reached.
- *
- * @throws SessionCreationException if the destination endpoint could not create a session.
- *
- * @throws SourceTerminatedPreBridgingException if the source session was terminated early.
- *
- * @throws BridgingException if the bridge could not be setup properly.
- */
- void routeSession(Session* source, string destination)
- throws AsteriskSCF::Core::Routing::V1::DestinationNotFoundException,
- EndpointUnreachableException, SessionCreationException,
- SourceTerminatedPreBridgingException, BridgingException ;
-
- /**
- * Replace one session in a Bridge with a new
- * session routable by the destination param.
- *
- * @param sessionToReplace The session that is to be replaced in a
- * bridge. The bridge obejct is obtained from the accessor on this
- * proxy.
- *
- * @param destination The identifier for the destination to be added to
- * the bridge in place of sessionToReplace.
- *
- * @throws DestinationNotFoundException if the given destination could not be found.
- *
- * @throws SessionCreationException if the destination endpoint could not create a session.
- *
- * @throws SourceTerminatedPreBridgingException if the source session was terminated early.
- *
- * @throws BridgingException if the bridge could not be setup properly.
- *
- * @throws NotBridged if the provided session is not currently in a bridge.
- */
- void connectBridgedSessionsWithDestination(Session* sessionToReplace, string destination)
- throws AsteriskSCF::Core::Routing::V1::DestinationNotFoundException,
- SessionCreationException,
- SourceTerminatedPreBridgingException, BridgingException, NotBridged ;
-
- /**
- * Replace one session in a Bridge with sessions from another bridge.
- * No routing is actually performed. This operation exists here for consistency,
- * since connectBridgedSessionsWithDestination(...) is implemented by this interface.
- *
- * @param sessionToReplace The session that is to be replaced in a
- * bridge. The bridge obejct associated with this session will survive, and
- * all sessions bridged to this session will be kept in the bridge.
- *
- * @param bridgedSession This session is assumed to be bridged to the sessions
- * that are to be moved to another bridge. The bridgedSession itself will not
- * be connected to the other bridge. The sessions being moved will be removed from
- * their current bridge before being added to the bridge currenltly attached to
- * sessionToReplace.
- *
- *
- * @throws SourceTerminatedPreBridgingException if the source session was terminated early.
- *
- * @throws BridgingException if the bridge could not be setup properly.
- *
- * @throws NotBridged if the session provided in sessionToReplace is not currently in a bridge.
- */
- void connectBridgedSessions(Session* sessionToReplace, Session* bridgedSession)
- throws SourceTerminatedPreBridgingException, BridgingException, NotBridged ;
+ /**
+ * Attempts to establish an end-to-end communication between an
+ * existing session and destination identified by an address or ID.
+ *
+ * @param operationId Unique id for this operation.
+ *
+ * @param source The initiating session.
+ *
+ * @param destination The identifier for the destination.
+ *
+ * @throws DestinationNotFoundException if the given destination could not be found.
+ *
+ * @throws EndpointUnreachableException if the destination endpoint could not be reached.
+ *
+ * @throws SessionCreationException if the destination endpoint could not create a session.
+ *
+ * @throws SourceTerminatedPreBridgingException if the source session was terminated early.
+ *
+ * @throws BridgingException if the bridge could not be setup properly.
+ */
+ ["amd"]
+ void routeSession(string operationId, Session* source, string destination)
+ throws AsteriskSCF::Core::Routing::V1::DestinationNotFoundException,
+ EndpointUnreachableException, SessionCreationException,
+ SourceTerminatedPreBridgingException, BridgingException ;
+
+ /**
+ * Replace one session in a Bridge with a new
+ * session routable by the destination param.
+ *
+ * @param operationId Unique id for this operation.
+ *
+ * @param sessionToReplace The session that is to be replaced in a
+ * bridge. The bridge obejct is obtained from the accessor on this
+ * proxy.
+ *
+ * @param destination The identifier for the destination to be added to
+ * the bridge in place of sessionToReplace.
+ *
+ * @throws DestinationNotFoundException if the given destination could not be found.
+ *
+ * @throws SessionCreationException if the destination endpoint could not create a session.
+ *
+ * @throws SourceTerminatedPreBridgingException if the source session was terminated early.
+ *
+ * @throws BridgingException if the bridge could not be setup properly.
+ *
+ * @throws NotBridged if the provided session is not currently in a bridge.
+ */
+ ["amd"]
+ void connectBridgedSessionsWithDestination(string operationId, Session* sessionToReplace, string destination)
+ throws AsteriskSCF::Core::Routing::V1::DestinationNotFoundException,
+ SessionCreationException,
+ SourceTerminatedPreBridgingException, BridgingException, NotBridged ;
+
+ /**
+ * Replace one session in a Bridge with sessions from another bridge.
+ * No routing is actually performed. This operation exists here for consistency,
+ * since connectBridgedSessionsWithDestination(...) is implemented by this interface.
+ *
+ * @param operationId Unique id for this operation.
+ *
+ * @param sessionToReplace The session that is to be replaced in a
+ * bridge. The bridge obejct associated with this session will survive, and
+ * all sessions bridged to this session will be kept in the bridge.
+ *
+ * @param bridgedSession This session is assumed to be bridged to the sessions
+ * that are to be moved to another bridge. The bridgedSession itself will not
+ * be connected to the other bridge. The sessions being moved will be removed from
+ * their current bridge before being added to the bridge currenltly attached to
+ * sessionToReplace.
+ *
+ * @throws SourceTerminatedPreBridgingException if the source session was terminated early.
+ *
+ * @throws BridgingException if the bridge could not be setup properly.
+ *
+ * @throws NotBridged if the session provided in sessionToReplace is not currently in a bridge.
+ */
+ ["amd"]
+ void connectBridgedSessions(string operationId, Session* sessionToReplace, Session* bridgedSession)
+ throws SourceTerminatedPreBridgingException, BridgingException, NotBridged ;
};
/**
@@ -542,27 +550,27 @@ module V1
*/
interface SessionEndpoint extends AsteriskSCF::Core::Endpoint::V1::BaseEndpoint
{
- /**
- * Creates a session for the specified destination, optionally registering
- * a SessionListener object for notification of changes to the session.
- *
- * @param destination A stringified identifier or address for the destination.
- *
- * @param callback A SessionListener object to be registered as a listener on the
- * newly created session. May be a nil reference if an initial listener is not
- * required.
- *
- * @return A newly created session object for the destination.
- *
- */
- Session* createSession(string destination, SessionListener* callback);
-
- /**
- * Returns the active sessions for this session endpoint.
- *
- * @return a sequence of Session proxies.
- */
- idempotent SessionSeq getSessions();
+ /**
+ * Creates a session for the specified destination, optionally registering
+ * a SessionListener object for notification of changes to the session.
+ *
+ * @param destination A stringified identifier or address for the destination.
+ *
+ * @param callback A SessionListener object to be registered as a listener on the
+ * newly created session. May be a nil reference if an initial listener is not
+ * required.
+ *
+ * @return A newly created session object for the destination.
+ *
+ */
+ Session* createSession(string destination, SessionListener* callback);
+
+ /**
+ * Returns the active sessions for this session endpoint.
+ *
+ * @return a sequence of Session proxies.
+ */
+ idempotent SessionSeq getSessions();
};
/**
@@ -578,7 +586,7 @@ module V1
*/
exception InvalidSessions
{
- Ice::LongSeq indexes;
+ Ice::LongSeq indexes;
};
/**
@@ -606,7 +614,7 @@ module V1
/**
* The bridge throws SessionNotFound exception if a specified session is
* not currently on the bridge.
- **/
+ */
exception SessionNotFound
{
Session* missingSession;
@@ -624,86 +632,86 @@ module V1
interface Bridge
{
/**
- * Add a sequence of session proxies to the bridge. Sessions are started
- * if necessary.
- *
- * @param session A sequence of session proxies.
- *
- * @throws InvalidSessions if any of the provided sessions are invalid.
- *
- * @see Session
- * @see InvalidSessions
- */
+ * Add a sequence of session proxies to the bridge. Sessions are started
+ * if necessary.
+ *
+ * @param session A sequence of session proxies.
+ *
+ * @throws InvalidSessions if any of the provided sessions are invalid.
+ *
+ * @see Session
+ * @see InvalidSessions
+ */
["amd"]
void addSessions(SessionSeq session)
throws InvalidSessions, BridgeSessionOperationFailed;
/**
- * Abruptly destroy the bridge. Sessions will not be stopped.
- */
+ * Abruptly destroy the bridge. Sessions will not be stopped.
+ */
void destroy();
/**
- * List the sessions currently on the bridge.
- *
- * @return a sequence of session proxies participating in the bridge.
- */
+ * List the sessions currently on the bridge.
+ *
+ * @return a sequence of session proxies participating in the bridge.
+ */
idempotent SessionSeq listSessions();
/**
- * Removes one or more sessions from the bridge. Sessions are not stopped
- * as they are removed.
- *
- * @param sessions A sequence of session proxies.
- *
- * @throws InvalidSessions if any of the provided sessions are invalid.
- *
- * @see Session
- * @see InvalidSessions
- */
- ["amd"]
+ * Removes one or more sessions from the bridge. Sessions are not stopped
+ * as they are removed.
+ *
+ * @param sessions A sequence of session proxies.
+ *
+ * @throws InvalidSessions if any of the provided sessions are invalid.
+ *
+ * @see Session
+ * @see InvalidSessions
+ */
+ ["amd"]
void removeSessions(SessionSeq sessions)
throws InvalidSessions, BridgeSessionOperationFailed;
/**
- * Nicely shutdown the bridge. Participating sessions are disconnected.
- */
+ * Nicely shutdown the bridge. Participating sessions are disconnected.
+ */
void shutdown();
/**
- * Adds a listener object to the bridge. The listener will receive notification
- * of future changes to the bridge as they occur.
- *
- * @param listener A reference to a BridgeListener object.
- *
- * @see BridgeListener
- */
+ * Adds a listener object to the bridge. The listener will receive notification
+ * of future changes to the bridge as they occur.
+ *
+ * @param listener A reference to a BridgeListener object.
+ *
+ * @see BridgeListener
+ */
void addListener(BridgeListener* listener);
/**
- * Removes a listener object from the bridge. The listen will cease receiving
- * notifications of changes to the bridge.
- *
- * @param listener A reference to the listener object to be removed.
- *
- * @see BridgeListener
- */
+ * Removes a listener object from the bridge. The listen will cease receiving
+ * notifications of changes to the bridge.
+ *
+ * @param listener A reference to the listener object to be removed.
+ *
+ * @see BridgeListener
+ */
void removeListener(BridgeListener* listener);
/**
- * Replaces a session that is on the bridge with another session. Useful for transfers, etc.
- * where a participant is replaced as part of the code flow.
- *
- * @param sessionToReplace The session being replaced. The bridge associated with this
- * session is used for the newSessions.
- *
- * @param newSessions The sessions to add to the bridge. The sessions are assumed to not
- * be already participating in another bridge.
- *
- * @throws InvalidSessions if any of the provided sessions are invalid.
+ * Replaces a session that is on the bridge with another session. Useful for transfers, etc.
+ * where a participant is replaced as part of the code flow.
+ *
+ * @param sessionToReplace The session being replaced. The bridge associated with this
+ * session is used for the newSessions.
+ *
+ * @param newSessions The sessions to add to the bridge. The sessions are assumed to not
+ * be already participating in another bridge.
+ *
+ * @throws InvalidSessions if any of the provided sessions are invalid.
*
* @throws SessionNotFound if the session to be replaced is not on the bridge.
- */
+ */
["amd"]
void replaceSession(Session* sessionToReplace, SessionSeq newSessions)
throws InvalidSessions, SessionNotFound, BridgeSessionOperationFailed;
@@ -719,36 +727,36 @@ module V1
interface BridgeListener
{
/**
- * Called when sessions have been added to a bridge.
- *
- * @param sessionBridge The bridge object the sessions were added to.
- *
- * @param sessions A sequence of session proxies that were added to the bridge.
- */
+ * Called when sessions have been added to a bridge.
+ *
+ * @param sessionBridge The bridge object the sessions were added to.
+ *
+ * @param sessions A sequence of session proxies that were added to the bridge.
+ */
void sessionsAdded(Bridge* sessionBridge, SessionSeq sessions);
/**
- * Called when sessions have been removed from a bridge.
- *
- * @param sessionBridge The bridge object the sessions were removed from.
- *
- * @param sessions A sequence of session proxies that were removed from
- * the bridge.
- */
+ * Called when sessions have been removed from a bridge.
+ *
+ * @param sessionBridge The bridge object the sessions were removed from.
+ *
+ * @param sessions A sequence of session proxies that were removed from
+ * the bridge.
+ */
void sessionsRemoved(Bridge* sessionBridge, SessionSeq sessions);
/**
- * Called when a bridge has completed shutdown/destruction.
- *
- * @param sessionBridge The bridge that was stopped.
- */
+ * Called when a bridge has completed shutdown/destruction.
+ *
+ * @param sessionBridge The bridge that was stopped.
+ */
void stopped(Bridge* sessionBridge);
/**
- * Called when a bridge has started shutdown/destruction operations.
- *
- * @param sessionBrdige The bridge that is stopping.
- */
+ * Called when a bridge has started shutdown/destruction operations.
+ *
+ * @param sessionBrdige The bridge that is stopping.
+ */
void stopping(Bridge* sessionBridge);
};
@@ -768,66 +776,66 @@ module V1
interface BridgeManager
{
/**
- * Method called to add a listener to the bridge manager.
- *
- * @param listener A proxy to the bridge manager listener to add.
- */
- void addListener(BridgeManagerListener* listener);
-
- /**
- * Method called to create a bridge.
- *
- * @param sessions A sequence of session proxies to be placed into the newly created bridge.
- *
- * @param listener A proxy to a bridge listener to be added to the newly created ridge.
- *
- * @return Bridge* Returns a proxy to the newly created bridge.
- */
+ * Method called to add a listener to the bridge manager.
+ *
+ * @param listener A proxy to the bridge manager listener to add.
+ */
+ void addListener(BridgeManagerListener* listener);
+
+ /**
+ * Method called to create a bridge.
+ *
+ * @param sessions A sequence of session proxies to be placed into the newly created bridge.
+ *
+ * @param listener A proxy to a bridge listener to be added to the newly created ridge.
+ *
+ * @return Bridge* Returns a proxy to the newly created bridge.
+ */
["amd"]
- Bridge* createBridge(SessionSeq sessions, BridgeListener* listener);
+ Bridge* createBridge(SessionSeq sessions, BridgeListener* listener);
- /**
- * Method called to remove a listener from the bridge manager.
- *
- * @param listener A proxy to the bridge manager listener to remove.
- */
- void removeListener(BridgeManagerListener* listener);
+ /**
+ * Method called to remove a listener from the bridge manager.
+ *
+ * @param listener A proxy to the bridge manager listener to remove.
+ */
+ void removeListener(BridgeManagerListener* listener);
/**
* Method called to add a listener to the list of bridge listeners that
* will automatically be added to every bridge that is created.
- *
- * @param listener A proxy to the bridge listener to add.
+ *
+ * @param listener A proxy to the bridge listener to add.
*
* @throws NullProxyException if the listener proxy is a null proxy.
*
- */
+ */
void addDefaultBridgeListener(BridgeListener* listener)
throws AsteriskSCF::System::V1::NullProxyException;
/**
* Method called to remove a listener to the list of bridge listeners that
* will automatically be added to every bridge that is created.
- *
- * @param listener A proxy to the bridge listener to remove.
+ *
+ * @param listener A proxy to the bridge listener to remove.
*
* @throws NullProxyException if the listener proxy is a null proxy.
*
- */
+ */
void removeDefaultBridgeListener(BridgeListener* listener)
throws AsteriskSCF::System::V1::NullProxyException;
- /**
- * Method called to get a list of bridges currently active in the bridge manager.
- *
- * @return BridgeSeq a sequence of proxies to the bridges that are active.
- */
- idempotent BridgeSeq listBridges();
+ /**
+ * Method called to get a list of bridges currently active in the bridge manager.
+ *
+ * @return BridgeSeq a sequence of proxies to the bridges that are active.
+ */
+ idempotent BridgeSeq listBridges();
- /**
- * Method called to shut down the bridge manager.
- */
- void shutdown();
+ /**
+ * Method called to shut down the bridge manager.
+ */
+ void shutdown();
};
/**
@@ -836,88 +844,94 @@ module V1
interface BridgeManagerListener
{
/**
- * Notice that a bridge was created.
- *
- * @param manager A proxy to the bridge manager that created the bridge.
- *
- * @param newBridge A proxy to the newly created bridge.
- */
- void bridgeCreated(BridgeManager* manager, Bridge* newBridge);
-
- /**
- * Notice that a bridge manager has stopped.
- *
- * @param manager The bridge manager that has stopped.
- */
- void stopped(BridgeManager* manager);
-
- /**
- * Notice that a bridge manager is stopping.
- *
- * @param manager The bridge manager that is stopping.
- */
- void stopping(BridgeManager* manager);
+ * Notice that a bridge was created.
+ *
+ * @param manager A proxy to the bridge manager that created the bridge.
+ *
+ * @param newBridge A proxy to the newly created bridge.
+ */
+ void bridgeCreated(BridgeManager* manager, Bridge* newBridge);
+
+ /**
+ * Notice that a bridge manager has stopped.
+ *
+ * @param manager The bridge manager that has stopped.
+ */
+ void stopped(BridgeManager* manager);
+
+ /**
+ * Notice that a bridge manager is stopping.
+ *
+ * @param manager The bridge manager that is stopping.
+ */
+ void stopping(BridgeManager* manager);
};
module Event
{
/**
- * String name of the IceStorm topic used for session router related events.
- */
+ * String name of the IceStorm topic used for session router related events.
+ */
const string TopicId = "::asteriskscf::session::sessionrouter::event";
/**
- * An enum for whether the result of an operation was successful or not
- */
+ * An enum for whether the result of an operation was successful or not
+ */
enum OperationResult
{
- SUCCESS,
- FAILURE
+ SUCCESS,
+ FAILURE
};
/**
- * Interface for monitoring session router events.
- */
+ * Interface for monitoring session router events.
+ */
interface SessionRouterEvents
{
- /**
- * Notice that routeSession operation was called.
- *
- * @param source The initiating session.
- *
- * @param destination The identifier for the destination.
- *
- * @param result Operation outcome.
- */
- void routeSessionEvent(Session* source, string destination, OperationResult result);
-
- /**
- * Notice that connectBridgedSessionsWithDestinationEvent operation was called.
- *
- * @param sessionToReplace The session that is to be replaced in the
- * bridge. The bridge obejct is obtained from the accessor on this
- * proxy.
- *
- * @param destination The identifier for the destination.
- *
- * @param result Operation outcome.
- */
- void connectBridgedSessionsWithDestinationEvent(Session* sessionToReplace, string destination, OperationResult result);
-
- /**
- * Notice that connectBridgedSessionsEvent operation was called.
- *
- * @param sessionToReplace The session that is to be replaced in the
- * bridge. The bridge obejct is obtained from the accessor on this
- * proxy.
- *
- * @param bridgedSession This session is assumed to be bridged to the sessions
- * that are to be moved to another bridge. The bridgedSession itself will not
- * be connected to the other bridge.
- *
- * @param result Operation outcome.
- */
- void connectBridgedSessionsEvent(Session* sessionToReplace, Session* bridgedSession, OperationResult result);
+ /**
+ * Notice that routeSession operation was called.
+ *
+ * @param operationId Unique id for this operation.
+ *
+ * @param source The initiating session.
+ *
+ * @param destination The identifier for the destination.
+ *
+ * @param result Operation outcome.
+ */
+ void routeSessionEvent(string operationId, Session* source, string destination, OperationResult result);
+
+ /**
+ * Notice that connectBridgedSessionsWithDestinationEvent operation was called.
+ *
+ * @param operationId Unique id for this operation.
+ *
+ * @param sessionToReplace The session that is to be replaced in the
+ * bridge. The bridge obejct is obtained from the accessor on this
+ * proxy.
+ *
+ * @param destination The identifier for the destination.
+ *
+ * @param result Operation outcome.
+ */
+ void connectBridgedSessionsWithDestinationEvent(string operationId, Session* sessionToReplace, string destination, OperationResult result);
+
+ /**
+ * Notice that connectBridgedSessionsEvent operation was called.
+ *
+ * @param operationId Unique id for this operation.
+ *
+ * @param sessionToReplace The session that is to be replaced in the
+ * bridge. The bridge obejct is obtained from the accessor on this
+ * proxy.
+ *
+ * @param bridgedSession This session is assumed to be bridged to the sessions
+ * that are to be moved to another bridge. The bridgedSession itself will not
+ * be connected to the other bridge.
+ *
+ * @param result Operation outcome.
+ */
+ void connectBridgedSessionsEvent(string operationId, Session* sessionToReplace, Session* bridgedSession, OperationResult result);
};
}; /* End of module Event */
diff --git a/AsteriskSCF/System/Component/ComponentServiceIf.ice b/AsteriskSCF/System/Component/ComponentServiceIf.ice
index d374e29..b6db122 100644
--- a/AsteriskSCF/System/Component/ComponentServiceIf.ice
+++ b/AsteriskSCF/System/Component/ComponentServiceIf.ice
@@ -17,7 +17,7 @@
#pragma once
module AsteriskSCF
-{
+{
module System
{
@@ -46,39 +46,69 @@ module V1
exception Suspended { };
/**
- * Service is the base interface for all AsteriskSCF services. Most components will include an implementation
+ * This is the base interface for all AsteriskSCF services. Most components will include an implementation
* of this or a derived interface.
*/
- interface ComponentService
- {
- /**
- * Suspends activity in the service. In general this means that the primary activity of a service
- * is suspended. Queries about state etc, may or may not be available. Calling suspend on a service
- * that is suspended should be treated as a no-op.
- *
- * @throws ShuttingDown if the service is in the process of shutting down.
- */
- void suspend() throws ShuttingDown;
-
- /**
- * Resumes a service that has been suspended. After this call returns the suspended service
- * must be ready to handle requests in a manner consistent with its state at the time the service
- * was suspended.
- *
- * @throws ShuttingDown if the service is in the process of shutting down.
- */
- void resume() throws ShuttingDown;
-
- /**
- * Commences a clean shutdown of the services. The details of shutdown are implementation specific.
- * For example, some services will begin to reject requests immediately after being shutdown but
- * resume requests currently being handled. Others might abort requests in progress. A component
- * implementing this interface should indicate if requests will be aborted or not on shutdown.
- *
- * @throws Suspended if the service is suspended.
- */
- void shutdown() throws Suspended;
- };
+ interface ComponentService
+ {
+ /**
+ * Suspends activity in the service. In general this means that the primary activity of a service
+ * is suspended. Queries about state etc, may or may not be available. Calling suspend on a service
+ * that is suspended should be treated as a no-op.
+ *
+ * @throws ShuttingDown if the service is in the process of shutting down.
+ */
+ void suspend() throws ShuttingDown;
+
+ /**
+ * Resumes a service that has been suspended. After this call returns the suspended service
+ * must be ready to handle requests in a manner consistent with its state at the time the service
+ * was suspended.
+ *
+ * @throws ShuttingDown if the service is in the process of shutting down.
+ */
+ void resume() throws ShuttingDown;
+
+ /**
+ * Commences a clean shutdown of the services. The details of shutdown are implementation specific.
+ * For example, some services will begin to reject requests immediately after being shutdown but
+ * resume requests currently being handled. Others might abort requests in progress. A component
+ * implementing this interface should indicate if requests will be aborted or not on shutdown.
+ *
+ * @throws Suspended if the service is suspended.
+ */
+ void shutdown() throws Suspended;
+ };
+
+ /**
+ * A base class to enable arbitary parameter passing to the ComponentTest inteface.
+ */
+ class ComponentTestParam {};
+ sequence<ComponentTestParam> ComponentTestParamSeq;
+
+ const string ComponentTestFacet = "TestFacet";
+
+ /**
+ * This interface is expsed as an optional facet on ComponentService.
+ */
+ interface ComponentTest
+ {
+ /**
+ * Set a test mode. The meaning of the mode is specific
+ * to a given component and it's tests.
+ */
+ void setTestMode(string mode);
+
+ /**
+ * Set a test mode with params. The meaning of the mode and paramters is specific
+ * to a given component and it's tests.
+ */
+ void setTestModeWithArgs(string mode, ComponentTestParamSeq params);
+
+ void clearTestMode(string mode);
+
+ void clearTestModes();
+ };
}; /* End of V1 */
commit db0812c0c896d51c136cb89fa3f7a14ba22ebf31
Author: Kevin P. Fleming <kpfleming at digium.com>
Date: Wed Apr 27 13:54:50 2011 -0500
No need to explicitly request Ice and IceUtil libraries.
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b0d2cb1..fa8dfb6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,8 +6,6 @@ set(API_SLICE_DIR ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
# Make all of our slice definitions available to... themselves!
asterisk_scf_slice_include_directories(${CMAKE_CURRENT_SOURCE_DIR})
-asterisk_scf_add_ice_libraries(Ice IceUtil)
-
asterisk_scf_component_init(asterisk-scf-api)
asterisk_scf_component_add_slice(asterisk-scf-api GLOB_RECURSE "AsteriskSCF/*.ice")
asterisk_scf_component_build_library(asterisk-scf-api)
commit 531f5fd38f97fbc3220f902a979bf172db50fdd2
Author: Kevin P. Fleming <kpfleming at digium.com>
Date: Wed Apr 27 11:10:48 2011 -0500
CMakeLists.txt cleanup across the entire tree.
* Consistent formatting.
* Removed old non-integrated build stuff.
* Organized include_directories() calls since they affect every component in
the directory they are executed in.
* Keep all scripts lines for each component together.
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8d97fc1..b0d2cb1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,27 +1,17 @@
-#
-# Asterisk Scalable Communications Framework
-#
-# Copyright (C) 2010 -- Digium, Inc.
-#
-# All rights reserved.
-#
-
asterisk_scf_project(API 3.4)
-asterisk_scf_component_init(asterisk-scf-api CXX)
+set(API_INCLUDE_DIR ${CMAKE_CURRENT_BINARY_DIR}/generated PARENT_SCOPE)
+set(API_SLICE_DIR ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
# Make all of our slice definitions available to... themselves!
asterisk_scf_slice_include_directories(${CMAKE_CURRENT_SOURCE_DIR})
-asterisk_scf_component_add_slice(asterisk-scf-api
- GLOB_RECURSE "AsteriskSCF/*.ice")
-
asterisk_scf_add_ice_libraries(Ice IceUtil)
-asterisk_scf_component_build_library(asterisk-scf-api)
-
-set(API_INCLUDE_DIR ${CMAKE_CURRENT_BINARY_DIR}/generated PARENT_SCOPE)
-set(API_SLICE_DIR ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
+asterisk_scf_component_init(asterisk-scf-api)
+asterisk_scf_component_add_slice(asterisk-scf-api GLOB_RECURSE "AsteriskSCF/*.ice")
+asterisk_scf_component_build_library(asterisk-scf-api)
asterisk_scf_component_install(asterisk-scf-api)
+
asterisk_scf_slice_headers_install()
asterisk_scf_slice_install(AsteriskSCF)
commit ccc9fef2f724df94c7b313a815eda7dcb43ddcda
Author: Kevin P. Fleming <kpfleming at digium.com>
Date: Mon Apr 25 17:46:21 2011 -0500
Changes to work with new single-build-directory CMake script.
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8f26841..8d97fc1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,6 +6,8 @@
# All rights reserved.
#
+asterisk_scf_project(API 3.4)
+
asterisk_scf_component_init(asterisk-scf-api CXX)
# Make all of our slice definitions available to... themselves!
-----------------------------------------------------------------------
--
asterisk-scf/integration/slice.git
More information about the asterisk-scf-commits
mailing list