[asterisk-users] Custom PHP for Call Files

Dale Noll dnoll at wi.rr.com
Mon Dec 28 09:06:36 CST 2015


On Mon, Dec 28, 2015 at 7:42 AM, Eherr <email.eherr9633 at gmail.com> wrote:

> Thanks Dale!
>
> I will try your method in the one web directory.
>
> Also while I was waiting for a response, I decided to start from scratch
> in a different web directory and rewrite my code for a database based
> system.
>
> I am writing so that the system inserts into table the extension and time
> of call with those two grouped with a unique key to avoid duplicates.
>
> Then have a cron check every minute to move any files with time of call
> datertime as current to the outgoing directory.
>
> I have been considering two methods
> 1 - create the call file and leave in directory where Apache can write to.
> Then put the uniqueID of the call file into the database so when cron runs,
> it'll grab the file name and move that file to outgoing/
>
> 2- run cron and when it gets time for the call file, have the perl grab
> the extension and write the call file then and there and then move it to
> outgoing/ and deleting the database entry.
>
> I currently going for option 2.
>
> Is there any benefit in a database driven application or does best
> practices favor the original directory permissions?
>
> I am not expecting a high level of wake up calls. Maybe the most of 5-10
> in the system nightly.
>
> Thanks,
> --Eric
>
> Sent from my phone.
>
>

As to best practice or perceived benefits, that is really a matter of your
point of view, your comfort level and the comfort level of the End User or
System Administrator. A great technical solution that the end user/system
admin does not like to use is of no real value.

I like database driven solutions because of the easy update factor. No need
to touch the file system until you absolutely need to.  With my basic
understanding of your use case, I would probably for with option 2 as well.

Dale
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20151228/29589345/attachment.html>


More information about the asterisk-users mailing list