GenStage consume events by time

Hello, everyone.

I’m using a GenStage to buffer then consume spikes of incoming demand. Is there a way to send these items/events to be consumed after a specified amount of time has passed or when the counter exceeds specified limit?

Thanks!