How to make my web service url case insensitive?

1.4k views Asked by At

I have generated a web service from an existing wsdl file using Axis2, and now my service is reachable by a url

http://something/Service?wsdl

The problem is, there are some applications which call this url, adding an upper case word "WSDL" at the end of url (please don't ask why..), so they are calling it as,

http://something/Service?WSDL

And they can't access it at that url. Is it possible to solve this problem? Maybe setting some parameter or making this url case insensitive someway?

1

There are 1 answers

1
Bogdan On BEST ANSWER

I've taken a quick look at the Axis2 code and it seems the ?wsdl extension compare is case sensitive. This thing sometimes happen.

You could have a look at the code yourself and see if there is some switch somewhere to make this case insensitive (in case I missed something when looking at the code).

What you could do is have a filter in your application that looks at the query string and if it finds ?WSDL in there, in any case whatsoever, to do a redirect to the same URL but with a lower case ?wsdl. This of course assumes that the clients that try to access the WSDL can follow redirects.

The problem is, there are some applications which call this url, adding an upper case word "WSDL" at the end of url (please don't ask why..)

Sorry, but why? The most simple way is to tell clients to use a lower case parameter instead of an upper case one. If they can do a call with ?WSDL why is it so hard to do one with ?wsdl?