提交 4cc2f98d 编写于 作者: F fjy

Merge pull request #537 from metamx/remove-initial-delay-polling

remove initial delay from polling
......@@ -106,7 +106,7 @@ public class DatabaseSegmentManager
final Duration delay = config.get().getPollDuration().toStandardDuration();
ScheduledExecutors.scheduleWithFixedDelay(
exec,
delay,
new Duration(0),
delay,
new Runnable()
{
......
......@@ -106,7 +106,7 @@ public class DatabaseSegmentManagerTest
@Test
public void testPoll()
{
EasyMock.expect(dbi.withHandle(EasyMock.<HandleCallback>anyObject())).andReturn(testRows);
EasyMock.expect(dbi.withHandle(EasyMock.<HandleCallback>anyObject())).andReturn(testRows).times(2);
EasyMock.replay(dbi);
manager.start();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册