About multiple flushes
Is there a way to do progressive rendering via multiple flushes?
Or can *fasthttp.Response implement http.Flusher interface?
I don't think so, you can see the code it's open. The Response struct doesn't have any .Flush method as I know... so If you want the Writer then you should check ctx.Response.BodyWriter() note that after handler is finished this object is reseting, so if you want to use it later you can copy it using ctx.Response.BodyWriteTo(awriter io.Writer) or copy the whole response using ctx.Response.CopyTo(destinationResponse *fasthttp.Response)
@kataras So this feature will not be added to fasthttp?
fasthttp has it's own methodology to handle these things, it doesn't need manual flush, but I really can't answer you with percision, just wait for a better answer from @valyala who mantains this package. Or just think how you could do that you want to do without Flush, take a closer look at the code I'm sure you will find the solution and when you do post the solution here to be visible to others
Is there a way to do progressive rendering via multiple flushes?
Yes - see RequestCtx.SetBodyStreamWriter. See the example for this function for details.
Very good valyala, can you add Iris to the readme.md and faq.md as with other frameworks? iris web framework is fasthttp based :rose:
@kataras , done.
@valyala Thanks you, I appreciate this!, again nice job with fasthttp all things you doing are excelent :)