Summary: | add IP TOS support to apr_socket_opt_set() | ||
---|---|---|---|
Product: | APR | Reporter: | Jeremy Jackson <jerj> |
Component: | APR | Assignee: | Apache Portable Runtime bugs mailinglist <bugs> |
Status: | NEW --- | ||
Severity: | enhancement | CC: | philipp, poeml |
Priority: | P2 | Keywords: | PatchAvailable |
Version: | HEAD | ||
Target Milestone: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Bug Depends on: | |||
Bug Blocks: | 48361, 49553, 49997 | ||
Attachments: |
Patch to add SOL_IP/IP_TOS support to apr_socket_opt_set()
Patch to have mod_ftp use the apr_socket_opt_set() interface for IP ToS Patch to add SOL_IP/IP_TOS support to apr_socket_opt_set() Patch to add SOL_IP/IP_TOS support to apr_socket_opt_set() Add QoS support to APR. Add QoS support to APR. Updated patch for QoS support including autoconf hooks |
Description
Jeremy Jackson
2007-07-10 16:01:01 UTC
There is a patch but I am not the original author, see URL for details. Created attachment 24685 [details]
Patch to add SOL_IP/IP_TOS support to apr_socket_opt_set()
I couldn't find the originally mentioned patch in the comments (seems to be an invalid link).
This is only reasonable to consider if we map the solaris equivilants and truly offer portable TOS control. Of course; whos do we 'advertise' in terms of the API? mod_ftp already supports both API's but didn't attempt to abstract it; c.f. http://svn.apache.org/repos/asf/httpd/mod_ftp/trunk/modules/ftp/ftp_data_connection.c Created attachment 24687 [details]
Patch to have mod_ftp use the apr_socket_opt_set() interface for IP ToS
Added to STATUS; note the reporter mixed up my reference, it is a pointer to provide BOTH TOS control API's, not a request for the patch to use this 1/2 of an implementation :) Will work up the proper patch, just placing this in STATUS so it isn't dropped. (In reply to comment #5) > Added to STATUS; note the reporter mixed up my reference, it is a pointer to > provide BOTH TOS control API's, not a request for the patch to use this 1/2 > of an implementation :) > > Will work up the proper patch, just placing this in STATUS so it isn't dropped. Not quite sure what you're saying. ToS (i.e. the dangerously obsolete RFC-791 meaning of the ToS and precedence bits) and QoS both use the same API. The only difference is what bits are passed in this 8-bit field, and how the underlying network fabric chooses to interpret them. Note also that the bit 0x02 (IPTOS_LOWCOST) may not be supported by a lot of Linuxen: as per RFC 3168, section 5, the low-order 2 bits of the ip_tos field are reserved now for Explicit Congestion Notification, and are ignored (actually, "clobbered" if set) by Linux 2.6.20 and later. So to reiterate, there's one API, because only one is needed. There is no point in having two, because interpretation of the bits as QoS or ToS isn't done on the end-system, it's done in the network fabric... well beyond the reach of any OS API. The Network behavior is identically. The C preprocessor constant names vary, you can refer to Stevens, UNIX Network Programming for reference. Or you could have just stolen the config detection code and conditionals I already researched, and pointed you to in mod_ftp. But arguing against compile portability in a portability library doesn't help :-/ (In reply to comment #7) > The Network behavior is identically. > > The C preprocessor constant names vary, you can refer to Stevens, UNIX Network > Programming for reference. Or you could have just stolen the config detection > code and conditionals I already researched, and pointed you to in mod_ftp. > But arguing against compile portability in a portability library doesn't help > :-/ So, again, I wasn't arguing. I was trying to figure out what you were saying. Hence starting with, "Not quite sure what you're saying." Ok, I think I understand. You're worried about the SOL_IP vs. IPPROTO_IP issue in Linux vs. BSD. Created attachment 25156 [details]
Patch to add SOL_IP/IP_TOS support to apr_socket_opt_set()
Redone for Solaris/BSD portability.
Hmmm... See also: https://sourceforge.net/tracker/?func=detail&atid=350976&aid=2915224&group_id=976 for at least one way to add autoconf support for detecting SOL_IP. Though I suspect there's a simpler way to do it with just AC_TRY_CPP(). Warning; comment #10 references GPL code. Dropping consideration of this submission; contributions must be compatible with the Apache License. reverting to the originally proposed http://qaix.com/apache-http-server/569-729-patch-add-ip-tos-support-read.shtml plus mod_ftp's support of solaris+linux. Created attachment 25211 [details]
Patch to add SOL_IP/IP_TOS support to apr_socket_opt_set()
Can you please update this bug report with a list of all blocking issues? Created attachment 25699 [details]
Add QoS support to APR.
As per William's comments that this previously didn't compile under Solaris (which doesn't have self-including header files).
Created attachment 25700 [details]
Add QoS support to APR.
Created attachment 27793 [details]
Updated patch for QoS support including autoconf hooks
Updating for the last year's worth of changes on trunk...
Offered a /bump on dev@apr in anticipation of a 1.6.0 tag. Re-reviewing, myself. |