Questions tagged [httpexception]

HttpException or HTTPException are exception classes defined by various object oriented libraries that signal a problem during processing of a http request.

There is a HttpException in the System.Web namespace of .Net, another one in Apache Commons and a HTTPException in JAX-WS

160 questions
3
votes
3 answers

How to catch a specific HttpException (#0x80072746) in an IHttpHandler

It appears that this HttpException (0x80072746 - The remote host closed the connection) can be thrown if, for example, the user closes the window whilst we are transmitting a file. Even if we send the files in smaller blocks and check the client is…
grebe
  • 31
  • 1
  • 2
3
votes
2 answers

NoClassDefFoundError: org/apache/commons/httpclient/HttpException while making WS call with Axis2

I'm making a soap call with Axis2 1.6.2 (ADB generated classes) and httpclient 4.2.1. for some reason it throws me NoClassDefFoundError: org/apache/commons/httpclient/HttpException. I checked HttpException is in a different package now for…
Joseph
  • 97
  • 2
  • 15
3
votes
2 answers

How to diagnose "the operation has timed out" HttpException

I am calling 5 external servers to retrieve XML-based data for each request for a particular webpage on my IIS 6 server. Present volume is between 3-5 incoming requests per second, meaning 15-20 outgoing requests per second. 99% of the outgoing…
dalej
  • 43
  • 1
  • 4
3
votes
1 answer

"Invalid use of response filter" when rewriting ASP.NET output

I have a very basic ASP.NET response filter that works "fine." I use it to replace the domain for static resources. My code in the controller looks like this: protected override void OnActionExecuted(ActionExecutedContext filterContext) { …
Mahmoud Al-Qudsi
  • 28,357
  • 12
  • 85
  • 125
2
votes
2 answers

ASP.NET MVC properly handling invalid URLs

I'm trying to properly handle and return a 404 for this URL: http://localhost:2867/dd./xml (notice the dot before the slash) In my current implementation I get 4 exceptions/errors in Application_Error. The first exception returned by…
pbz
  • 8,865
  • 14
  • 56
  • 70
2
votes
1 answer

System.Web.HttpException with BasicAuthentication custom HttpModule

I am trying to debug a System.Web.HttpException that I keep getting. It could be related to a BaiscAuthentication custom HttpModule I am trying to implement. The BasicAuthentication HttpModule is subscribing to two events in the pipeline,…
Duncan Gravill
  • 4,552
  • 7
  • 34
  • 51
2
votes
2 answers

How to stop FastAPI app after raising an Exception?

When handling exceptions in FastAPI, is there a way to stop the application after raising an HTTPException? An example of what I am trying to achieve: @api.route("/") def index(): try: do_something() except Exception as e: …
noah
  • 312
  • 2
  • 13
2
votes
0 answers

How to properly translate HttpExceptions in the Frontend with Angular?

We have a complex business logic where we raise several HTTPExceptions with FastAPI if an error occurs. When we raise an exception we define a status code and a detail error message. The problem is that this error message is in english but our…
2
votes
2 answers

(HttpException) => Null' is not a subtype of type '(dynamic) => dynamic'!! flutter

Im trying to request JSONs and some images. The JSONs come just fine, as they are small. When im requesting images, I just get the following SocketException 95% of the time: I/flutter ( 9249): Exception: type '(HttpException) => Null' is not a…
Maverick
  • 31
  • 4
2
votes
2 answers

AJAX call in Laravel returns Http Exception

When I tried to use ajax in laravel it shows the following error, { "message": "", "exception": "Symfony\Component\HttpKernel\Exception\HttpException", "file": …
2
votes
1 answer

Throw 404 in c# to go to customerror.aspx without 302 and 301

I have custom errors set in web.config for a 404 error and in IIS. My custom error page works ok. I want to be able to go to my custom error page from a page load event. If I throw a 404 using throw new HttpException(404, "Not found"); I get to…
2
votes
3 answers

When HttpStatusCodeException exception raised?

when i use below code , what is the case to get HttpStatusCodeException exception . ResponseEntity response = restTemplate.exchange(builder.build().encode().toUri(), HttpMethod.GET, entity, Object.class); Please can anyone help out…
Nag-Raj
  • 169
  • 1
  • 4
  • 13
2
votes
3 answers

Resetting indexes with ruflin/elastica throws HttpException on heroku

I'm using elasticsearch in a Symfony project with FOSElasticaBundle, that requires ruflin/elastica client. In order to create indexes I use the command suggested in the documentation of FOSElasticaBundle and in my local machine everything is going…
2
votes
1 answer

Parsing erroneous server responses in Meteor

We are developing a Meteor app which is calling in-house made RESTful API. Our server expects that "Content-type: application/json" header is set and it always responds with same header (Content-Type: application/json; charset=UTF-8) and a…
errata
  • 5,695
  • 10
  • 54
  • 99
2
votes
1 answer

403 Forbidden Error while building Google Endpoints backend in Android Studio

It is my first time trying to use GAE endpoints connecting in an Android Studio project. So, I've simply followed the instructions provided by Google (https://cloud.google.com/tools/android-studio/app_engine/). But I am getting a 403 error every…
1 2
3
10 11