Hi. I continue my work on urweb-callback. I've dropped the cgi/fastcgi support (as we have discussed with Adam). The code becomes much simpler, now it relies on the C++11 threads and requires almost nothing special from the urweb side.
https://github.com/grwlf/urweb-callback/tree/clonectx == Pathch1 == Still, in order to provide unified method of writing to log (like this place [1]), I've made some relatively simple changes to the urweb API interface. The summary of changes is: * Move struct loggers from request.h to urweb.h and remove uw_app* field from (it was required by client_pruner only) * Tweak the code here in there in request.c, move to new loggers * Add uw_get_loggers function to the urweb.h. Now FFI code can query uw_loggers and write to it. * Add separate data structure to pass to client_pruner thread Also the patch inserts #include "request.h" into request.c which should help to keep code safer. == Patch2 == urweb-callback uses -1 as the ctx->id at the moment since we can't (at least shouldn't) create client sources from the callback context. The patch just ensures that we notice this kind of errors. The patches are in attach, please consider reviewing/merging! Regards, Sergey [1] - https://github.com/grwlf/urweb-callback/blob/clonectx/CallbackFFI.cpp#L325
1_of_1_Define_uw_loggers_structure__allow_FFI_code_to_access_it.patch
Description: Binary data
1_of_1_Protect_uw_Basis_new_client_source_from_invalid_ctx__id.patch
Description: Binary data
_______________________________________________ Ur mailing list [email protected] http://www.impredicative.com/cgi-bin/mailman/listinfo/ur
