0

apache camel for jira

 2 years ago
source link: https://www.codesd.com/item/apache-camel-for-jira.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

apache camel for jira

advertisements

I want to build an Apache camel application to download a Jira issue report, parse it, and store it into a .csv file. I'm new at Apache camel, I do believe the jira here should be an endpoint, how to setup this configuration, I want to set is as from:("Jira") to (csv file). I believe it could be something like this:

public void configure() throws Exception {

from("jira://pullRequestComment?ProjectKey=CAMEL-0000&IssueTypeId=1&IssueSummary=title")
.process(new MyLogProcessor())
.bean(new MyTransformer(),"transformContent")
.to("file:D:/camel/output");
}

I tried the above code, I got an exception for java conversion type.

Exception:


The JIRA component returns Java objects from the JIRA REST API. You need to either:

  1. Support passing in the object type to your processor class as a method argument
  2. Convert the JIRA Java Object to something else, then pass into your processor

BTW- The JIRA component caches "seen" data to know what is "new" to pass into the route. For really busy JIRA servers, this looks and acts like a memory leak so you'll need to be mindful to manage that scenario


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK