Hi

That sounds like a fine use-case.

+1

On Wed, Mar 1, 2017 at 1:11 PM, Zoran Regvart <zo...@regvart.com> wrote:
> Hi,
> On Wed, Mar 1, 2017 at 1:04 PM, Claus Ibsen <claus.ib...@gmail.com> wrote:
>>
>> But is there something about creating URI is expensive? I vaguely
>> recall something about creating either that or URL that may do some
>> hostname lookup or something.
>
> java.net.URL is the evil blocking one it blocks in hashCode on DNS
> lookup[1], java.net.URI is inexpensive
>
>> Btw what is the need for this type converter? Where are you going to
>> use it more specific?
>
> I would like @UriParam to be typed java.net.URI, it seems wasteful and
> error prone to have scheme, host, port, path as separate properties,
> so I added a converter that would convert String to URI so that the
> parameters would be set from endpoint URI. Does that make sense?
>
> zoran
>
>
> [1] 
> http://michaelscharf.blogspot.de/2006/11/javaneturlequals-and-hashcode-make.html
> (first hit on Google)
> --
> Zoran Regvart



-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2

Reply via email to