void (final @NotNull ImperativeCommand.Environment env) { try { while (true) { final int fileId = env.generateValue(Generator.integers(0, Integer.MAX_VALUE), "Generated fileId: %s"); final int attributeId = env.generateValue(Generator.integers(0, AbstractAttributesStorage.MAX_ATTRIBUTE_ID), "Generated attributeId: %s"); //RC: we can create >1 AttributeRecords with the same fileId/attributeId, which leads to // property failure (i.e. one of the record found not exist because another one was // deleted) -> prevents it: if (fileIdToAttributeId.get(fileId) == attributeId) { continue; } fileIdToAttributeId.put(fileId, attributeId); final AttributeRecord insertedRecord = attributes.insertOrUpdateRecord( AttributeRecord.newAttributeRecord(fileId, attributeId) .withRandomAttributeBytes(1029), storage ); records.add(insertedRecord); assertTrue( insertedRecord.existsInStorage(storage) ); return; } } catch (IOException e) { throw new AssertionError(e); } }