summaryrefslogtreecommitdiff
path: root/contrib/ast-db-manage
AgeCommit message (Collapse)Author
2016-03-02alembic: Fix downgrade and tweak for sqliteGeorge Joseph
Downgrade had a few issues. First there was an errant 'update' statement in add_auto_dtmf_mode that looks like it was a copy/paste error. Second, we weren't cleaning up the ENUMs so subsequent upgrades on postgres failed because the types already existed. For sqlite... sqlite doesn't support ALTER or DROP COLUMN directly. Fortunately alembic batch_operations takes care of this for us if we use it so the alter and drops were converted to use batch operations. Here's an example downgrade: with op.batch_alter_table('ps_endpoints') as batch_op: batch_op.drop_column('tos_audio') batch_op.drop_column('tos_video') batch_op.add_column(sa.Column('tos_audio', yesno_values)) batch_op.add_column(sa.Column('tos_video', yesno_values)) batch_op.drop_column('cos_audio') batch_op.drop_column('cos_video') batch_op.add_column(sa.Column('cos_audio', yesno_values)) batch_op.add_column(sa.Column('cos_video', yesno_values)) with op.batch_alter_table('ps_transports') as batch_op: batch_op.drop_column('tos') batch_op.add_column(sa.Column('tos', yesno_values)) # Can't cast integers to YESNO_VALUES, so dropping and adding is required batch_op.drop_column('cos') batch_op.add_column(sa.Column('cos', yesno_values)) Upgrades from base to head and downgrades from head to base were tested repeatedly for postgresql, mysql/mariadb, and sqlite3. Change-Id: I862b0739eb3fd45ec3412dcc13c2340e1b7baef8
2016-02-19res_pjsip/config_transport: Allow reloading transports.George Joseph
The 'reload' mechanism actually involves closing the underlying socket and calling the appropriate udp, tcp or tls start functions again. Only outbound_registration, pubsub and session needed work to reset the transport before sending requests to insure that the pjsip transport didn't get pulled out from under them. In my testing, no calls were dropped when a transport was changed for any of the 3 transport types even if ip addresses or ports were changed. To be on the safe side however, a new transport option was added (allow_reload) which defaults to 'no'. Unless it's explicitly set to 'yes' for a transport, changes to that transport will be ignored on a reload of res_pjsip. This should preserve the current behavior. Change-Id: I5e759850e25958117d4c02f62ceb7244d7ec9edf
2016-02-04pjsip/alembic: Add missing columns to system and registrationGeorge Joseph
ps_systems needed disable_tcp_switch ps_registrations needed line and endpoint ASTERISK-25737 #close Change-Id: Iaf9c2d69e62243d9fa53104c28c5339c47d4ac19
2016-01-31pjsip/alembic: Fix definition of qualify_timeoutGeorge Joseph
A recent commit set qualify_timeout to Decimal which isn't supported. This path corrects it to Float. Change-Id: I038f5274ba8cb60f8518a5845ce448d49306aadf
2016-01-19Fix alembic branches on v13.Richard Mudgett
Change-Id: I313449b609ede18ad1e1763a655dd23b9210a8e0
2016-01-18Merge "pjsip/alembic: Fix qualify_timeout column definition" into 13Joshua Colp
2016-01-14Merge "pjsip: Add option global/regcontext" into 13Joshua Colp
2016-01-13pjsip/alembic: Fix qualify_timeout column definitionDaniel Journo
Corrects the qualify_timeout column type from Integer to Decimal ASTERISK-25686 #close Reported-by: Marcelo Terres Change-Id: I757d0e3c011ee9be6cd5abd48bc92441a405d3c8
2016-01-11pjsip_sdp_rtp: Add option endpoint/bind_rtp_to_media_addressGeorge Joseph
On a system with multiple ip addresses in the same subnet, if a transport is bound to a specific ip address and endpoint/media_address is set, the SIP/SDP will have the correct address in all fields but the rtp stream MAY still originate from one of the other ip addresses, most probably the "primary" ip address. This happens because res_pjsip_sdp_rtp/create_rtp always calls ast_instance_new with the "all" ip address (0.0.0.0 or ::). The new option causes res_pjsip_sdp_rtp/create_rtp to call ast_rtp_instance_new with the endpoint's media_address (if specified) instead of the "all" address. This causes the packets to originate from the specified address. ASTERISK-25632 ASTERISK-25637 Reported-by: Olivier Krief Reported-by: Dan Journo Change-Id: I3dfaa079e54ba7fb7c4fd1f5f7bd9509bbf8bd88
2016-01-11pjsip: Add option global/regcontextDaniel Journo
Added new global option (regcontext) to pjsip. When set, Asterisk will dynamically create and destroy a NoOp priority 1 extension for a given endpoint who registers or unregisters with us. ASTERISK-25670 #close Reported-by: Daniel Journo Change-Id: Ib1530c5b45340625805c057f8ff1fb240a43ea62
2015-12-16Alembic: Increase column size of PJSIP AOR "contact".Mark Michelson
When running the PJSIP AMI "show_endpoint" test with automatic conversion to realtime, the test would fail. This was because the AOR "contact" column was sized at 40, and the configured contact was larger than that. This commit increases the size of the contact column to 255 characters. Change-Id: Ia65bc7fd37699b7c0eaef9629a1a31eab9a24ba1
2015-12-16Alembic: Add PJSIP global keep_alive_interval.Mark Michelson
The keep_alive_interval option was added about a year ago, but no alembic revision was created to add the appropriate column to the database. This commit fixes the problem and adds the column. This was discovered by running the testsuite with automatic conversion to realtime enabled. Change-Id: If3ef92a7c4f4844d08f8aae170d2178aec5c4c1a
2015-10-23res_pjsip_outbound_registration: registration stops due to fatal 4xx responseKevin Harwell
During outbound registration it is possible to receive a fatal (any permanent/ non-temporary 4xx, 5xx, 6xx) response from the registrar that is simply due to a problem with the registrar itself. Upon receiving the failure response Asterisk terminates outbound registration for the given endpoint. This patch adds an option, 'fatal_retry_interval', that when set continues outbound registration at the given interval up to 'max_retries' upon receiving a fatal response. ASTERISK-25485 #close Change-Id: Ibc2c7b47164ac89cc803433c0bbe7063bfa143a2
2015-09-04res_pjsip: Change default from user value.Mark Michelson
When Asterisk sends an outbound SIP request, if there is no direct reason to place a specific value for the username in the From header, Asterisk would generate a UUID. For example, this would happen when sending outbound OPTIONS requests when qualifying or when sending outbound INVITE requests when originating (if no explicit caller ID were provided). The issue is that some SIP providers reject these sorts of requests with a "Name too long" error response. This patch aims to fix this by changing the default outbound username in From headers to "asterisk". This value can be overridden by changing the default_from_user option in the global options if desired. ASTERISK-25377 #close Reported by Mark Michelson Change-Id: I6a4d34a56ff73ff4f661b0075aeba5461b7f3190
2015-07-24pjsip: Add rtp_timeout and rtp_timeout_hold endpoint options.Joshua Colp
This change adds support for the 'rtp_timeout' and 'rtp_timeout_hold' endpoint options. These allow the channel to be hung up if RTP is not received from the remote endpoint for a specified number of seconds. ASTERISK-25259 #close Change-Id: I3f39daaa7da2596b5022737b77799d16204175b9
2015-07-20res_pjsip: Add rtp_keepalive endpoint option.Mark Michelson
This adds an "rtp_keepalive" option for PJSIP endpoints. Similar to the chan_sip option, this specifies an interval, in seconds, at which we will send RTP comfort noise frames. This can be useful for keeping RTP sessions alive as well as keeping NAT associations alive during lulls. ASTERISK-25242 #close Reported by Mark Michelson Change-Id: I06660ba672c0a343814af4cec838e6025cafd54b
2015-06-15res_pjsip: Add option to force G.726 to be treated as AAL2 packed.Kevin Harwell
Some phones send g.726 audio packed for AAL2, which differs from what is recommended by RFC 3351. If Asterisk receives audio formatted as such when negotiating g.726 then it sounds a bit distorted. Added an option to res_pjsip_endpoint that allows g.726 negotiated audio to be treated as g.726 AAL2 packed. ASTERISK-25158 #close Reported by: Steve Pitts Change-Id: Ie7e21f75493d7fe53e75e12c971e72f5afa33615
2015-05-03contrib/ast-db-manage: Add Postgres ENUM type support in auto DTMF mode updateMatt Jordan
The upgrade script for auto DTMF mode (31cd4f4891ec) added in 88b0fa7755 failed to add ENUM support for Postgres databases. This requires a specific import from the sqlalchemy.dialects.postgresql package. This patch corrects this error, which allows for Postgres update scripts to be generated. ASTERISK-24706 Change-Id: I4742ac8efa533cd6f18e0bdd907b339a9aedf015
2015-04-17pjsip_options: Add qualify_timeout processing and eventingGeorge Joseph
This is the second follow-on to https://reviewboard.asterisk.org/r/4572/ and the discussion at http://lists.digium.com/pipermail/asterisk-dev/2015-March/073921.html The basic issues are that changes in contact status don't cause events to be emitted for the associated endpoint. Only dynamic contact add/delete actions update the endpoint. Also, the qualify timeout is fixed by pjsip at 32 seconds which is a long time. This patch makes use of the new transaction timeout feature in r4585 and provides the following capabilities... 1. A new aor/contact variable 'qualify_timeout' has been added that allows the user to specify the maximum time in milliseconds to wait for a response to an OPTIONS message. The default is 3000ms. When the timer expires, the contact is marked unavailable. 2. Contact status changes are now propagated up to the endpoint as follows... When any contact is 'Available', the endpoint is marked as 'Reachable'. When all contacts are 'Unavailable', the endpoint is marked as 'Unreachable'. The existing endpoint events are generated appropriately. ASTERISK-24863 #close Change-Id: Id0ce0528e58014da1324856ea537e7765466044a Tested-by: Dmitriy Serov Tested-by: George Joseph <george.joseph@fairview5.com>
2015-04-16res_pjsip: Add global option to limit the maximum time for initial qualifiesGeorge Joseph
Currently when Asterisk starts initial qualifies of contacts are spread out randomly between 0 and qualify_timeout to prevent network and system overload. If a contact's qualify_frequency is 5 minutes however, that contact may be unavailable to accept calls for the entire 5 minutes after startup. So while staggering the initial qualifies is a good idea, basing the time on qualify_timeout could leave contacts unavailable for too long. This patch adds a new global parameter "max_initial_qualify_time" that sets the maximum time for the initial qualifies. This way you could make sure that all your contacts are initialy, randomly qualified within say 30 seconds but still have the contact's ongoing qualifies at a 5 minute interval. If max_initial_qualify_time is > 0, the formula is initial_interval = min(max_initial_interval, qualify_timeout * random(). If not set, qualify_timeout is used. The default is "0" (disabled). ASTERISK-24863 #close Change-Id: Ib80498aa1ea9923277bef51d6a9015c9c79740f4 Tested-by: George Joseph <george.joseph@fairview5.com>
2015-04-10res_pjsip: Add an 'auto' option for DTMF ModeMatthew Jordan
This patch adds support for automatically detecting the type of DTMF that a PJSIP endpoint supports. When the 'dtmf_mode' endpoint option is set to 'auto', the channel created for an endpoint will attempt to determine if RFC 4733 DTMF is supported. If so, it will use that DTMF type. If not, the DTMF type for the channel will be set to inband. Review: https://reviewboard.asterisk.org/r/4438 ASTERISK-24706 #close Reported by: yaron nahum patches: yaron_patch_3_Feb.diff submitted by yaron nahum (License 6676) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@434637 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2015-03-24chan_pjsip: Add "rpid_immediate" option to prevent unnecessary "180 Ringing" ↵Richard Mudgett
messages. Incoming PJSIP call legs that have not been answered yet send unnecessary "180 Ringing" or "183 Progress" messages every time a connected line update happens. If the outgoing channel is also PJSIP then the incoming channel will always send a "180 Ringing" or "183 Progress" message when the outgoing channel sends the INVITE. Consequences of these unnecessary messages: * The caller can start hearing ringback before the far end even gets the call. * Many phones tend to grab the first connected line information and refuse to update the display if it changes. The first information is not likely to be correct if the call goes to an endpoint not under the control of the first Asterisk box. When connected line first went into Asterisk in v1.8, chan_sip received an undocumented option "rpid_immediate" that defaults to disabled. When enabled, the option immediately passes connected line update information to the caller in "180 Ringing" or "183 Progress" messages as described above. * Added "rpid_immediate" option to prevent unnecessary "180 Ringing" or "183 Progress" messages. The default is "no" to disable sending the unnecessary messages. ASTERISK-24781 #close Reported by: Richard Mudgett Review: https://reviewboard.asterisk.org/r/4473/ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@433338 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2015-03-17res_pjsip: Allow configuration of endpoint identifier query orderKevin Harwell
This patch fixes previously reverted code that caused binary incompatibility problems with some modules. And like the original patch it makes sure that no matter what order the endpoint identifier modules were loaded, priority is given based on the ones specified in the new global 'endpoint_identifier_order' option. ASTERISK-24840 Reported by: Mark Michelson Review: https://reviewboard.asterisk.org/r/4489/ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@433028 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2015-03-13Revert - res_pjsip: Allow configuration of endpoint identifier query orderKevin Harwell
Due to a break in binary compatibility with some other modules these changes are being reverted until the issue can be resolved. ASTERISK-24840 Reported by: Mark Michelson git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@432868 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2015-03-09res_pjsip: Allow configuration of endpoint identifier query orderKevin Harwell
It's possible to have a scenario that will create a conflict between endpoint identifiers. For instance an incoming call could be identified by two different endpoint identifiers and the one chosen depended upon which identifier module loaded first. This of course causes problems when, for example, the incoming call is expected to be identified by username, but instead is identified by ip. This patch adds a new 'global' option to res_pjsip called 'endpoint_identifier_order'. It is a comma separated list of endpoint identifier names that specifies the order by which identifiers are processed and checked. ASTERISK-24840 #close Reported by: Mark Michelson Review: https://reviewboard.asterisk.org/r/4455/ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@432638 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2015-01-06contrib/ast-db-manage: Correct down_revision path for user_eq_phoneMatthew Jordan
When the user_eq_phone patch was backported to 13, it referenced the downward revision that the PJSIP optimistic encryption option also references. This creates a multi-path upgrade Exception when generating the SQL files. This patch corrects this in the 13 branch. Note that trunk, which already contained both of these features, is unaffected by this problem. git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@430252 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-12-24res_pjsip: Backport missing commits for user_eq_phoneMatthew Jordan
This backports the following from trunk, which were missed: r427257 | file | 2014-11-04 16:31:16 -0600 (Tue, 04 Nov 2014) | 2 lines res_pjsip: Allow + at the beginning of a phone number when user_eq_phone is enabled. r427259 | file | 2014-11-04 16:51:32 -0600 (Tue, 04 Nov 2014) | 2 lines res_pjsip: Apply the 'user_eq_phone' setting to the To header as well. It also adds the Alembic script for the option. ASTERISK-24643 git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@430092 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-11-19res_pjsip_sdp_rtp: Add support for optimistic SRTP.Joshua Colp
Optimistic SRTP is the ability to enable SRTP but not have it be a fatal requirement. If SRTP can be used it will be, if not it won't be. This gives you a better chance of using it without having your sessions fail when it can't be. Encrypt all the things! Review: https://reviewboard.asterisk.org/r/3992/ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@428222 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-10-02Alembic: Add enumerator value to sippeers -> directmedia - 'outgoing'Jonathan Rose
The 'outgoing' value was left off of the enumerator when first creating the column. This patch adds it, and should gracefully upgrade keeping the existing data in tact. ASTERISK-23781 #close Reported by: Stephen More Review: https://reviewboard.asterisk.org/r/4013/ ........ Merged revisions 424372 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@424373 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-09-15contrib: Fix verifyi typo in alembic DB script ps_transport table.Walter Doekes
Reported by: Zogot (on IRC) Patches: tmp.diff uploaded by Zogot, cleaned up by me. ........ Merged revisions 423128 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@423129 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-08-11app_queue: Add RealTime support for queue rulesMatthew Jordan
This patch gives the optional ability to keep queue rules in RealTime. It is important to note that with this patch: (a) Queue rules in RealTime are only examined on module load/reload (b) Queue rules are loaded both from the queuerules.conf file as well as the RealTime backend To inform app_queue to examine RealTime for queue rules, a new setting has been added to queuerules.conf's general section "realtime_rules". RealTime queue rules will only be used when this setting is set to "yes". The schema for the database table supports a rule_name, time, min_penalty, and max_penalty columns. min_penalty and max_penalty can be relative, if a '-' or '+' literal is provided. Otherwise, the penalties are treated as constants. For example: rule_name, time, min_penalty, max_penalty 'default', '10', '20', '30' 'test2', '20', '30', '55' 'test2', '25', '-11', '+1111' 'test2', '400', '112', '333' 'test3', '0', '4564', '46546' 'test_rule', '40', '15', '50' which would result in : Rule: default - After 10 seconds, adjust QUEUE_MAX_PENALTY to 30 and adjust QUEUE_MIN_PENALTY to 20 Rule: test2 - After 20 seconds, adjust QUEUE_MAX_PENALTY to 55 and adjust QUEUE_MIN_PENALTY to 30 - After 25 seconds, adjust QUEUE_MAX_PENALTY by 1111 and adjust QUEUE_MIN_PENALTY by -11 - After 400 seconds, adjust QUEUE_MAX_PENALTY to 333 and adjust QUEUE_MIN_PENALTY to 112 Rule: test3 - After 0 seconds, adjust QUEUE_MAX_PENALTY to 46546 and adjust QUEUE_MIN_PENALTY to 4564 Rule: test_rule - After 40 seconds, adjust QUEUE_MAX_PENALTY to 50 and adjust QUEUE_MIN_PENALTY to 15 If you use RealTime, the queue rules will be always reloaded on a module reload, even if the underlying file did not change. With the option disabled, the rules will only be reloaded if the file was modified. Review: https://reviewboard.asterisk.org/r/3607/ ASTERISK-23823 #close Reported by: Michael K patches: app_queue.c_realtime_trunk.patch uploaded by Michael K (License 6621) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@420624 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-08-06Fix alembic script to work properly in offline mode.Richard Mudgett
When run in offline mode, this would attempt to check the database for the presence of a type it was going to try to create. I now check the context to see if we're running in offline mode and change a parameter accordingly. ........ Merged revisions 407567 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@420237 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-08-06Add alembic script that adds contact user_agent and endpoint message_context.Richard Mudgett
........ Merged revisions 411514 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@420236 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-08-06alembic: Adjust sippeers, queue_members, and voicemail_messages tables.Richard Mudgett
* Increased the sippeers useragent max string size to 255. * Changed the queue_members uniqueid to an auto incremented integer instead of a string. * Increased the voicemail_messages BLOB size to LONGBLOB on mysql. * Fixed the add_tables_for_pjsip config change version downgrade actions to drop a table it created. * Adjusted the sample alembic.ini files cdr.ini.sample, config.ini.sample, and voicemail.ini.sample to give a mysql and postgres sqlalchemy.url lines. ASTERISK-23847 #close Reported by: Stephen More ASTERISK-23825 #close Reported by: Stephen More ASTERISK-23909 #close Reported by: Stephen More Review: https://reviewboard.asterisk.org/r/3870/ ........ Merged revisions 420211 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@420212 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-16res_pjsip: Support setting a default accountcode on endpointsMatthew Jordan
Most channel drivers let you specify a default accountcode to be set on channels associated with a particular peer/endpoint/object. Prior to this patch, chan_pjsip/res_pjsip did not support such a setting. This patch adds a new setting to the res_pjsip endpoint object, 'accountcode'. When a channel is created that is associated with an endpoint with this value set, the channel will automatically have its accountcode property set to the value configured for the endpoint. Review: https://reviewboard.asterisk.org/r/3724/ ASTERISK-24000 #close Reported by: Matt Jordan ........ Merged revisions 418756 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@418757 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-06-30Recorded merge of revisions 417677 from ↵Joshua Colp
http://svn.asterisk.org/svn/asterisk/branches/11 ........ res_rtp_asterisk: Add SHA-256 support for DTLS and perform DTLS negotiation on RTCP. This change fixes up DTLS support in res_rtp_asterisk so it can accept and provide a SHA-256 fingerprint, so it occurs on RTCP, and so it occurs after ICE negotiation completes. Configuration options to chan_sip and chan_pjsip have also been added to allow behavior to be tweaked (such as forcing the AVP type media transports in SDP). ASTERISK-22961 #close Reported by: Jay Jideliov Review: https://reviewboard.asterisk.org/r/3679/ Review: https://reviewboard.asterisk.org/r/3686/ ........ Merged revisions 417678 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@417679 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-06-12res_pjsip_pubsub: Persist subscriptions in sorcery so they are recreated on ↵Joshua Colp
startup. This change makes res_pjsip_pubsub persist inbound subscriptions in sorcery. By default this uses the local astdb but it can also be configured to store within an outside database. When Asterisk is started these subscriptions are recreated if they have not expired. Notifications are sent to the devices which have subscribed and they are none the wiser that the system has restarted. Review: https://reviewboard.asterisk.org/r/3598/ ........ Merged revisions 415766 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@415767 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-05-28ast-db-manage/cdr/env.py: Don't fail if a config file can't be loadedMatthew Jordan
When generating SQL files via the repotools alembic_creator.py script, a configuration object is used programatically with SQLAlechemy, as opposed to a configuration file. This patch ignores failures to interpret a config file, as ... there isn't one in this case. ........ Merged revisions 414763 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@414764 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-04-24pjsip realtime: increase the size of some columnsKevin Harwell
The string lengths on certain columns created through alembic for PJSIP were too short. For instance, columns containing URIs are currently set to 40 characters, but this can be too small and result in truncated values. Added an alembic migration script that increases the size of these columns and a few others to 255. ASTERISK-23639 #close Reported by: Mark Michelson Review: https://reviewboard.asterisk.org/r/3475/ ........ Merged revisions 412992 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@412993 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-26Fix 'alembic branches' merge conflict as described by the web page.Richard Mudgett
........ Merged revisions 411191 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@411192 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-14PJSIP: TOS values should be represented as decimals in sorcery objectsJonathan Rose
(closes issue ASTERISK-23235) Reported by: George Joseph Review: https://reviewboard.asterisk.org/r/3324/ ........ Merged revisions 410574 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@410575 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-06pjsip configuration: Make transport TOS values consistent with endpointsJonathan Rose
Transport TOS values were interpreted as DSCP values without being documented as such. Endpoint TOS values (tos_audio/tos_video) behaved normally as TOS values have historically. This patch makes the transport TOS values behave as TOS values and makes all TOS values readable as string values (e.g. AF11). In addition, alembic scripts have been updated to use the proper field types for all TOS/COS values. (issue ASTERISK-23235) Reported by: George Joseph Review: https://reviewboard.asterisk.org/r/3304/ ........ Merged revisions 410028 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@410029 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-05alembic: Add missing queue and CDR table creation scripts.Richard Mudgett
* Added the queues and queue_members tables to the config alembic scripts. * Added the CDR table alembic creation script. The CDR table is more of an example for new setups since the actual table can be fully customized in cdr_adaptive_odbc.conf. (closes issue ASTERISK-23233) Reported by: jmls Review: https://reviewboard.asterisk.org/r/3227/ ........ Merged revisions 409885 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@409889 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-02-18alembic: Add svn:ignore *.pyc to directories and svn:executable to *.py files.Richard Mudgett
........ Merged revisions 408297 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@408299 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-02-06pjsip realtime: already created enum failure for postgresqlKevin Harwell
If an enum had been previously created the alembic script would attempt to re-create it and an error would be generated while running migrations for a postgresql server. The work around for this is to use the ENUM object type for postgres as opposed to the generic enum type used by sqlalchemy. Using this type in the script seems to work properly for both postgres and mysql. ........ Merged revisions 407572 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@407574 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-01-31res_pjsip: Config option to enable PJSIP logger at load time.Kevin Harwell
Added a "debug" configuration option for res_pjsip that when set to "yes" enables SIP messages to be logged. It is specified under the "system" type. Also added an alembic script to add the option to realtime. (closes issue ASTERISK-23038) Reported by: Rusty Newton Review: https://reviewboard.asterisk.org/r/3148/ ........ Merged revisions 407036 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@407037 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-01-31alembic: script modifications due to errorsKevin Harwell
A couple of the scripts had errors that would not allow a full migration to take place. The extensions table needed to make its 'id' column a primary key in order to work with mysql. The other script ...add_endpoints... was missing tables that it was trying to add columns to. Added the primary key on id for extensions and added the tables in for the missing pjsip configuration options. While it is not ideal to modify already released scripts this was a case where it had to be done due to errors in the script and lacking a better alternative. Review: https://reviewboard.asterisk.org/r/3167/ ........ Merged revisions 407019 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@407029 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-01-15PJSIP: Add Path header supportKinsey Moore
This adds Path support to chan_pjsip in res_pjsip_path.c with minimal additions in res_pjsip_registrar.c to store the path and additions in res_pjsip_outbound_registration.c to enable advertisement of path support to registrars and intervening proxies. Path information is stored on contacts and is enabled via Address of Record (AoRs) and Registration configuration sections. While adding path support, it became necessary to be able to add SIP supplements that handled messages outside of sessions, so a framework for handling these types of hooks was added in parallel to the already-existing session supplements and several senders of out-of-dialog requests were refactored as a result. (closes issue ASTERISK-21084) Review: https://reviewboard.asterisk.org/r/3050/ ........ Merged revisions 405565 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@405566 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-12realtime: Create extensions in alembic ast-db-manage contributionScott Griepentrog
When the alembic scripts were written for creating Asterisk realtime databases the extensions table for dialplan wasn't included. This update creates the extensions table. (closes issue ASTERISK-22815) Reported by: Zone Conkle Review: https://reviewboard.asterisk.org/r/3064/ ........ Merged revisions 403713 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403714 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-11-22res_pjsip: convert configuration settings names to snake case some moreKevin Harwell
Updated the alembic script for pjsip. Also, the dtls config parsing stuff was expecting strings with no underscores, so removed the underscores from the option name before passing it to the parser. ........ Merged revisions 403082 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403083 65c4cc65-6c06-0410-ace0-fbb531ad65f3