public static void main(String[] args) throws Exception { String name = TMP + "/chronicle"; Chronicle chronicle = new IndexedChronicle(name); DataStore dataStore = new DataStore(chronicle, ModelMode.MASTER); List<String> underlying = new ArrayList<String>(); int maxMessageSize = 128; ListWrapper<String> list = new ListWrapper<String>(dataStore, "testlist", String.class, underlying, maxMessageSize); dataStore.start(); for (int i = 0; i < 1000000; i++) { list.add(0, "hello" + i); list.add(1, "world" + i); list.remove(0); list.remove(1); // does nothing until second loop and leaves one elements } System.out.println("list.size(): " + list.size()); System.out.println("list: " + list); chronicle.close(); }