Added long polling support