@Override
    public Ticket updateTicket(final Ticket ticket) {
        FunctionUtils.doAndHandle(__ -> {
            LOGGER.debug("Updating ticket [{}]", ticket.getId());
            val ticketDocument = buildTicketAsDocument(ticket);
            val metadata = ticketCatalog.find(ticket);
            LOGGER.trace("Located ticket definition [{}] in the ticket catalog", metadata);
            val collectionName = getTicketCollectionInstanceByMetadata(metadata);
            LOGGER.trace("Found collection [{}] linked to ticket [{}]", collectionName, metadata);

            val writeResult = firestore.collection(collectionName)
                .document(ticketDocument.getTicketId())
                .update(ticketDocument.asUpdatableMap())
                .get();
            LOGGER.debug("Added ticket [{}] to [{}] @ [{}]", ticket.getId(), collectionName, writeResult.getUpdateTime());
        });
        return ticket;
    }
This is {@link GoogleCloudFirestoreTicketRegistry}.

@author Misagh Moayyed
@since 7.0.0
support/cas-server-support-gcp-firestore-ticket-registry/src/main/java/org/apereo/cas/ticket/registry/GoogleCloudFirestoreTicketRegistry.java