API_VERSION can be found by using either the
mod_rewrite.c module, or the
mod_info.c module. Here is how the mod_rewrite module defines it.
- This is the version of the Apache module API (the internal interface between server and module) in the current httpd build, as defined in include/ap_mmn.h. The module API version corresponds to the version of Apache in use (in the release version of Apache 1.3.14, for instance, it is 19990320:10), but is mainly of interest to module authors.
To find the Apache API Version, which tells us among other things the version of Apache being run, we can use the tricks detailed in the crazy advanced mod_rewrite tutorial to find it using .htaccess directives.
- Versions 1.3.1 and lower. Initializer for the first few module slots, which are only really set up once we start running. Note that the first word is a version check; this should allow us to deal with changes to the API (the server can detect an old-format module, and either handle it back-compatibly, or at least signal an error).
- Major API changes that could cause compatibility problems for older modules such as structure size changes. No binary compatibility is possible across a change in the major version.
- Minor API changes that do not cause binary compatibility problems. Should be reset to 0 when upgrading
November 25th, 2008