@Override
    public GitRepoResponse pushToGit(final GitRepoPushDto gitRepoPushDto) {
        Objects.requireNonNull(gitRepoPushDto);
        GitRepoResponse response;
        try {
            LOGGER.info("Pushing to Git repo: '{}'", gitRepoPushDto.getGitRepoDoc().getUrl());
            List<Message> messages = gitRepoStorageServiceProvider.get()
                            .exportDoc(gitRepoPushDto.getGitRepoDoc(),
                                       gitRepoPushDto.getCommitMessage(),
                                       true);
            response = this.createResponse(messages);
        } catch (Exception e) {
            response = new GitRepoResponse(false, e.getMessage());
        }
        return response;
    }
Called on the server when a REST request is received from the
UI for a Git Push.
@param gitRepoPushDto The DTO holding the info.
@return a GitRepoResponse with all the messages about
        whether it worked.
stroom-gitrepo/stroom-gitrepo-impl/src/main/java/stroom/gitrepo/impl/GitRepoResourceImpl.java