项目作者: severe-island

项目描述 :
svn-broker -- the part of project repository aggregator.
高级语言: Java
项目地址: git://github.com/severe-island/ra-svn-broker.git
创建时间: 2018-02-01T14:09:03Z
项目社区:https://github.com/severe-island/ra-svn-broker

开源协议:

下载


SVN-broker

Requirement

  • Java 8 (or higher)
  • Gradle 4.3.1 (or higher)

Building

Command for build:

  1. gradle build

Running

Commands for run (Windows and Linux):

  1. svn-broker

Using

The REST-service schema is in /specs/service.yaml (Swagger-compatible).

Warning!

Using POST-requests for /repositories requires the HTTP-headers:

  1. Content-Type: multipart/form-data; boundary=HereGoes

Testing

You can use for test SVN-repository of the Codeblocks project: http://svn.code.sf.net/p/codeblocks/code

First of all you need to register your repository in web-service. You can do it with Curl:

  1. curl -F "url=svn://svn.code.sf.net/p/codeblocks/code" \
  2. -F "id=codeblocks" \
  3. -H "Content-Type: multipart/form-data; boundary=HereGoes" \
  4. -X POST http://localhost:3003/repositories

After you can do GET-requests to repository using ID, which you noted on registration:

  • /repositories - shows a list of registered repositories;
  • /repositories/{id} - shows an overview information for repository with {id};
  • /repositories/{id}/commits - shows a list of commits for repository with {id};
  • /repositories/{id}/branches - shows a list of branches for repository with {id};
  • /repositories/{id}/commits/{commitId} - shows an overview information for commit named {commitId} in repository {id};
  • /repositories/{id}/branches/{branchId} - shows an overview information for branch named {branchId} in repository {id};

You can also run the Unit-tests:

  1. gradle test

Note: Some caching processes are working asynchronously and taking time. You can see info about it in warnings. Please, don’t stop web-service until they finished.