<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
<tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="https://reviewboard.asterisk.org/r/3870/">https://reviewboard.asterisk.org/r/3870/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<p style="margin-top: 0;">On August 4th, 2014, 4:10 p.m. CDT, <b>Mark Michelson</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
<thead>
<tr>
<th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
<a href="https://reviewboard.asterisk.org/r/3870/diff/1/?file=65734#file65734line36" style="color: black; font-weight: bold; text-decoration: underline;">/branches/12/contrib/ast-db-manage/voicemail/versions/39428242f7f5_increase_recording_column_size.py</a>
<span style="font-weight: normal;">
(Diff revision 1)
</span>
</th>
</tr>
</thead>
<tbody>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">36</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> <span class="c"># Make BLOB a LONGBLOB for mysql</span></pre></td>
</tr>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">37</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> <span class="n">op</span><span class="o">.</span><span class="n">alter_column</span><span class="p">(</span><span class="s">'voicemail_messages'</span><span class="p">,</span> <span class="s">'recording'</span><span class="p">,</span> <span class="n">type_</span><span class="o">=</span><span class="n">sa</span><span class="o">.</span><span class="n">LargeBinary</span><span class="p">(</span><span class="mi">4294967295</span><span class="p">))</span></pre></td>
</tr>
</tbody>
</table>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">There is something just absolutely frightening about this. Can you add to your comment:
1) why this is necessary
2) a reference indicating that this is the correct way of doing this for MySQL
3) some reassurance that this will not do something awful for other DBMSs.
As it looks, every voicemail message is going to have 4GB set aside for it.</pre>
</blockquote>
</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This is necessary because mysql will truncate recordings to about 4 seconds worth of audio as mysql limits a BLOB to only 64k.
For postgres, the backend did not output anything different.
This is the only parameter that LargeBinary is documented as accepting.
See LargeBinary http://docs.sqlalchemy.org/en/rel_0_9/core/types.html
I'll augment the comment.</pre>
<br />
<p>- rmudgett</p>
<br />
<p>On July 30th, 2014, 9:52 a.m. CDT, rmudgett wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://reviewboard.asterisk.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for Asterisk Developers.</div>
<div>By rmudgett.</div>
<p style="color: grey;"><i>Updated July 30, 2014, 9:52 a.m.</i></p>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>
<a href="https://issues.asterisk.org/jira/browse/ASTERISK-23825">ASTERISK-23825</a>,
<a href="https://issues.asterisk.org/jira/browse/ASTERISK-23847">ASTERISK-23847</a>,
<a href="https://issues.asterisk.org/jira/browse/ASTERISK-23909">ASTERISK-23909</a>
</div>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt;">Repository: </b>
Asterisk
</div>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">* 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.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">The alembic table adjustments work in the upgrade and downgrade modes for mysql and postgres.
The queue_members change does give a postgres warning message from the postgres alembic backend about a mysql only kind of change. The warning is benign and can be ignored as it is an alembic only warning.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>/branches/12/contrib/ast-db-manage/voicemail/versions/39428242f7f5_increase_recording_column_size.py <span style="color: grey">(PRE-CREATION)</span></li>
<li>/branches/12/contrib/ast-db-manage/voicemail.ini.sample <span style="color: grey">(419804)</span></li>
<li>/branches/12/contrib/ast-db-manage/config/versions/5139253c0423_make_q_member_uniqueid_autoinc.py <span style="color: grey">(PRE-CREATION)</span></li>
<li>/branches/12/contrib/ast-db-manage/config/versions/43956d550a44_add_tables_for_pjsip.py <span style="color: grey">(419804)</span></li>
<li>/branches/12/contrib/ast-db-manage/config/versions/1758e8bbf6b_increase_useragent_column_size.py <span style="color: grey">(PRE-CREATION)</span></li>
<li>/branches/12/contrib/ast-db-manage/config.ini.sample <span style="color: grey">(419804)</span></li>
<li>/branches/12/contrib/ast-db-manage/cdr.ini.sample <span style="color: grey">(419804)</span></li>
</ul>
<p><a href="https://reviewboard.asterisk.org/r/3870/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>