Shaping Object

class activelogic.ShapingObject

Object representing a shaping object in the ruleset.

  • name (str) – Name of the object.

  • id (int) – Id of the object.

  • flags (ShapingObjectFlags) – Behavioural flags set on the object.

  • max_connections (int) – Maximum number of allowed connections.

  • limits (An instance of ShapingObjectLimitGroup) – The limits configured on the shaping object.

  • split_netobjects (list) – The list of NetObjects with which split happens.

  • wfq (tuple) – Weights in percent to be used in fair queueing.

  • split_type (ShapingObjectSplitType) – ShapingObjectSplitType for how the object shall be split

  • split_argument (int) – Argument for selected split_type

  • fairness_group (ShapingObjectSplitType) – Fairness group.

  • fairness_group_argument (int) – Argument for fairness group.

  • speed_sc (ShapingObjectSessionContextSpeed) – The object representing the settings to makes it possible to dynamically provision bandwidth limiting using session context.

>>> so = rs.add(ShapingObject("Unlimited"))
>>> limits = ShapingObjectLimitGroup(inbound=ShapingObjectLimit(kbps=1024), outbound=ShapingObjectLimit(kbps=1024))
>>> so = rs.add(ShapingObject("Per host 1Mbps", split_type=ShapingObjectSplitType.LOCALHOST, limits=limits))
class activelogic.ShapingObjectFlags

Defines a set of behavioural flags for a shaping object.

  • NONE – No flags are set.

  • BROWN – Enable the BROWN Shaping Algorithm.

  • HOST_FAIRNESS – Enable fairness between hosts.

  • COUNTER – Enable byte counter.

  • BLUE – Enable BLUE AQM.

  • VIRTUAL_QUEUING – Enable virtual queueing.

  • CODEL – Enable CoDel AQM.

  • WFQ – Enable WFQ configured on the wfq property of the ShapingObject.

  • FAIRSPLIT – Enable fair split host fairness.

  • ZERO_RATING – Mark this ShapingObject as zero-rating object.

  • NO_SYSDIAG – Dont push stats for this ShapingObject.

  • SKIP_QSYNC – Skip Qsync for this ShapingObject.

  • QSYNC_HISTORICAL – Select Historical Sample QueueSync Algorithm for ShapingObject.

  • QSYNC_STEP – Select Step QueueSync Algorithm for ShapingObject.

  • QSYNC_FAIRSPLIT – Select Fairsplit QueueSync Algorithm for ShapingObject.

  • QSYNC_PRIORITY – Select Multi priority QueueSync Algorithm for ShapingObject.

  • QSYNC_QUALITY_FACTOR – Select Quality factor QueueSync Algorithm for ShapingObject.

  • QSYNC_DELAYED_UPDATE_SMOOTHENING – Smoothening for delayed QueueSync updates per ShapingObject.

class activelogic.ShapingObjectSplitType

Defines a set of split types for a shaping object.

  • NONE – No split type is set.

  • LOCALHOST – Split by local host.

  • HOST_NETOBJECT – Split by host NetObject.

  • SERVER_NETOBJECT – Split by server NetObject.

  • CLIENT_NETOBJECT – Split by client NetObject.

  • CONNECTION – Split by connection.

  • LOCAL_NETOBJECT – Split by local NetObject.

  • SUBSCRIBER – Split by subscriber.

  • LOCAL_NETWORK_PREFIX – Split by local network prefix.

  • SESSIONCONTEXT_OBJECT – Split by session context object.

class activelogic.ShapingObjectLimit

Object representing the shaping limits.

  • pps (int) – Maximum packets per second ( packet rate ), 0 for unlimited.

  • kbps (int) – Maximum kilo bits per second, 0 for unlimited.

  • cps (int) – Maximum new connections per second, 0 for unlimited.

  • queue_goal (int) – Queue goal in milliseconds, 0 for automatic.

  • queue_size – Queue size in packets, 0 for automatic.

class activelogic.ShapingObjectSessionContextSpeed

Object representing dynamically provisioned limits using session context.

  • schema (str) – Field defines the session context schema.

  • column_in (str) – Field defines what column to use for applying incoming bandwidth limit.

  • column_out (str) – Field defines what column to use for applying outgoing bandwidth limit.

Specified columns in the session context row that matches the connection is used to update the limits specified in the split copy.

class activelogic.ShapingObjectLimitGroup

Object representing the shaping object limits in different directions.