aboutsummaryrefslogtreecommitdiffstats
path: root/main/taskprocessor.c
AgeCommit message (Collapse)AuthorFilesLines
2008-11-15Merged revisions 157041 via svnmerge from russell1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ........ r157041 | russell | 2008-11-14 22:25:57 -0600 (Fri, 14 Nov 2008) | 3 lines Fix a few more places where the case insensitive hash should be used since the comparison is case insensitive. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.1@157042 f38db490-d61c-443f-a65b-d21fe96a405b
2008-08-29Merged revisions 140489 via svnmerge from mmichelson1-1/+1
https://origsvn.digium.com/svn/asterisk/trunk ................ r140489 | mmichelson | 2008-08-29 12:47:17 -0500 (Fri, 29 Aug 2008) | 30 lines Merged revisions 140488 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r140488 | mmichelson | 2008-08-29 12:34:17 -0500 (Fri, 29 Aug 2008) | 22 lines After working on the ao2_containers branch, I noticed something a bit strange. In all cases where we provide a callback function to ao2_container_alloc, the callback function would only return 0 or CMP_MATCH. After inspecting the ao2_callback() code carefully, I found that if you're only looking for one specific item, then you should return CMP_MATCH | CMP_STOP. Otherwise, astobj2 will continue traversing the current bucket until the end searching for more matches. In cases like chan_iax2 where in 1.4, all the peers are shoved into a single bucket, this makes for potentially terrible performance since the entire bucket will be traversed even if the peer is one of the first ones come across in the bucket. All the changes I have made were for cases where the callback function defined was passed to ao2_container_alloc so that calls to ao2_find could find a unique instance of whatever object was being stored in the container. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.1@140490 f38db490-d61c-443f-a65b-d21fe96a405b
2008-08-10That's all, folks. Not going to update the Makefile until res_jabber isseanbright1-4/+4
converted (snuffy, you there? :)) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@137110 f38db490-d61c-443f-a65b-d21fe96a405b
2008-08-06move taskprocessor CLI commands into the core namespacedhubbard1-9/+8
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@136245 f38db490-d61c-443f-a65b-d21fe96a405b
2008-06-23make solaris happy...pointed out by snuff-home on IRCdhubbard1-8/+8
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@124707 f38db490-d61c-443f-a65b-d21fe96a405b
2008-06-10Properly initialize the cli_ping condition and lockrussell1-1/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@121402 f38db490-d61c-443f-a65b-d21fe96a405b
2008-06-10Change system header includes to be like how it is done in other filesrussell1-2/+4
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@121401 f38db490-d61c-443f-a65b-d21fe96a405b
2008-06-09Initialize the lock and destroy lock and cond in the destructor (thanks, ↵twilson1-1/+6
mmichelson) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@121365 f38db490-d61c-443f-a65b-d21fe96a405b
2008-05-29Had to move the ASTERISK_FILE_VERSION decl to just after the include of ↵murf1-1/+2
"asterisk.h" or you get undefined variable errors when you are compiling under the influence of MTX_PROFILE git-svn-id: http://svn.digium.com/svn/asterisk/trunk@119074 f38db490-d61c-443f-a65b-d21fe96a405b
2008-05-15Use casts or intermediate variables to remove a numberrizzo1-1/+1
of platform/compiler-dependent warnings when handing struct timeval fields, both reading and printing them. It is a lost battle to handle the different ways struct timeval is handled on the various platforms and compilers, so try to be pragmatic and go through int/long which are universally supported. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@116557 f38db490-d61c-443f-a65b-d21fe96a405b
2008-05-03A taskprocessor is an object that has a name, a task queue, and an event ↵dhubbard1-0/+490
processing thread. Modules reference a taskprocessor, push tasks into the taskprocessor as needed, and unreference the taskprocessor when the taskprocessor is no longer needed. A task wraps a callback function pointer and a data pointer and is managed internal to the taskprocessor subsystem. The callback function is responsible for releasing task data. Taskprocessor API * ast_taskprocessor_get(..) - returns a reference to a taskprocessor * ast_taskprocessor_unreference(..) - releases reference to a taskprocessor * ast_taskprocessor_push(..) - push a task into a taskprocessor queue Check doxygen for more details git-svn-id: http://svn.digium.com/svn/asterisk/trunk@115268 f38db490-d61c-443f-a65b-d21fe96a405b