Re: apr_dbd: Support for multiple database connections from the same virtual host

2010-03-17 Thread Kevac Marko
Sorry for delay. Hope I will manage to find some time till monday. On Mon, Mar 8, 2010 at 5:45 PM, Kevac Marko ma...@kevac.org wrote: If someone is still interested, I can update bug with newer patch in a few days. On Mon, Mar 8, 2010 at 5:44 PM, Kevac Marko ma...@kevac.org wrote: Hello

Building httpd trunk. Problem with apr-util.

2010-03-14 Thread Kevac Marko
Hello. After cloning httpd git repository (mirror of svn one), I have tried to build trunk, but I don't know hot to tell build sripts what apr-util library to use. $ ./configure --with-apr=/usr/bin/apr-1-config

Re: Building httpd trunk. Problem with apr-util.

2010-03-14 Thread Kevac Marko
AM, Kevac Marko ma...@kevac.org wrote: Hello. After cloning httpd git repository (mirror of svn one), I have tried to build trunk, but I don't know hot to tell build sripts what apr-util library to use. $ ./configure

r-connection-aborted in mod_disk_cache and mod_mem_cache

2010-03-08 Thread Kevac Marko
Hello. Why this code is presented in disk cache, but not in mem cache? if (r-connection-aborted || r-no_cache) { ap_log_error(APLOG_MARK, APLOG_INFO, 0, r-server, disk_cache: Discarding body for URL %s because connection has

Re: apr_dbd: Support for multiple database connections from the same virtual host

2010-03-08 Thread Kevac Marko
Hello. Probably you are talking about my bug and my patch - https://issues.apache.org/bugzilla/show_bug.cgi?id=45456 As far as I know this patch was not been reviewed nor included to trunk. We are using mod_dbd with this patch (probably slightly improved over time) in production. On Mon, Mar

Re: apr_dbd: Support for multiple database connections from the same virtual host

2010-03-08 Thread Kevac Marko
If someone is still interested, I can update bug with newer patch in a few days. On Mon, Mar 8, 2010 at 5:44 PM, Kevac Marko ma...@kevac.org wrote: Hello. Probably you are talking about my bug and my patch - https://issues.apache.org/bugzilla/show_bug.cgi?id=45456 As far as I know

Re: Finding memory leaks in httpd and httpd modules

2010-02-16 Thread Kevac Marko
On Tue, Feb 16, 2010 at 2:10 PM, harish kulkarni wasinap...@gmail.com wrote: http://harishvk27.wordpress.com/2008/11/05/fixing-memory-leak-in-apache-mod_proxy/ Thank you. But I am surprised that no one uses valgrind. -- Marko Kevac Sent from Moscow, Mow, Russia

Re: Finding memory leaks in httpd and httpd modules

2010-02-16 Thread Kevac Marko
On Wed, Feb 17, 2010 at 12:49 AM, Sam Carleton scarle...@gmail.com wrote: I am in agreement with mcqueenorama.  I have not done a ton of module programming, but what I have done is HEAVILY used by my app and core to the whole thing.  My best advise is don't use the pools other then the request

Re: unsupported compression issue seen in 2.3.5-alpha

2010-02-15 Thread Kevac Marko
I don't know if this is connected, but we experience some problems with gzip compressing. Open http://www.micex.ru via Chrome and and hit shift + refresh button. Sometimes tables will not load (a little rotating circle will appear). These tables are loaded via AJAX and when they are not loaded,

Re: Using mod_rewrite in my authorization module. Need advice.

2010-02-04 Thread Kevac Marko
On Thu, Feb 4, 2010 at 10:52 AM, Sorin Manolache sor...@gmail.com wrote: Try to set an apache request note in the authentication instead of dynamically changing the configuration of mod_rewrite.c. Thus, you'll have something like RewriteRule /url %{ENV:destination} The configuration would

Re: Using mod_rewrite in my authorization module. Need advice.

2010-02-04 Thread Kevac Marko
On Thu, Feb 4, 2010 at 2:05 PM, Sorin Manolache sor...@gmail.com wrote: No, you cannot. The expansion does not work in the pattern (the second argument). But the second argument can be a regular expression. Hopefully you can write regexps for all your cases. Unfortunately I cannot. These

Using mod_rewrite in my authorization module. Need advice.

2010-02-03 Thread Kevac Marko
Hello. I am porting our authorization module to mpm_worker from mpm_prefork. This authorization module was using some ugly, but nevertheless working hack which messes with mod_rewrite configuration. This authorization module check user permissions for current url A and rewrites url to AA or AB

Re: Using mod_rewrite in my authorization module. Need advice.

2010-02-03 Thread Kevac Marko
Thanks a lot for your comments. I'll try to describe requirements for our authorization module and current implementation a little bit more. Requirements: 1. Authorization must happen before mod_cache (also a little bit fixed for our needs), so it must be executed in 'quick_handler'. This is

Generating a lot of data in content handler

2009-12-08 Thread Kevac Marko
Hello. I am doing a lot of ap_rprintf(r, ...) in my content handler, generating more than tens of megabytes of data per request. I suppose all this data is kept in r-pool, which is freed after request. So if one user consume 20 MiB, hundred will consume 2 GiB. How can I generate a lot of data

Re: Probably OT. Difficulty implementing content handler Apache2

2009-07-14 Thread Kevac Marko
Check for segmentation faults in global error-log. -- Marko Kevac Gilda Radner - Adopted kids are such a pain - you have to teach them how to look like you. - http://www.brainyquote.com/quotes/authors/g/gilda_radner.html

Memory and pools

2009-06-30 Thread Kevac Marko
Hello Is memory (RSS) returned to OS after cleaning pool (for example r-pool)? After destroying pool? My module uses a lot of memory (~100 MiB). This memory is taken from r-pool. But after request is finished, this memory is not returned to OS - RSS is 100 MiB. Linux 2.6 - httpd-2.2.10 --

Re: build mod_proxy by source

2009-06-22 Thread Kevac Marko
apxs -c -o mod_proxy.so mod_proxy.c proxy_util.c On Mon, Jun 22, 2009 at 11:00 PM, h iroshan iroshanm...@gmail.com wrote: Hi All, I need to build mod_proxy by source rather than enable in the configuration. I dont know how to build it by apxs as it has two dependent files (proxy_util.c and

Re: build mod_proxy by source

2009-06-22 Thread Kevac Marko
-avoid-versionproxy_util.lo mod_proxy.lo $ ls -la .libs/mod_proxy.so -rwxr-xr-x 1 marko marko 177683 2009-06-23 01:30 .libs/mod_proxy.so On Tue, Jun 23, 2009 at 12:14 AM, h iroshan iroshanm...@gmail.com wrote: hi Kevac Marko, apxs -c -o mod_proxy.so mod_proxy.c proxy_util.c above command

Re: mod_proxy_balancer dynamic change properties

2009-06-18 Thread Kevac Marko
On Wed, Jun 17, 2009 at 12:39 PM, h iroshaniroshanm...@gmail.com wrote: Hi kevac Marko, Thank you very much .I just want to do the same thing  here. My workers are Tomcat and I am going to change lbfactor  according to there Memory usage.Can we use normal socket connection to retrieve

Re: mod_proxy_balancer dynamic change properties

2009-06-17 Thread Kevac Marko
Yes, you can do that. We wrote module that changes loadfactor in accordance to machine load. On Wed, Jun 17, 2009 at 12:12 AM, h iroshaniroshanm...@gmail.com wrote: Hi Rüdiger, thanks lot , I  already followed the source code of the mod_cluster. Its uses another shared memory implementation

Re: mod_proxy. mod_proxy_balancer and failovers

2009-06-04 Thread Kevac Marko
So, do we have any conclusion? Should I make modifications and post patch? -- Marko Kevac

Re: mod_proxy. mod_proxy_balancer and failovers

2009-06-04 Thread Kevac Marko
On Thu, Jun 4, 2009 at 4:32 PM, Jim Jagielski j...@jagunet.com wrote: Sure... no guarantees that they'll be applied, but it would be useful to see what you have in mind. Huh. I thought it would be easy as fixing just mod_proxy.c, but... It occurred that mod_proxy_http thinks that, for example,

Re: Making HTTP requests

2009-06-02 Thread Kevac Marko
I am using CURL. On Mon, Jun 1, 2009 at 9:01 PM, Michael Spiegle m...@nauticaltech.com wrote: Is there a proper/defined way to use mod_proxy for this, or should I just move forward with cURL? -- Marko Kevac

mod_proxy. mod_proxy_balancer and failovers

2009-06-02 Thread Kevac Marko
Hello. I am using mod_proxy and mod_proxy_balancer for proxying requests to group of workers. Recentry I have stumbled upon issues with failover retries when worker returns error. For example I have balancer with 10 equal workers. One of them breaks and for 1 of 10 requests return

Re: mod_proxy. mod_proxy_balancer and failovers

2009-06-02 Thread Kevac Marko
On Tue, Jun 2, 2009 at 3:49 PM, Plüm, Rüdiger, VF-Group ruediger.pl...@vodafone.com wrote: A 404 is no error regarding balancing and a proper HTTP response by the backend. You need to send back a HTTP_INTERNAL_ERROR or a HTTP_SERVICE_UNAVAILABLE in this case but without any error page. Who

Re: mod_proxy. mod_proxy_balancer and failovers

2009-06-02 Thread Kevac Marko
On Tue, Jun 2, 2009 at 3:49 PM, Plüm, Rüdiger, VF-Group ruediger.pl...@vodafone.com wrote: A 404 is no error regarding balancing and a proper HTTP response by the backend. You need to send back a HTTP_INTERNAL_ERROR or a HTTP_SERVICE_UNAVAILABLE in this case but without any error page.

Re: mod_proxy. mod_proxy_balancer and failovers

2009-06-02 Thread Kevac Marko
On Tue, Jun 2, 2009 at 4:15 PM, Nick Kew n...@webthing.com wrote: How is the balancer supposed to know that one valid HTTP response is an error while another is correct?  A 404 or other error response doesn't mean there's a problem with the server! These HTTP responses can be configured in

Re: mod_proxy. mod_proxy_balancer and failovers

2009-06-02 Thread Kevac Marko
On Tue, Jun 2, 2009 at 4:15 PM, Nick Kew n...@webthing.com wrote: How is the balancer supposed to know that one valid HTTP response is an error while another is correct?  A 404 or other error response doesn't mean there's a problem with the server! Sorry, didn't fully understood your question.

Re: mod_proxy. mod_proxy_balancer and failovers

2009-06-02 Thread Kevac Marko
On Tue, Jun 2, 2009 at 6:08 PM, Rainer Jung rainer.j...@kippdata.de wrote: You have chosen an especially problematic example. If a not found triggers error status for the worker, then you will have continuous denial of service. Nearly every productive web server I know of, has every now and

Re: [PATCH] mod_dbd: execute SQL statements after DB connection has been established

2009-04-27 Thread Kevac Marko
Anything new? -- Marko Kevac

Re: [PATCH] mod_dbd: execute SQL statements after DB connection has been established

2009-04-27 Thread Kevac Marko
On Mon, Apr 27, 2009 at 11:50 AM, Nick Kew n...@webthing.com wrote: What, since http://svn.apache.org/viewvc?view=revrevision=766938 ? Wow. I didn't know about that. Thanks. Than i will go with mod_dbd pool patches soon. -- Marko Kevac

Re: [PATCH] mod_dbd: execute SQL statements after DB connection has been established

2009-04-18 Thread Kevac Marko
Is this now looking good, Nick? -- Marko Kevac

How to parse POST arguments?

2009-04-16 Thread Kevac Marko
Hello 1. How to parse POST arguments? 2. Why there is no functions to parse GET and POST arguments in Apache? Thanks. -- Marko Kevac

Re: [PATCH] mod_dbd: execute SQL statements after DB connection has been established

2009-04-16 Thread Kevac Marko
On Tue, Apr 14, 2009 at 1:16 AM, Nick Kew n...@webthing.com wrote: On 12 Apr 2009, at 16:36, Kevac Marko wrote: https://issues.apache.org/bugzilla/show_bug.cgi?id=46827 This patch adds ability to the mod_dbd Apache module to execute any SQL statements after DB connection have been

[PATCH] mod_dbd: execute SQL statements after DB connection has been established

2009-04-12 Thread Kevac Marko
https://issues.apache.org/bugzilla/show_bug.cgi?id=46827 This patch adds ability to the mod_dbd Apache module to execute any SQL statements after DB connection have been established. Patch is against httpd trunk. Configuration example: DBDriver mysql DBDParams

Re: AP_FTYPE_PROTOCOL before AP_FTYPE_CONTENT_SET sometimes in 2.2.10

2009-04-02 Thread Kevac Marko
Fixed. It's because i didn't called ap_remove_output_filter(f). Why should I call this from within filter itself? On Wed, Apr 1, 2009 at 5:48 PM, Kevac Marko ma...@kevac.org wrote: Hello. ap_http_header_filter (AP_FTYPE_PROTOCOL) sometimes executed before my AP_FTYPE_CONTENT_SET filter

AP_FTYPE_PROTOCOL before AP_FTYPE_CONTENT_SET sometimes in 2.2.10

2009-04-01 Thread Kevac Marko
Hello. ap_http_header_filter (AP_FTYPE_PROTOCOL) sometimes executed before my AP_FTYPE_CONTENT_SET filter. Any clue how that can happen? As a result, my output header in not added. 2.2.10 -- Marko Kevac

Re: [PATCH] mod_dbd with more than one pool

2009-03-31 Thread Kevac Marko
Nick, any news? On Fri, Mar 13, 2009 at 3:54 PM, Nick Kew n...@webthing.com wrote: Thanks.  I'll test-drive today. -- Marko Kevac

Re: [PATCH] mod_dbd with more than one pool

2009-03-27 Thread Kevac Marko
On Tue, Mar 24, 2009 at 10:03 PM, Ronald Park rkpar...@gmail.com wrote: A user might presume that the order of commands listed in the config file would be preserved when the commands are run.  By using a hash table, you'll likely get a random order causing problems.  For example, perhaps the

Re: [PATCH] mod_dbd with more than one pool

2009-03-18 Thread Kevac Marko
On Fri, Mar 13, 2009 at 2:54 PM, Nick Kew n...@webthing.com wrote: Thanks.  I'll test-drive today. Succeeded? -- Marko Kevac

mod_dbd and lost of connection to server

2009-03-16 Thread Kevac Marko
Hello. If our server connection is persisted, than connection is created right away and kept under the hood. If something happens to this connection (server timeout for example) than acquire will return NULL first time. Second time it will recreate connection. Maybe it is better to recreate this

Re: [PATCH] mod_dbd with more than one pool

2009-03-13 Thread Kevac Marko
On Tue, Mar 10, 2009 at 10:45 PM, Nick Kew n...@webthing.com wrote: Can I throw an alternative suggestion into the ring. Instead of running dbd_init_sql_init at the end of dbd_construct, run a hook there.  Your function then runs on that hook, but it enables other modules to do their own

Re: [PATCH] mod_dbd with more than one pool

2009-03-10 Thread Kevac Marko
Ok, here is sql init statement only patch against trunk: https://issues.apache.org/bugzilla/show_bug.cgi?id=46827 P.S. Thanks http://jukka.zitting.name/git/ for git mirrors. I am happy :-) P.P.S. Probably I should wait for sql init statement only patch inclusion before posting everything else?

Re: [PATCH] mod_dbd with more than one pool

2009-03-10 Thread Kevac Marko
On Fri, Mar 6, 2009 at 7:58 PM, Chris Darroch chr...@pearsoncmg.com wrote:  One thought I had overnight is that you might, if you like, want to tackle the init SQL patch first, which seems unrelated to the multiple pools idea and significantly simpler, easier to review, and probably easier to

Re: [PATCH] mod_dbd with more than one pool

2009-03-10 Thread Kevac Marko
On Thu, Mar 5, 2009 at 10:05 PM, Chris Darroch chr...@pearsoncmg.com wrote:  One difference, I think -- again, after only a quick review -- is that what I was trying to solve with the notion of a DBDGroup container and then a DBDGroup directive was to minimize the number of distinct

Re: mod_dbd analogue for memcached

2009-03-10 Thread Kevac Marko
On Thu, Mar 5, 2009 at 6:53 PM, Brian Akins br...@akins.org wrote: Is this based on the existing mod_memcache? After some observation of apr_memcache I have realized that mod_dbd pools are not needed here, because apr_memcache have own pools to each memcache server. So it can be based on

Re: mod_dbd analogue for memcached

2009-03-10 Thread Kevac Marko
On Tue, Mar 10, 2009 at 8:49 PM, josh rotenberg joshrotenb...@gmail.com wrote: I'm just catching up, but I'd be happy to add some of this functionality to mod_memcache. Great. I think I'll send patch on this week. mod_memcache is not in httpd, so, probably, we should continue our talk

Re: [PATCH] mod_dbd with more than one pool

2009-03-06 Thread Kevac Marko
There are some bugs in non-threaded build. I am fixing them right now. -- Marko Kevac

mod_dbd analogue for memcached

2009-03-05 Thread Kevac Marko
Hello I've created mod_dbd analogue for memcached (named connection pools to memcached servers, see also http://www.mail-archive.com/d...@httpd.apache.org/msg42922.html). It's now based on libmemcached (http://tangent.org/552/libmemcached.html). The question I want to ask is should I base my

Re: [PATCH] mod_dbd with more than one pool

2009-03-05 Thread Kevac Marko
On Thu, Feb 12, 2009 at 12:56 AM, Nick Kew n...@webthing.com wrote: Sounds OK in principle for trunk.  If you want to post a patch against trunk, I'll try and find the time to review it. Here I am again. The patch works well for us. Is there something else that I can do for now? -- Marko

mod_dbd analogue for memcached

2009-03-05 Thread Kevac Marko
Hello I've created mod_dbd analogue for memcached (named connection pools to memcached servers, see also http://www.mail-archive.com/dev@httpd.apache.org/msg42922.html). It's now based on libmemcached (http://tangent.org/552/libmemcached.html). The question I want to ask is should I base my

Re: mod_dbd analogue for memcached

2009-03-05 Thread Kevac Marko
On Thu, Mar 5, 2009 at 6:53 PM, Brian Akins br...@akins.org wrote: Is this based on the existing mod_memcache? No. It is based on mod_dbd. New one (http://www.mail-archive.com/dev@httpd.apache.org/msg42922.html) to be precise. mod_memcache, if we are talking about

Re: [PATCH] mod_dbd with more than one pool

2009-03-05 Thread Kevac Marko
Chris, thank you. I am impressed. I'm not experienced in commiting patches to open source projects, so I am very thankful for your comments. I'll try to fix things up very soon. 80 columns is a little bit ancient requirement in the world of 22 LCDs, but ok, i'll fix that too. -- Marko Kevac

Re: mod_dbd analogue for memcached

2009-03-05 Thread Kevac Marko
On Fri, Mar 6, 2009 at 2:02 AM, M. Brian Akins br...@akins.org wrote: Will you implement a default pool like mod_dbd does? Yes This feature enables us to create dynamic, not static servers list. For high availability clusters for example. Sounds interesting, I suppose. I just generate my

Re: [PATCH] mod_dbd with more than one pool

2009-02-11 Thread Kevac Marko
Now for every exported function we have pair of functions that accepts pool_name and old one, which is just wrapper: DBD_DECLARE_NONSTD(ap_dbd_t*) ap_dbd_open_pool(apr_pool_t *pool, server_rec *s, const char *pool_name); DBD_DECLARE_NONSTD(ap_dbd_t*) ap_dbd_open(apr_pool_t *pool,

Re: [PATCH] mod_dbd with more than one pool

2009-02-11 Thread Kevac Marko
On Thu, Feb 12, 2009 at 12:43 AM, Brian Akins br...@akins.org wrote: I was looking to do the same thing to mod_memcache (which should be imported into trunk, IMO...) kni...@juffin:~/micex/git/apache$ tree modules/memcache/ modules/memcache/ |-- SConscript |-- mod_memcache.c `-- mod_memcache.h

Re: Profiling Apache

2009-01-30 Thread Kevac Marko
On Wed, Jan 28, 2009 at 9:25 AM, Paras Fadte plf...@gmail.com wrote: Which tool is the most suitable for profiling Apache ? gprof ? Oprofile ? Used valgrind and gpt. -- Marko Kevac

Regular expression matching for multi line strings...

2008-12-22 Thread Kevac Marko
) What i am doing wrong? Thanks. -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Unit testing

2008-12-12 Thread Kevac Marko
Hello. What is the best way to write unit tests for C apache modules? Maybe some frameworks? -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Re: new modules in trunk

2008-12-01 Thread Kevac Marko
yours, Kevac Marko

Re: Howto implement a new algorithm scheduler in mod_proxy_balancer

2008-10-22 Thread Kevac Marko
this message in context: http://www.nabble.com/Howto-implement-a-new-algorithm-scheduler-in-mod_proxy_balancer-tp20082207p20117149.html Sent from the Apache HTTP Server - Module Writers mailing list archive at Nabble.com. -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Re: Access configuration variable in other modules

2008-09-13 Thread Kevac Marko
build system, sorry. I still mantain my fork of mod_dbd separarely. -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Re: Access configuration variable in other modules

2008-09-13 Thread Kevac Marko
уважением, Кевац Марко Sincerely yours, Kevac Marko

What should i do to bring attention to the bug?

2008-08-25 Thread Kevac Marko
-- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Re: Child init process is not initialized with the data stored by master process

2008-07-24 Thread Kevac Marko
] wrote: Which is the problem? -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Re: mod_dbd and more than one database server

2008-07-11 Thread Kevac Marko
On Thu, Jul 10, 2008 at 7:18 AM, Kevac Marko [EMAIL PROTECTED] wrote: Thank you, but i need pool of connections too. So i think i'll fix mod_dbd to allow more than one connection pool and slightly change api to allow choosing pool of connections. I am planning to implement something like

Re: mod_dbd and more than one database server

2008-07-09 Thread Kevac Marko
always open ad-hoc database connections directly using the apr-util functions apr_dbd_get_driver(), apr_dbd_open_ex(), apr_dbd_close(), etc. instead of using the pool of connections provided by mod_dbd. -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Re: [可能是垃圾邮件] Re: how to catch segment fault

2008-06-25 Thread Kevac Marko
. can you tell me how to change startup script -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

Re: how to catch segment fault

2008-06-24 Thread Kevac Marko
how to change startup script -- С уважением, Кевац Марко Sincerely yours, Kevac Marko

ap_auth_type(r) problem

2008-06-21 Thread Kevac Marko
that mod_mycache is executed from quick handler? -- С уважением, Кевац Марко Sincerely yours, Kevac Marko