cancel
Showing results for 
Search instead for 
Did you mean: 

Task type: Camel or other?

davidcarrico
Champ in-the-making
Champ in-the-making
If i'd like my process to execute a REST GET action to some endpoint, what is the ideal Activiti mechanism to use? Should I use Camel (and execute the REST call from there)? The Web Service Task type doesn't seem viable here, as I will be calling REST interface, not a web service.

I don't see this example in the User Guide…
Thanks!
Dave
4 REPLIES 4

jbarrez
Star Contributor
Star Contributor
you'd use a regular Java service task and use HttpClient (or if you're using Spring the RestTemplate)

davidcarrico
Champ in-the-making
Champ in-the-making
Thanks for this.

davidcarrico
Champ in-the-making
Champ in-the-making
Actually - one follow-on question: could I use a javascript Script task type? Using XMLHttpRequest, etc?

jbarrez
Star Contributor
Star Contributor
You could, although im not sure XmlHttpRequest is available, but you could use HttpClient or even plain java.net.URL.