code: private void storeServerState(Consumer<KieServerState> kieServerStateConsumer) {
          KieServerState currentState = repository.load(KieServerEnvironment.getServerId());
          kieServerStateConsumer.accept(currentState);
          repository.store(KieServerEnvironment.getServerId(), currentState);
      }
docs: Persists updated KieServer state.
  @param kieServerStateConsumer