2

I have rest wcf service working okay. Except in some scenarios It throws bad request.

On some search and checks, it seems when the url has longer parameters.(sometimes url length is more than 1000) .It does not hit the service and thrown bad request straight away.

http://testservice/Service.svc/endpoint/get/1/2/longparameter

How can I address for such situations?

Mandar Jogalekar
  • 3,199
  • 7
  • 44
  • 85

1 Answers1

2

I had a similar issue and thanks to this answer was able to resolve it by adding the following:

<system.web>
  <httpRuntime maxUrlLength="500" />
</system.web>

That worked for me, but in your case it sounds like you'd need to set it even higher.

Community
  • 1
  • 1
Sean Gough
  • 1,721
  • 3
  • 26
  • 47