Skip to content
Advertisement

Getting java.lang.IllegalArgumentException when trying to make a dynamic HTTP endpoint in Mule

I got an HTTP outbound-endpoint that does a GET method to an specific URL, thing is that if i add a variable in the path URL it will throw an exception… i believe this is not being supported. This is my FLOW:

JavaScript

This is the exception stacktrace

JavaScript

Tried searching a lot in Google but i got no clue on what’s wrong or what could be done to get it working. I even saw that there were JIRA tickets created in MuleSoft to fix this as it wasn’t “supported” but it was supposed to be fixed after Mule 3.2.1 (I’m using 3.3.1).

The URL is being correctly created, even if you copy-paste it in the browser it will work, but for some misterious reason Mule doesn’t like this.

Thanks.

Advertisement

Answer

Try this:

  • Configure an HTTP connector, say: <http:connector name="httpConnector" />
  • Use it in your dynamic HTTP endpoint: <http:outbound-endpoint connector-ref="httpConnector" ...
User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement