Welcome! Log In Create A New Profile

Advanced

Re: Breaking content generation phase into multiple phases or adding custom events in content phase

June 22, 2015 02:20AM
Thanks Yichun and Jeff for your inputs and sorry for late ack.

I had a brief look at ngx_drizzle, I see that it needs the library to
expose underlying fd, which is not possible in our case, but looks an
interesting solution. The other cosocket API mechanism seem to be using
unix domain socket as per the docs, so this would be similar to using
pipe/socket to handle async apis where the callback could trigger event on
the pipe/socket. Please correct me if am missing something? (never worked
on lua :) )

Use case is very similar to image optimization case in pagespeed. I am
guessing cosocket approach can also fit here?

@Jeff regarding using pipes to trigger event, does it create one pipe per
request or just one pipe where say module can
- trigger the async API,
- queue the nginx_request and proceed with other requests, (not sure this
is possible with nginx?, as i think nginx handler cannot return something
like NGX_AGAIN to resume handler where it called async api)
- when there is event on pipe, nginx pipe_event_handler can figure out
which request's data is ready and respond

Easiest approach I can think of is to use domain socket in upstream form,
but wanted to avoid as it it would mean additional socket descriptor per
request.

If you can help understand at design level w.r.t nginx, will be faster to
adapt :)

Thanks again!!
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

Breaking content generation phase into multiple phases or adding custom events in content phase

Kaustubh Deorukhkar 750 June 17, 2015 02:18PM

Re: Breaking content generation phase into multiple phases or adding custom events in content phase

Yichun Zhang (agentzh) 359 June 17, 2015 11:28PM

Re: Breaking content generation phase into multiple phases or adding custom events in content phase

Jeff Kaufman 613 June 18, 2015 07:08AM

Re: Breaking content generation phase into multiple phases or adding custom events in content phase

Yichun Zhang (agentzh) 344 June 18, 2015 11:08PM

Re: Breaking content generation phase into multiple phases or adding custom events in content phase

Jeff Kaufman 388 June 19, 2015 08:36AM

Re: Re: Breaking content generation phase into multiple phases or adding custom events in content phase

kaustubh 465 June 24, 2015 12:02AM

Re: Breaking content generation phase into multiple phases or adding custom events in content phase

kaustubh 447 June 22, 2015 02:20AM

Re: Breaking content generation phase into multiple phases or adding custom events in content phase

Jeff Kaufman 390 June 23, 2015 05:58AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 183
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready