diff options
author | Richard Mudgett <rmudgett@digium.com> | 2014-08-06 17:04:08 +0000 |
---|---|---|
committer | Richard Mudgett <rmudgett@digium.com> | 2014-08-06 17:04:08 +0000 |
commit | a6612e80aacd6f7b446940d48f2f1cbd24875a56 (patch) | |
tree | f80f1d9687063a68ea49827dcb2b15e56106dacb /contrib/ast-db-manage/voicemail | |
parent | 3e5ab6ca39e3eaf0afffce06a1eea065c30093a5 (diff) |
alembic: Adjust sippeers, queue_members, and voicemail_messages tables.
* 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
Diffstat (limited to 'contrib/ast-db-manage/voicemail')
-rwxr-xr-x | contrib/ast-db-manage/voicemail/versions/39428242f7f5_increase_recording_column_size.py | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/contrib/ast-db-manage/voicemail/versions/39428242f7f5_increase_recording_column_size.py b/contrib/ast-db-manage/voicemail/versions/39428242f7f5_increase_recording_column_size.py new file mode 100755 index 000000000..f06cbf10e --- /dev/null +++ b/contrib/ast-db-manage/voicemail/versions/39428242f7f5_increase_recording_column_size.py @@ -0,0 +1,44 @@ +# +# Asterisk -- An open source telephony toolkit. +# +# Copyright (C) 2014, Richard Mudgett +# +# Richard Mudgett <rmudgett@digium.com> +# +# See http://www.asterisk.org for more information about +# the Asterisk 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 file +# at the top of the source tree. +# + +"""increase recording column size + +Revision ID: 39428242f7f5 +Revises: a2e9769475e +Create Date: 2014-07-28 16:02:05.104895 + +""" + +# revision identifiers, used by Alembic. +revision = '39428242f7f5' +down_revision = 'a2e9769475e' + +from alembic import op +import sqlalchemy as sa + + +def upgrade(): + # Make BLOB a LONGBLOB for mysql so recordings longer than about + # four seconds can be stored. + # See LargeBinary http://docs.sqlalchemy.org/en/rel_0_9/core/types.html + op.alter_column('voicemail_messages', 'recording', type_=sa.LargeBinary(4294967295)) + + +def downgrade(): + op.alter_column('voicemail_messages', 'recording', type_=sa.LargeBinary) + |