<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/1139/">https://reviewboard.asterisk.org/r/1139/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<p style="margin-top: 0;">On March 29th, 2011, 2:05 p.m., <b>Brad Latus</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I would follow oej's view, it should be more like the DB functions since they do the same.
Also throughout the code your not following some of the CODING-GUIDELINES.txt
Main thing I noticed was that you declare variables all around the code, all variables must be declared at top of scope.
You also have no message/default if people happen to specify an invalid or wrong hash function (at my quick look)</pre>
</blockquote>
<p>On April 5th, 2011, 6:46 p.m., <b>drivefast</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">(sorry for the late response.)
i tried to keep close to the way memcached defines the operations, rather than focusing on providing similarity with the DB functions. and to be honest, i'm no big fan of asterisk's "writing" functions, they look to me like functions called for their side effect. i am however open to suggestions, and if you can be more specific on how would you see those functions, i would be happy to provide additional calling conventions, or replace the existing ones.</pre>
</blockquote>
</blockquote>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I would probably do the following:
Function of MCD()
MCD(<key>,[,<timeout>,<option>])
Applications would go away, so no mcdadd/mcdget/mcdset..
The 'option' flag would be for 'appending' or 'deleting' a value, or simply a blank value would delete the key.
Basically all commands would be Set(MCD(key)=val) or Set(val=${MCD(key)}) etc
Let me know what you think.
I had some of my own code (which isn't very good i was bored and attempted to make a module) under asterisk/team/snuffy/func_memcached
I probably tried to 'over engineer' it allowing different memcache servers / duplicating memcache keys to multiple servers etc..
</pre>
<br />
<p>- Brad</p>
<br />
<p>On March 15th, 2011, 11:56 a.m., drivefast wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://reviewboard.asterisk.orgrb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for Asterisk Developers.</div>
<div>By drivefast.</div>
<p style="color: grey;"><i>Updated 2011-03-15 11:56:21</i></p>
<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;">memcached utilities for asterisk dialplans</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;">dialplan that touches all the functions and apps</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>/trunk/build_tools/menuselect-deps.in <span style="color: grey">(310878)</span></li>
<li>/trunk/configs/memcached.conf.sample <span style="color: grey">(PRE-CREATION)</span></li>
<li>/trunk/configure.ac <span style="color: grey">(310878)</span></li>
<li>/trunk/makeopts.in <span style="color: grey">(310878)</span></li>
<li>/trunk/res/res_memcached.c <span style="color: grey">(PRE-CREATION)</span></li>
</ul>
<p><a href="https://reviewboard.asterisk.org/r/1139/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>