Integration with redmine and integration with redmine
Redmine version 2.3.0
1. Open the rest web service
2. jar dependency
<dependency> <groupId>com.taskadapter</groupId> <artifactId>redmine-java-api</artifactId> <version>1.17</version></dependency>
3. Code
Public class test {public static void main (String [] args) {// TODO Auto-generated method stub RedmineManager mgr = new RedmineManager ("http: // xxxxxx/redmine ", "kongxianghao", "12345678"); try {tryGetIssues (mgr);} catch (Exception e) {e. printStackTrace () ;}} private static void tryGetIssues (RedmineManager mgr) throws Exception {// List <Project> list = mgr. getProjects (); Project project = mgr. getProjectByKey ("143"); // Tracker tk: project. getTrackers () {System. out. println (tk. getId () + "-->" + tk. getName ();} // List of project issues <Issue> issues = mgr. getIssues ("143", null); for (Issue issue: issues) {System. out. println (issue. getId () + issue. toString ());}}}