https://issues.apache.org/bugzilla/show_bug.cgi?id=50551

--- Comment #6 from [email protected] 2011-05-19 11:28:09 UTC ---
Created attachment 27034
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=27034
DNS recheck patch

Please find attached a patch which addresses the DNS chaching issue.

This is a description of the approach used:
1. As I didn't find any place where I could put an arbitrarily executed timer,
I decided to go with a Boolean option to enable/disable the DNS address issue
resolving. I have kept the option by now to be a timer however, to be able to
change it if someone tells me how to implement it.
2. I have put the handling code into the function ap_proxy_release_connection()
of module proxy_util.c
3. The code makes a call to apr_sockaddr_info_get() to check if the destination
address has changed. If it has changed, the change is propagated to all places
I thought to be relevant and then the connection in question is marked as being
due to be closed.

There are several issues with the patch however, since I am by no means
experienced enough with the Apache code to make sure it is the best solution.
The main issues I can think of (And you will for sure find others) are:
A. Is this the right place to put such a check?
B. Is it possible to have a timer to do this check instead?
C. Is the pool handling correct or does it lead to a memory leak?
D. Is the method to clean up and close the connections with obsolete ip
addresses (the last four lines of the code above the call to
connection_cleanup(conn, s)) the right approach?

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to