# Stay within EU/avoid Kaliningrad?

**URL:** https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380
**Category:** openrouteservice
**Created:** [March 31, 2019, 5:09pm UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380 "2019-03-31T17:09:14Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![markvdb](https://ask.openrouteservice.org/letter_avatar_proxy/v4/letter/m/5fc32e/32.png) [@markvdb](https://ask.openrouteservice.org/u/markvdb)
#### Post date: [March 31, 2019, 5:09pm UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380/1 "2019-03-31T17:09:16Z")

</div>

Hello,

I’m trying to use the [maps.openrouteservice.org](http://maps.openrouteservice.org) web interface to map a route between a place in the Baltics and western Europe. This routes me through Kaliningrad by default. I don’t want that, since it means requesting a visa and customs checks.

When I try to check “Avoid borders”-\> “Country borders”-\> “Russia”, I get the below error message:

 ![error2004](https://ask.openrouteservice.org/uploads/default/original/1X/b54c7d5660c53c1b4dab093f9fdbea5021db67de.jpeg)

“Code 2004: Request parameters exceed the server configuration limits. By dynamic weighting, the approximated distance of a route segment must not be greater than 300000.0 meters”

I checked for similar issues, but couldn’t immediately find any, so I hope you will appreciate me reporting this issue.

Apologies if this is not the right place to mention this. In that case, please do point me in the right direction if there is any!

Thank you very much for your work on open route service!

Mark

---

<div class="post-metadata">

### Author: ![adam](https://ask.openrouteservice.org/user_avatar/ask.openrouteservice.org/adam/32/8_2.png) [@adam](https://ask.openrouteservice.org/u/adam)
#### Post date: [April 1, 2019, 8:59am UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380/2 "2019-04-01T08:59:07Z")

</div>

Hi @markvdb

currently we have to restrict the length of routes that use “dynamic weightings” (i.e. avoiding countries) to 300km due to processing requirements. We should be implementing a new algorithm within the next few weeks that makes it possible to use such restrictions on longer routes, so after the next release you should be able to request this route.

Ada,

---

<div class="post-metadata">

### Author: ![pablopardoz](https://ask.openrouteservice.org/letter_avatar_proxy/v4/letter/p/97f17d/32.png) [@pablopardoz](https://ask.openrouteservice.org/u/pablopardoz)
#### Post date: [May 10, 2019, 8:46am UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380/3 "2019-05-10T08:46:05Z")

</div>

Hi!  
I’m having the same trouble with shortest routes (±500Km) in a single country, but with the **avoid ferry** parameter.  
Are you plannnig to allow this option soon?

Thanks!

---

<div class="post-metadata">

### Author: ![adam](https://ask.openrouteservice.org/user_avatar/ask.openrouteservice.org/adam/32/8_2.png) [@adam](https://ask.openrouteservice.org/u/adam)
#### Post date: [May 10, 2019, 9:07am UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380/4 "2019-05-10T09:07:46Z")

</div>

Hi @pablopardoz ,

generally we have to restrict anything that is not a basic route request to 300km as using the restrictions (borders, ferries etc.) takes a lot longer and uses up a lot of resources. Unfortunately the new algorithm we were going to be using which would have got around this problem has had some teething issues and so we have had to postpone the release of that for the time being. Hopefully we will be able to get these issues resolved soon so we can release the new algorithm, but until then there is unfortunately no way around the 300km restriction.

Adam

---

<div class="post-metadata">

### Author: ![shanghaitours](https://ask.openrouteservice.org/user_avatar/ask.openrouteservice.org/shanghaitours/32/96_2.png) [@shanghaitours](https://ask.openrouteservice.org/u/shanghaitours)
#### Post date: [May 22, 2019, 2:21pm UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380/5 "2019-05-22T14:21:45Z")

</div>

Hi Adam,

I was excited to hear you are working on a new algorithm as I am facing similar problems (related to a border) to the two posters above. Thank you!  
Can I ask when you expect it to be released/fully implemented (roughly - i.e. in half a year, two months)?

Best,  
Verena

---

<div class="post-metadata">

### Author: ![adam](https://ask.openrouteservice.org/user_avatar/ask.openrouteservice.org/adam/32/8_2.png) [@adam](https://ask.openrouteservice.org/u/adam)
#### Post date: [May 23, 2019, 9:42am UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380/6 "2019-05-23T09:42:49Z")

</div>

Hi @shanghaitours,

we are aiming to have it deployed by the end of August

Regards  
Adam

---

<div class="post-metadata">

### Author: ![shanghaitours](https://ask.openrouteservice.org/user_avatar/ask.openrouteservice.org/shanghaitours/32/96_2.png) [@shanghaitours](https://ask.openrouteservice.org/u/shanghaitours)
#### Post date: [October 2, 2019, 4:25pm UTC](https://ask.openrouteservice.org/t/stay-within-eu-avoid-kaliningrad/380/7 "2019-10-02T16:25:59Z")

</div>

Hi Adam,

Sorry to re-open the topic. I was wondering whether the new algorithm to overcome the challenge of imposing restrictions for longer routes is still on the agenda or whether the project had to be abandoned/postponed indefinitely.

Best wishes,  
Verena
