It's all about the answers!

Ask a question

(502) Bad Gateway


magnus Elfving (322) | asked Oct 26 '21, 1:34 p.m.

Hi,


I am running an external application (developed in Visual Basic) fetching information's from a Rhapsody (8.4) SYSML model and using this information to create and update artefacts/modules in DNG (6.0.6.1) using the OSLC REST API. This has been working fine for a while.

Though, one procedure the Visual Basic application performs, is to query DNG for a large set of artifacts. That procedure is now failing by throwing an exception after ~60 seconds, see below:
  "System.Net.WebException occurred
  HResult=0x80131509
  Message=The remote server returned an error: (502) Bad Gateway.
  Source=<Cannot evaluate the exception source>"

Other querying procedures still works, for instance, when querying for an artefact using the URL of the artefact

Can someone advise me what a probable cause and possible solution for the failing query?

Kind Regards

Magnus     

Accepted answer


permanent link
Ian Barnard (1.2k613) | answered Oct 27 '21, 3:47 a.m.
JAZZ DEVELOPER
edited Nov 01 '21, 4:29 a.m.

Hi Magnus


If your deployment has a reverse proxy or is using WAS it sounds like this is timing out on what is presumably a lengthy query you're making to DOORS Next. The way a reverse proxy works is to accept the request from your application, create a new request (with the same data) to the target application (DOORS Next), wait (with a timeout) for the response, and when it's received create a response to your application. By working this way you can have a single fronting URL for ELM which the reverse proxy dispatches to different application servers to be serviced, allowing distribution of the load and greatly simplifying reconfiguration of the application servers.

You could ask your IT team to check the configuration of your reverse proxy/WAS to perhaps increase the timeout waiting for response.

You could also consider changing your application to make multiple smaller (i.e. quicker) queries rather than one enormous query.

HTH
Ian

magnus Elfving selected this answer as the correct answer

Comments
magnus Elfving commented Oct 28 '21, 8:59 a.m.

Thanks Ian.


I have notified the IT team and I will firstly evaluate the effects of change in the settings of timeout.

Using smaller queries; do you mean pagination or some other way to divide a query ?

Magnus 


Ian Barnard commented Oct 28 '21, 10:32 a.m.
JAZZ DEVELOPER

Pagination will still require your server to find and handle the same large number of results albeit delivering them in smaller chunks.


I imagine making smaller queries (divide it into smaller queries) will be more effective.


Ian Barnard commented Oct 28 '21, 11:10 a.m.
JAZZ DEVELOPER

 If you have any further problem with this, create a support case


magnus Elfving commented Nov 01 '21, 10:06 a.m.

I have now successfully queried DNG with increased setting for time out  

Your answer


Register or to post your answer.