public long addReader(final FileReader reader) {
        final long readerId = this.nextId.getAndIncrement();
        if (this.fileReaderMap.putIfAbsent(readerId, reader) == null) {
            return readerId;
        } else {
            return -1L;
        }
    }
Adds a file reader and return it's generated readerId.
jraft-core/src/main/java/com/alipay/sofa/jraft/storage/FileService.java