Package com.atlassian.jira.rest.client.internal.jersey

Examples of com.atlassian.jira.rest.client.internal.jersey.JerseyJiraRestClientFactory


    private final JiraRestClient client;
   
    public AbstractJIRAProducer(JIRAEndpoint endpoint) throws Exception {
        super(endpoint);
       
        final JerseyJiraRestClientFactory factory = new JerseyJiraRestClientFactory();
        final URI jiraServerUri = URI.create(endpoint.getServerUrl());
        client = factory.createWithBasicHttpAuthentication(jiraServerUri, endpoint.getUsername(),
                                                           endpoint.getPassword());
    }
View Full Code Here


        this.endpoint = endpoint;
       
        // support to set the delay from JIRA Endpoint
        setDelay(endpoint.getDelay());

        JerseyJiraRestClientFactory factory;
        Registry registry = endpoint.getCamelContext().getRegistry();
        Object target = registry.lookupByName("JerseyJiraRestClientFactory");
        if (target != null) {
            LOG.debug("JerseyJiraRestClientFactory found in registry " + target.getClass().getCanonicalName());
            factory = (JerseyJiraRestClientFactory) target;
        } else {
            factory = new JerseyJiraRestClientFactory();
        }


        final URI jiraServerUri = URI.create(endpoint.getServerUrl());
        client = factory.createWithBasicHttpAuthentication(jiraServerUri, endpoint.getUsername(),
                                                           endpoint.getPassword());
    }
View Full Code Here

  private static boolean quiet = false;

  public static void main(String[] args) throws URISyntaxException, JSONException {
    parseArgs(args);

    final JerseyJiraRestClientFactory factory = new JerseyJiraRestClientFactory();
    final JiraRestClient restClient = factory.createWithBasicHttpAuthentication(jiraServerUri, "admin", "admin");
    final NullProgressMonitor pm = new NullProgressMonitor();
    final int buildNumber = restClient.getMetadataClient().getServerInfo(pm).getBuildNumber();

    // first let's get and print all visible projects (only jira4.3+)
    if (buildNumber >= ServerVersionConstants.BN_JIRA_4_3) {
View Full Code Here

      prop.load(new FileInputStream("jira.properties"));
    } catch (Exception e) {
      e.printStackTrace();
    }
    System.out.println("Connecting to Jira...");
    this.factory = new JerseyJiraRestClientFactory();
    this.restClient = factory.createWithBasicHttpAuthentication(new URI(
        prop.getProperty("url").trim()),
        prop.getProperty("username").trim(),
        prop.getProperty("password").trim());
    this.pm = new NullProgressMonitor();
View Full Code Here

*
* @since v0.1
*/
public class Example1 {
  public static void main(String[] args) throws URISyntaxException {
    final JerseyJiraRestClientFactory factory = new JerseyJiraRestClientFactory();
    final URI jiraServerUri = new URI("http://localhost:8090/jira");
    final JiraRestClient restClient = factory.createWithBasicHttpAuthentication(jiraServerUri, "admin", "admin");
    final NullProgressMonitor pm = new NullProgressMonitor();

    // first let's get and print all visible projects
    final Iterable<BasicProject> allProjects = restClient.getProjectClient().getAllProjects(pm);
    for (BasicProject project : allProjects) {
View Full Code Here

TOP

Related Classes of com.atlassian.jira.rest.client.internal.jersey.JerseyJiraRestClientFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.