[asterisk-scf-commits] asterisk-scf/integration/slice.git branch "workqueue" created.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Thu Feb 24 16:52:32 CST 2011


branch "workqueue" has been created
        at  10e5d492b1801ff3c3260fc9aaff5a3676905285 (commit)

- Log -----------------------------------------------------------------
commit 10e5d492b1801ff3c3260fc9aaff5a3676905285
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Thu Feb 24 16:50:51 2011 -0600

    Initial definitions of new interfaces to be used as the standard
    for components needing work queues and thread pools (including
    suspendable work queues, designed for when work items need to be
    restarted after asynchronous operations complete). Wiki documentation
    to come soon...
    
    These were written by Mark Michelson and myself after quite a few hours
    of discussion with Brent Eagles and Ken Hunt. Collaborative design!

diff --git a/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice b/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
new file mode 100644
index 0000000..e4bcd7a
--- /dev/null
+++ b/AsteriskSCF/System/ThreadPool/ThreadPoolIf.ice
@@ -0,0 +1,57 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+#include <AsteriskSCF/System/WorkQueue/WorkQueueIf.ice>
+
+module AsteriskSCF
+{
+
+module System
+{
+
+module ThreadPool
+{
+
+module V1
+{
+    
+    local interface PoolManager
+    {
+	void setPoolSize(int size);
+    };
+
+    local interface PoolListener
+    {
+	void stateChanged(PoolManager manager, int activeThreads, int idleThreads, int zombieThreads);
+	void queueWorkAdded(PoolManager manager, int newWorkCount, bool wasEmpty);
+	void queueEmptied(PoolManager manager);
+    };
+
+    local interface Pool
+    {
+	void setWorkQueue(AsteriskSCF::System::WorkQueue::V1::Queue queue);
+	void setListener(PoolListener listener);
+    };
+
+}; /* End of V1 */
+
+}; /* End of ThreadPool */
+
+}; /* End of System */
+
+}; /* End of AsteriskSCF */
diff --git a/AsteriskSCF/System/WorkQueue/WorkQueueIf.ice b/AsteriskSCF/System/WorkQueue/WorkQueueIf.ice
new file mode 100644
index 0000000..ebd0caa
--- /dev/null
+++ b/AsteriskSCF/System/WorkQueue/WorkQueueIf.ice
@@ -0,0 +1,89 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+module AsteriskSCF
+{
+
+module System
+{
+
+module WorkQueue
+{
+
+module V1
+{
+    
+    local interface QueueListener
+    {
+	void workAdded(bool wasEmpty);
+	void emptied();
+    };
+
+    local interface Work
+    {
+	void execute();
+    };
+
+    local interface Queue
+    {
+	void enqueueWork(Work item);
+	void cancelWork(Work item);
+
+	/* return value indicates whether queue contains more work
+	   that can be executed immediately
+	*/
+	bool executeWork();
+	/* this is a snapshot and should only be used as a hint */
+	int workCount();
+
+        void setListener(QueueListener listener);
+    };
+
+    enum SuspendableWorkResult
+    {
+	Complete,
+	Suspended
+    };
+
+    local interface SuspendableWork
+    {
+	SuspendableWorkResult execute();
+    };
+
+    local interface SuspendableQueue
+    {
+	void enqueueWork(SuspendableWork item);
+	void cancelWork(SuspendableWork item);
+
+	/* return value indicates whether queue contains more work
+	   that can be executed immediately
+	*/
+	bool executeWork();
+	/* this is a snapshot and should only be used as a hint */
+	int workCount();
+
+        void setListener(QueueListener listener);
+    };
+
+}; /* End of V1 */
+
+}; /* End of WorkQueue */
+
+}; /* End of System */
+
+}; /* End of AsteriskSCF */

commit 030aad466eccb71487a7443a99129d6ccd11502d
Author: Joshua Colp <jcolp at digium.com>
Date:   Mon Feb 21 14:05:03 2011 -0400

    Add Configuration interface slice file.

diff --git a/AsteriskSCF/System/Component/ConfigurationIf.ice b/AsteriskSCF/System/Component/ConfigurationIf.ice
new file mode 100644
index 0000000..64397e2
--- /dev/null
+++ b/AsteriskSCF/System/Component/ConfigurationIf.ice
@@ -0,0 +1,170 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2010, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+module AsteriskSCF
+{
+
+module System
+{
+
+module Configuration
+{
+
+["suppress"]
+module V1
+{
+    /**
+     * Generic configuration item class that can be extended by components.
+     *
+     * This essentially represents a single configurable aspect.
+     */
+    ["preserved"]
+    class ConfigurationItem
+    {
+	/**
+	 * Serial number of the configuration item. This number should be incremented each
+	 * time an update is sent to the setConfiguration method on the Configuration interface.
+	 *
+	 * If the serial number is older than is currently presently on the configured item then
+	 * an exception will be thrown indicating that the configured item has already been changed
+	 * from another source.
+	 *
+	 * The serial number check can be disabled by passing a serial number of -1. This will force
+	 * the update to proceed no matter what.
+	 */
+	int serialNumber;
+    };
+
+    /**
+     * A dictionary of configuration items. The key is a string to encourage only having a single
+     * instance of each configuratiom item, and to also provide a value for logging information.
+     */
+    dictionary<string, ConfigurationItem> ConfigurationItemDict;
+
+    /**
+     * Generic configuration group class that can be extended by components.
+     *
+     * This essentially represents a group of configurable items that configure a specific concept.
+     */
+    ["preserved"]
+    class ConfigurationGroup
+    {
+	/**
+	 * Dictionary of configuration items for this group.
+	 */
+	ConfigurationItemDict configurationItems;
+    };
+
+    /**
+     * A sequence of configuration groups.
+     */
+    sequence<ConfigurationGroup> ConfigurationGroupSeq;
+
+    /**
+     * Exception thrown when a configuration item serial number is older than is currently configured.
+     */
+    exception SerialConflict
+    {
+	/**
+	 * The configuration group that the item belongs to. This includes all configuration items so that
+	 * they can all be updated and retried.
+	 */
+	ConfigurationGroup group;
+
+	/**
+	 * The configuration item that the serial conflict applies to.
+	 */
+	ConfigurationItem item;
+    };
+
+   /**
+    * The configuration interface provides methods that allow the manipulation of the configuration
+    * data for a specific component.
+    *
+    * This interface purposely does not provide explicit methods for individual group retrieval
+    * or updating to encourage batching updates which reduces RPCs. This also makes it easier to
+    * implement a transaction approach where a configuration update is an all-or-nothing operation.
+    */
+   interface ConfigurationService
+   {
+       /**
+	* Retrieves a sequence of configuration groups containing the configuration items specified
+	* in the ConfigurationGroup classes in the sequence itself and their current values.
+	*
+	* @param groups A sequence of group classes to be retrieved, along with the configuration items to be retrieved
+	*               in each class.
+	*
+	* @return A sequence of group classes containing the current values of the configuration items requested.
+	*
+	*/
+       idempotent ConfigurationGroupSeq getConfiguration(ConfigurationGroupSeq groups);
+
+       /**
+	* Retrieves a sequence of configuration groups containing all the configuration items and
+	* their current values.
+	*
+	* @param groups A sequence of group classes to be retrieved.
+	*
+	* @return A sequence of group classes containing the current values of the configuration items requested.
+	*
+	*/
+       idempotent ConfigurationGroupSeq getConfigurationAll(ConfigurationGroupSeq groups);
+
+       /**
+	* Retrieves a sequence of current configuration groups. This does not return all the configuration items.
+	* If the configuration items are needed the getConfiguration method must be called afterwards.
+	*
+	* @return A sequence of current configuration groups.
+	*
+	*/
+       idempotent ConfigurationGroupSeq getConfigurationGroups();
+
+       /**
+	* Update the configuration of one or more configuration groups.
+	*
+	* @param groups The groups and configuration items to update (or add).
+	*
+	* @throws SerialConflict when serial number of a configuration item is out of date.
+	*
+	*/
+       idempotent void setConfiguration(ConfigurationGroupSeq groups) throws SerialConflict;
+
+       /**
+	* Remove specific configuration items from a configuration group.
+	*
+	* @param groups The groups or configuration items to remove.
+	*
+	*/
+       void removeConfigurationItems(ConfigurationGroupSeq groups);
+
+       /**
+	* Remove a configuration group and all configuration items.
+	*
+	* @param groups The groups or configuration items to remove.
+	*
+	*/
+       void removeConfigurationGroups(ConfigurationGroupSeq groups);
+    };
+
+}; /* End of namespace V1 */
+
+}; /* End of namespace Configuration */
+
+}; /* End of namespace System */
+
+}; /* End of namespace AsteriskSCF */

commit 3710f1976fa50786ce5d5c5ccf9aa19d01613bf8
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Fri Feb 18 18:07:37 2011 -0600

    Add default values for various class/struct members where it makes sense to provide one.

diff --git a/AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice b/AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice
index e25b6da..49e684a 100644
--- a/AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice
+++ b/AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice
@@ -153,7 +153,7 @@ module V1
       /** managmenet interface for the server */
       ServiceManagement *management;
       /** current status */
-      ServiceStatus status;
+      ServiceStatus status = Active;
       /** the service itself */
       Object *service;
    };
diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
index b0db305..2b85aa2 100644
--- a/AsteriskSCF/SIP/SIPExtensionPointIf.ice
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -154,7 +154,7 @@ module V1
     class MD5DigestChallenge extends DigestChallenge
     {
 	// Indicates whether 'MD5' or 'MD5-sess' should be used
-	bool sessionMode;
+	bool sessionMode = false;
     };
 
     class AKAv1DigestChallenge extends MD5DigestChallenge
diff --git a/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice b/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
index e33311a..01e9c1b 100644
--- a/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
+++ b/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
@@ -86,7 +86,7 @@ module V1
 	/**
 	 * The duration of the 'connected' time for this session.
 	 */
-	long connectedTime;
+	long connectedTime = 0;
 
 	/**
 	 * A textual description of the current state of the session. For
diff --git a/AsteriskSCF/System/Hook/HookIf.ice b/AsteriskSCF/System/Hook/HookIf.ice
index c205a2e..68bd8e0 100644
--- a/AsteriskSCF/System/Hook/HookIf.ice
+++ b/AsteriskSCF/System/Hook/HookIf.ice
@@ -40,7 +40,7 @@ module V1
 
     struct HookResult
     {
-	HookStatus status;
+	HookStatus status = Succeeded;
 	string info;
     };
 

commit 3ecc809e33681d696a75670337140db4d51a8b5b
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Fri Feb 18 16:30:14 2011 -0600

    Add 'visitor' metadata for some additional classes that are intended to be
    subclassed and passed around in collections.
    
    Modify 'visitor' metadata in SIPExtensionPointIf to use relative class name
    for visiting class.

diff --git a/AsteriskSCF/Media/MediaIf.ice b/AsteriskSCF/Media/MediaIf.ice
index 59e1846..4d22fe0 100644
--- a/AsteriskSCF/Media/MediaIf.ice
+++ b/AsteriskSCF/Media/MediaIf.ice
@@ -36,11 +36,19 @@ module V1
    /**
     * Forward declaration of the Frame class so we can define a sequence of them.
     */
+   ["visitor"] local class FrameVisitor
+   {
+   };
+
    class Frame;
 
    /**
     * Forward declaration of the Format class so we can define a sequence of them.
     */
+   ["visitor"] local class FormatVisitor
+   {
+   };
+
    class Format;
 
    /**
@@ -326,10 +334,20 @@ module V1
     * A generic media operation class that can be extended for adding parameters. The parameters are used to find
     * a component capable of performing the described operation.
     */
-   class MediaOperation
+   ["visitor"] local class MediaOperationVisitor
    {
    };
 
+   ["visitor:MediaOperationVisitor"] class MediaOperation
+   {
+   };
+
+   /**
+    * A sequence of media operations. These are ordered in the order in which they should be
+    * executed.
+    */
+   sequence<MediaOperation> MediaOperationSeq;
+
    /**
     * A transcoding media operation class that is used to transcode from one format to other.
     */
@@ -347,15 +365,13 @@ module V1
    };
 
    /**
-    * A sequence of media operations. These are ordered in the order in which they should be
-    * executed.
-    */
-   sequence<MediaOperation> MediaOperationSeq;
-
-   /**
     * A media operation query result class, this gets returned by a media operation service when queried.
     */
-   class MediaOperationQueryResult
+   ["visitor"] local class MediaOperationQueryResultVisitor
+   {
+   };
+
+   ["visitor:MediaOperationQueryResultVisitor"] class MediaOperationQueryResult
    {
       /**
        * A concrete class describing the operation that the media operation service can perform.
@@ -405,7 +421,7 @@ module V1
     * A generic frame class that contains common details about frames. Additional classes should extend this to provide
     * additional details about the frame.
     */
-   class Frame
+   ["visitor:FrameVisitor"] class Frame
    {
       /**
        * A concrete format class describing the format that this frame is in.
@@ -452,7 +468,7 @@ module V1
     * A generic format class that provides common information about formats. Additional classes should extend
     * this to provide additional details about the format.
     */
-   class Format
+   ["visitor:FormatVisitor"] class Format
    {
       /**
        * A string containing a human readable name for the format, this may not be unique and is
diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
index 65fcee5..b0db305 100644
--- a/AsteriskSCF/SIP/SIPExtensionPointIf.ice
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -142,7 +142,7 @@ module V1
     {
     };
 
-    ["visitor:::AsteriskSCF::SIP::ExtensionPoint::V1::DigestChallengeVisitor"] class DigestChallenge
+    ["visitor:DigestChallengeVisitor"] class DigestChallenge
     {
 	string username;
 	string password;

commit 093dd4f755efcb495b31bb805838690d22138039
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Fri Feb 18 12:20:21 2011 -0600

    Convert DigestChallenge variants from an enum member field to subclasses.
    
    Add visitor-pattern metadata for DigestChallenge so it can be used when
    DigestChallengeSeq is passed around.

diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
index ad6db50..65fcee5 100644
--- a/AsteriskSCF/SIP/SIPExtensionPointIf.ice
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -138,25 +138,33 @@ module V1
     {
     };
 
-    enum DigestAlgorithm
+    ["visitor"] local class DigestChallengeVisitor
     {
-	MD5,
-	MD5sess,
-	AKAv1MD5,
-	AKAv1MD5sess,
-	AKAv2MD5,
-	AKAv2MD5sess
     };
 
-    class DigestChallenge
+    ["visitor:::AsteriskSCF::SIP::ExtensionPoint::V1::DigestChallengeVisitor"] class DigestChallenge
     {
 	string username;
 	string password;
 	Ice::StringSeq domain;
 	string realm;
-	Ice::StringSeq nonce;
 	Ice::StringSeq opaque;
-	DigestAlgorithm algorithm;
+    };
+
+    class MD5DigestChallenge extends DigestChallenge
+    {
+	// Indicates whether 'MD5' or 'MD5-sess' should be used
+	bool sessionMode;
+    };
+
+    class AKAv1DigestChallenge extends MD5DigestChallenge
+    {
+	string nonce;
+    };
+
+    class AKAv2DigestChallenge extends MD5DigestChallenge
+    {
+	string nonce;
     };
 
     sequence<DigestChallenge> DigestChallengeSeq;

commit f08f95b47099e7310580f29f164c842d47f3061c
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Thu Feb 10 11:49:35 2011 -0600

    After further discussion, two changes are in order:
    
    * There is no need for operations that register hooks to return a
      HookId-type object; the only object required to be able to unregister
      the hook in the future is the proxy to the hook, so a second object
      is unnecessary.
    
    * When registering a hook on an Extension Point, there is a need to
      be able to specify a priority (lower number == higher priority), so
      that hooks can be configured to run in a deterministic order.

diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
index 9b9f642..ad6db50 100644
--- a/AsteriskSCF/SIP/SIPExtensionPointIf.ice
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -188,8 +188,8 @@ module V1
 
     interface AuthExtensionPoint
     {
-	AsteriskSCF::System::Hook::V1::HookId addAuthHook(AuthHook *hook, RequestTypeSeq requestTypes);
-	void removeAuthHook(AsteriskSCF::System::Hook::V1::HookId id);
+	void addAuthHook(AuthHook *hook, int priority, RequestTypeSeq requestTypes);
+	void removeAuthHook(AuthHook *hook);
 	void clearAuthHooks();
     };
 
diff --git a/AsteriskSCF/System/Hook/HookIf.ice b/AsteriskSCF/System/Hook/HookIf.ice
index c9693fa..c205a2e 100644
--- a/AsteriskSCF/System/Hook/HookIf.ice
+++ b/AsteriskSCF/System/Hook/HookIf.ice
@@ -28,11 +28,6 @@ module Hook
 module V1
 {
 
-    struct HookId
-    {
-	string id;
-    };
-
     enum HookStatus
     {
 	/* Hook successfully processed input/returned result */

commit fff2150a0cbf51c4848c59b46a822ecd99f7bb54
Merge: 89e06ac 0cde8ca
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Thu Feb 10 11:46:58 2011 -0600

    Merge branch 'master' into sip-auth-hook


commit 89e06ac4dbdf1d9d6043a7770497dc83a05ae17a
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Wed Feb 9 10:30:33 2011 -0600

    Add RequestInfo subclasses for all IANA-registered SIP request methods.

diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
index e2071dd..9b9f642 100644
--- a/AsteriskSCF/SIP/SIPExtensionPointIf.ice
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -68,6 +68,76 @@ module V1
 	RequestTransport transport;
     };
 
+    // RFC 3261 - ACK method
+    class AckRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3261 - BYE method
+    class ByeRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3261 - CANCEL method
+    class CancelRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 6086 - INFO method
+    class InfoRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3261/6026 - INVITE method
+    class InviteRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3428 - MESSAGE method
+    class MessageRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3265 - NOTIFY method
+    class NotifyRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3261 - OPTIONS method
+    class OptionsRequestInfo extends InviteRequestInfo
+    {
+    };
+
+    // RFC 3262 - PRACK method
+    class PrackRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3903 - PUBLISH method
+    class PublishRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3515 - REFER method
+    class ReferRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3261 - REGISTER method
+    class RegisterRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3265 - SUBSCRIBE method
+    class SubscribeRequestInfo extends RequestInfo
+    {
+    };
+
+    // RFC 3311 - UPDATE method
+    class UpdateRequestInfo extends RequestInfo
+    {
+    };
+
     enum DigestAlgorithm
     {
 	MD5,
@@ -108,6 +178,8 @@ module V1
 	NonDialog,
 	// Examples of 'In Dialog' requests include (but are not limited to):
 	// (RFC3261) INVITE with a valid To tag denoting an existing dialog
+	// (RFC3261) ACK with a valid To tag denoting an existing dialog
+	// (RFC3261) BYE with a valid To tag denoting an existing dialog
 	// (RFC3265) SUBSCRIBE with a valid To tag denoting an existing dialog
 	InDialog,
     };

commit 06e3aa507539fe0e017ebcfce6d476e33507ff2e
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Wed Feb 9 10:19:44 2011 -0600

    Document some examples of SIP methods that fall into each category
    of RequestType.

diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
index dffcd74..e2071dd 100644
--- a/AsteriskSCF/SIP/SIPExtensionPointIf.ice
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -98,8 +98,17 @@ module V1
 
     enum RequestType
     {
+	// Examples of 'Dialog Establishing' requests include (but are not limited to):
+	// (RFC3261) INVITE without a To tag
+	// (RFC3265) SUBSCRIBE without a To tag
 	DialogEstablishing,
+	// Examples of 'Non Dialog' requests include (but are not limited to):
+	// (RFC3261) OPTIONS
+	// (RFC3261) REGISTER
 	NonDialog,
+	// Examples of 'In Dialog' requests include (but are not limited to):
+	// (RFC3261) INVITE with a valid To tag denoting an existing dialog
+	// (RFC3265) SUBSCRIBE with a valid To tag denoting an existing dialog
 	InDialog,
     };
 

commit 82d142a052204f76cd21b8ecc58f69147e95491e
Merge: 2e556b3 7d1de75
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Tue Feb 8 16:08:50 2011 -0600

    Merge branch 'master' into sip-auth-hook
    
    Conflicts:
    	make-mono-api.sh


commit 2e556b3559e046ba4407f0e2924ba5e6e9a5f1eb
Merge: b365c69 a4973ac
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Tue Feb 8 06:37:45 2011 -0600

    Merge branch 'master' into sip-auth-hook


commit b365c6903c0a09324ebdd9d664bf592fa127d5e4
Author: David M. Lee <dlee at digium.com>
Date:   Mon Feb 7 19:12:06 2011 -0600

    Fixed a couple of copy/paste errors.

diff --git a/make-python-api.sh b/make-python-api.sh
index 539ed18..3300179 100755
--- a/make-python-api.sh
+++ b/make-python-api.sh
@@ -6,7 +6,7 @@ then
     exit 1
 fi
 
-if [ ! -x "${ICE_HOME}/bin/slice2cs" ]
+if [ ! -x "${ICE_HOME}/bin/slice2py" ]
 then
     echo "slice2py translator not found in ICE_HOME"
     echo "(${ICE_HOME})"
diff --git a/make-ruby-api.sh b/make-ruby-api.sh
index 4241a00..decc27a 100755
--- a/make-ruby-api.sh
+++ b/make-ruby-api.sh
@@ -6,7 +6,7 @@ then
     exit 1
 fi
 
-if [ ! -x "${ICE_HOME}/bin/slice2cs" ]
+if [ ! -x "${ICE_HOME}/bin/slice2rb" ]
 then
     echo "slice2rb translator not found in ICE_HOME"
     echo "(${ICE_HOME})"

commit 1512425da52259210df6fea339798a9351256a7c
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Mon Feb 7 19:53:37 2011 +0100

    Build Mono API with warnings turned into errors
    and with DEBUG defined.

diff --git a/make-mono-api.sh b/make-mono-api.sh
index a8ad426..2bf5471 100755
--- a/make-mono-api.sh
+++ b/make-mono-api.sh
@@ -26,6 +26,6 @@ do
 done
 
 echo "Compiling generated C# into a library..."
-gmcs -debug -out:mono/AsteriskSCF-API.dll -t:library -recurse:'mono/generated/*.cs' Properties/AssemblyInfo.cs "-lib:${ICE_HOME}/bin" -r:Ice
+gmcs -warnaserror -debug -define:DEBUG -out:mono/AsteriskSCF-API.dll -t:library -recurse:'mono/generated/*.cs' Properties/AssemblyInfo.cs "-lib:${ICE_HOME}/bin" -r:Ice
 
 echo "Finished."

commit 9ea5281dc525bf6fcb641bca2f8dfbf27764f788
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Mon Feb 7 19:53:15 2011 +0100

    slice2rb now supports plugins, so use
    SliceVisitorPattern when building the API.

diff --git a/make-ruby-api.sh b/make-ruby-api.sh
index 01bbe81..4241a00 100755
--- a/make-ruby-api.sh
+++ b/make-ruby-api.sh
@@ -22,8 +22,7 @@ do
     slicedir=`dirname "${slice}"`
     mkdir -p "ruby/${slicedir}"
     echo "Translating ${slice} into Ruby..."
-#   --plugin SliceVisitorPattern:create
-    ${ICE_HOME}/bin/slice2rb -I ${ICE_HOME}/slice -I . --output-dir "ruby/${slicedir}" --checksum "${slice}"
+    ${ICE_HOME}/bin/slice2rb -I ${ICE_HOME}/slice -I . --output-dir "ruby/${slicedir}" --checksum --plugin SliceVisitorPattern:create "${slice}"
 done
 
 echo "Finished."

commit 6c31bea4b36ce5d3b0b3a93fdc8ef77df822bcca
Merge: 5ac2f70 fe141a9
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Mon Feb 7 13:15:39 2011 +0100

    Merge branch 'master' into sip-auth-hook


commit 5ac2f708432de5cd30c47895e61f710bb06b8f3f
Merge: f2f3868 738e77d
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Mon Feb 7 13:05:21 2011 +0100

    Merge branch 'master' into sip-auth-hook


commit f2f3868111b19b3abbcb629bc8c68bd3fde6e926
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Mon Feb 7 13:04:34 2011 +0100

    Byte-compile generated Python sources.

diff --git a/make-python-api.sh b/make-python-api.sh
index afac053..5ee04bb 100755
--- a/make-python-api.sh
+++ b/make-python-api.sh
@@ -25,4 +25,10 @@ do
     ${ICE_HOME}/bin/slice2py -I ${ICE_HOME}/slice -I . --output-dir python --checksum --plugin SliceVisitorPattern:create --prefix "${prefix}" "${slice}"
 done
 
+find python -name \*.py -print | while read py
+do
+    echo "Compiling ${py}..."
+    pycompile "${py}"
+done
+
 echo "Finished."

commit b96fd90a5a103a5972174e44b3ec84c90d89701f
Merge: 047f8c5 d8ee2a8
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Mon Feb 7 12:59:58 2011 +0100

    Merge branch 'master' into sip-auth-hook


commit 047f8c507d73e216eb0fbab40e7f7ee945c481a4
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Fri Feb 4 16:45:16 2011 +0100

    Add an initial version of the basic Hook interface and a SIP
    authentication Extension Point. This all came from the relevant
    wiki pages on wiki.asterisk.org, with some minor modifications
    along the way.

diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
new file mode 100644
index 0000000..dffcd74
--- /dev/null
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -0,0 +1,121 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+#include <Ice/BuiltinSequences.ice>
+
+#include <AsteriskSCF/System/Hook/HookIf.ice>
+
+module AsteriskSCF
+{
+
+module SIP
+{
+
+module ExtensionPoint
+{
+
+["suppress"]
+module V1
+{
+
+    dictionary<string, string> ParamDict;
+
+    enum RequestTransport
+    {
+	UDP,
+	TCP,
+	TLS
+    };
+
+    class RequestInfo
+    {
+	// The display name in the From header
+	string fromName;
+	// The URI in the From header
+	string fromURI;
+	// URI parameters in the From header
+	ParamDict fromParams;
+	// The display name in the To header
+	string toName;
+	// The URI in the To header
+	string toURI;
+	// URI parameters in the To header
+	ParamDict toParams;
+	// The request URI
+	string requestURI;
+	// request URI parameters
+	ParamDict requestURIParams;
+	// Source IP address
+	string IPAddr;
+	// Source Port
+	int port;
+	// Transport over which request was received
+	RequestTransport transport;
+    };
+
+    enum DigestAlgorithm
+    {
+	MD5,
+	MD5sess,
+	AKAv1MD5,
+	AKAv1MD5sess,
+	AKAv2MD5,
+	AKAv2MD5sess
+    };
+
+    class DigestChallenge
+    {
+	string username;
+	string password;
+	Ice::StringSeq domain;
+	string realm;
+	Ice::StringSeq nonce;
+	Ice::StringSeq opaque;
+	DigestAlgorithm algorithm;
+    };
+
+    sequence<DigestChallenge> DigestChallengeSeq;
+
+    interface AuthHook
+    {
+	AsteriskSCF::System::Hook::V1::HookResult challengeRequest(RequestInfo info, out DigestChallengeSeq challenges);
+    };
+
+    enum RequestType
+    {
+	DialogEstablishing,
+	NonDialog,
+	InDialog,
+    };
+
+    sequence<RequestType> RequestTypeSeq;
+
+    interface AuthExtensionPoint
+    {
+	AsteriskSCF::System::Hook::V1::HookId addAuthHook(AuthHook *hook, RequestTypeSeq requestTypes);
+	void removeAuthHook(AsteriskSCF::System::Hook::V1::HookId id);
+	void clearAuthHooks();
+    };
+
+}; /* End of module V1 */
+
+}; /* End of module ExtensionPoint */
+
+}; /* End of module SIP */
+
+}; /* End of module AsteriskSCF */
diff --git a/AsteriskSCF/System/Hook/HookIf.ice b/AsteriskSCF/System/Hook/HookIf.ice
new file mode 100644
index 0000000..c9693fa
--- /dev/null
+++ b/AsteriskSCF/System/Hook/HookIf.ice
@@ -0,0 +1,58 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+module AsteriskSCF
+{
+
+module System
+{
+
+module Hook
+{
+
+module V1
+{
+
+    struct HookId
+    {
+	string id;
+    };
+
+    enum HookStatus
+    {
+	/* Hook successfully processed input/returned result */
+	Succeeded,
+	/* Hook failed to process input or return result */
+	Failed,
+	/* Hook declined to process input and return result */
+	Declined
+    };
+
+    struct HookResult
+    {
+	HookStatus status;
+	string info;
+    };
+
+}; /* End of V1 */
+
+}; /* End of Hook */
+
+}; /* End of System */
+
+}; /* End of AsteriskSCF */

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/slice.git



More information about the asterisk-scf-commits mailing list