// Get a unique generation for this AIS, but will only be visible to owning session
validateForSession(session, newAIS, null);
// Again so no other transactions see the new one from validate
bumpGeneration(session);
// Save online schemas
TransactionState txn = txnService.getTransaction(session);
List<String> idPath = onlineDirPath(onlineSession.id);
DirectorySubspace idDir = openDirectory(txn, smDirectory, idPath);
txn.setBytes(idDir.pack(GENERATION_KEY), Tuple2.from(newAIS.getGeneration()).pack());
try {
DirectorySubspace protobufDir = idDir.createOrOpen(txn.getTransaction(), PROTOBUF_PATH).get();
ByteBuffer buffer = null;
for(String name : schemas) {
buffer = storeProtobuf(txn, protobufDir, buffer, newAIS, name);
}
} catch (RuntimeException e) {