A model for continuous query latencies in data streams