Question

UrlRewriteFilter depends on httpclient-3.1, while Couchbase client depends on httpclient-4.0.

I came up with two choices:

  1. Use two different versions of httpclient together

  2. Replace UrlRewriteFilter with other solutions

I found that using httpclient 3.1 and 4.0 together is ok (reference), but is it the best way?

As for the second choice, I use proxying, redirecting, and forwarding with UrlRewriteFilter. Redirecting and forwarding would be possible if I user Spring MVC. But I have no idea how can I proxy some URIs without using Apache web server or haproxy.

Any advices or corrections for this question are welcomed.

Was it helpful?

Solution

HttpClient 3.1 and 4.0 can coexist with no problem. I would say the best solution at the moment is to do that. It's always tempting to form UrlRewriteFilter for example. But in the end, that kind of solutions are just time-consuming.

Whatever you are doing do NOT use Apache to proxy som URLs, you will just be mad that you can never just use Jetty in development and you have to maintain rewrites that are not in the codebase, that is the worst solution.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top