You are viewing a plain text version of this content. The canonical link for it is here.
Posted to docs@httpd.apache.org by Daniel Gruno <ru...@cord.dk> on 2012/04/11 10:15:03 UTC

Document on developing modules for 2.4 and onwards

Hello all httpd document lovers,
As per our nifty little STATUS document, it came to my attention that we
were missing an introductory segment on how to develop simple modules
for httpd 2.4, so I took the liberty of drawing up a proposal for what
we could put in place for this request. The draft is located at
http://httpd.apache.org/docs/trunk/developer/modguide.html and I would
much appreciate it if you guys could give me some feedback on whether
this will fit in as an, at least for the time being, appropriate
document to describe how to develop modules for the server.

I plan to expand on the subject, probably add another 10 pages or so,
during the summer, as well as letting it into the 2.4 fold, provided I
get positive feedback from this mailing list.

So, please do read the document and tell me what you think :)
Any suggestions, critique etc you might have will be warmly accepted.

With regards,
Daniel.

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


Re: Fwd: Document on developing modules for 2.4 and onwards

Posted by Daniel Gruno <ru...@cord.dk>.
On 11-04-2012 16:46, rm@tuxteam.de wrote:
> Nice work, and I bet it'll be helpful for new module authors. Just a
> small bug: in your example on configuration setting, in the function
> 'example_create_dir_conf(...)' your code returns 'dir' which isn't
> declared in function scope. Shouldn't this read 'return cfg;' ???
> Cheers, Ralf Mattes
Yes, of course it should - fixed, thanks! :)

As per the strcpy, it's really not a concern, since the path isn't a
file path per se, but instead gets to hold one of two values; "Merged
configuration" or "Newly created configuration" at this point. But I
should probably look at casting properly, yeah, so I'll go fix that next.

With regards,
Daniel.

Re: Fwd: Document on developing modules for 2.4 and onwards

Posted by rm...@tuxteam.de.
On Wed, Apr 11, 2012 at 11:12:31AM +0200, Daniel Gruno wrote:
> As per Igor's advice, I'm forwarding this message to the dev@ and
> modules-dev@ lists as well:
> ------------------------------------------------------------------------
> 
> Hello all httpd document lovers,
> As per our nifty little STATUS document, it came to my attention that we
> were missing an introductory segment on how to develop simple modules
> for httpd 2.4, so I took the liberty of drawing up a proposal for what
> we could put in place for this request. The draft is located at
> http://httpd.apache.org/docs/trunk/developer/modguide.html and I would
> much appreciate it if you guys could give me some feedback on whether
> this will fit in as an, at least for the time being, appropriate
> document to describe how to develop modules for the server.
> 
> I plan to expand on the subject, probably add another 10 pages or so,
> during the summer, as well as letting it into the 2.4 fold, provided I
> get positive feedback from this mailing list.
> 
> So, please do read the document and tell me what you think :)
> Any suggestions, critique etc you might have will be warmly accepted.

Nice work, and I bet it'll be helpful for new module authors.
Just a small bug: in your example on configuration setting, in the
function 'example_create_dir_conf(...)' your code returns 'dir' which
isn't declared in function scope. Shouldn't this read 
'return cfg;' ???

 Cheers, Ralf Mattes

> With regards,
> Daniel.

Re: Fwd: Document on developing modules for 2.4 and onwards

Posted by rm...@tuxteam.de.
On Wed, Apr 11, 2012 at 11:12:31AM +0200, Daniel Gruno wrote:
> As per Igor's advice, I'm forwarding this message to the dev@ and
> modules-dev@ lists as well:
> ------------------------------------------------------------------------
> 
> Hello all httpd document lovers,
> As per our nifty little STATUS document, it came to my attention that we
> were missing an introductory segment on how to develop simple modules
> for httpd 2.4, so I took the liberty of drawing up a proposal for what
> we could put in place for this request. The draft is located at
> http://httpd.apache.org/docs/trunk/developer/modguide.html and I would
> much appreciate it if you guys could give me some feedback on whether
> this will fit in as an, at least for the time being, appropriate
> document to describe how to develop modules for the server.
> 
> I plan to expand on the subject, probably add another 10 pages or so,
> during the summer, as well as letting it into the 2.4 fold, provided I
> get positive feedback from this mailing list.
> 
> So, please do read the document and tell me what you think :)
> Any suggestions, critique etc you might have will be warmly accepted.
> 
> With regards,
> Daniel.


More comments: first, it might be a matter of style (or good habbits)
but i think you should cast void pointers to the correct type in your
code. So:

 example_config* base = BASE ;

should be:

 example_config* base = (example_config*) BASE ;

A real bug? 

  strcpy(conf->path, strlen(add->path) ? add->path : base->path);

Don't you mean strncpy here?
BTW, 'char path[256];' is pretty dangerous, there are OS/Compiler
constants that provide the operating sytem's max path length.

Cheers, RalfD


 

Fwd: Document on developing modules for 2.4 and onwards

Posted by Daniel Gruno <ru...@cord.dk>.
As per Igor's advice, I'm forwarding this message to the dev@ and
modules-dev@ lists as well:
------------------------------------------------------------------------

Hello all httpd document lovers,
As per our nifty little STATUS document, it came to my attention that we
were missing an introductory segment on how to develop simple modules
for httpd 2.4, so I took the liberty of drawing up a proposal for what
we could put in place for this request. The draft is located at
http://httpd.apache.org/docs/trunk/developer/modguide.html and I would
much appreciate it if you guys could give me some feedback on whether
this will fit in as an, at least for the time being, appropriate
document to describe how to develop modules for the server.

I plan to expand on the subject, probably add another 10 pages or so,
during the summer, as well as letting it into the 2.4 fold, provided I
get positive feedback from this mailing list.

So, please do read the document and tell me what you think :)
Any suggestions, critique etc you might have will be warmly accepted.

With regards,
Daniel.


Fwd: Document on developing modules for 2.4 and onwards

Posted by Daniel Gruno <ru...@cord.dk>.
As per Igor's advice, I'm forwarding this message to the dev@ and
modules-dev@ lists as well:
------------------------------------------------------------------------

Hello all httpd document lovers,
As per our nifty little STATUS document, it came to my attention that we
were missing an introductory segment on how to develop simple modules
for httpd 2.4, so I took the liberty of drawing up a proposal for what
we could put in place for this request. The draft is located at
http://httpd.apache.org/docs/trunk/developer/modguide.html and I would
much appreciate it if you guys could give me some feedback on whether
this will fit in as an, at least for the time being, appropriate
document to describe how to develop modules for the server.

I plan to expand on the subject, probably add another 10 pages or so,
during the summer, as well as letting it into the 2.4 fold, provided I
get positive feedback from this mailing list.

So, please do read the document and tell me what you think :)
Any suggestions, critique etc you might have will be warmly accepted.

With regards,
Daniel.


Re: Document on developing modules for 2.4 and onwards

Posted by Tim Bannister <is...@jellybaby.net>.
On 11 Apr 2012, at 09:15, Daniel Gruno wrote:

> As per our nifty little STATUS document, it came to my attention that we were missing an introductory segment on how to develop simple modules for httpd 2.4, so I took the liberty of drawing up a proposal for what we could put in place for this request. The draft is located at http://httpd.apache.org/docs/trunk/developer/modguide.html and I would much appreciate it if you guys could give me some feedback on whether  this will fit in as an, at least for the time being, appropriate document to describe how to develop modules for the server.

I'm fairly new to httpd development as well as to writing for 2.4. To me, the draft is structured well and was very easy to understand.

-- 
Tim Bannister – isoma@jellybaby.net


Re: Document on developing modules for 2.4 and onwards

Posted by Igor Galić <i....@brainsware.org>.
> I plan to expand on the subject, probably add another 10 pages or so,
> during the summer, as well as letting it into the 2.4 fold, provided
> I
> get positive feedback from this mailing list.

I think dev@ -- and modules-dev@ are the righter lists to
get the kind of feedback you wish for.
We might wanna put them in the loop.
 
i

-- 
Igor Galić

Tel: +43 (0) 664 886 22 883
Mail: i.galic@brainsware.org
URL: http://brainsware.org/
GPG: 6880 4155 74BD FD7C B515  2EA5 4B1D 9E08 A097 C9AE


---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org