Internal Server Error - java

I am getting an unusual error while running my application, just wondering if anyone has come across this before. I am using google protocol buffers, my servlet takes a request and tries to process it, I have the following code:
InputStream s = request.getInputStream();
AdRequest adRequest = AdRequest.parseFrom(s);
After executing the second line I get the error below in Myeclipse debugger:
Source not found for ApplicationFilterChain.internalDoFilter(ServletRequest, ServletResponse) line: 310
I am using Jboss app server. I get a HTTP Status-Code 500: Internal Server Error.
Does anyone have any suggestions/thoughts?

I have sorted out the problem. The protobuffers.jar file was not being included in my projects .war file, even though I had added the jar to my project MyEclipse was not including it. Upon following the path to the Jboss server and looking inside the .war I found out the jar was not there. After copying it over to Jboss/.../default/server/deploy/myproject.war/WEB-INF/lib directory the error has gone away and I am able to send a request to the servlet.
Thanks.
Regards.

I'd check your jboss logs server//log/server.log (assuming you've not configured it to be somewhere else), and you'll get a better description of the problem.
The internal server error simply means that an unhandled exception is getting passed up the filter chain.

Related

Java, App Insights: "I/O Exception: Invalid Argument or cannot assign requested address" only when I run using docker. No error locally with gradle

i have a java spring app that runs just fine locally with gradle, but when i run the image version of it, i get a strange error that i am not sure how to resolve or debug
docker run -it --rm myregistry.azurecr.io/my-app:latest
is the command that i get the following error on:
I/O exception (java.net.SocketException) caught when processing request to {s}->https://rt.services.visualstudio.com:443: Invalid argument or cannot assign requested address
ive found out thru googling that this url https://rt.services.visualstudio.com:443 is associated with Application Insights (azure logging) which is one of my dependencies. does this mean something is wrong with logback?
the thing is, when i run with gradle, i see trace logs in the app insights instance i am trying to log to, so i know that connection is working outside of docker.
one thing to note is that in the deployed dockerized instance, i see the same logs on startup as the successful local gradle output, but then it dies after it sets the profile. maybe meaning that it is dying during the tomcat initialization.
what to do/try here?
this ended up being due to a web proxy issue, switching networks or creating a proxy rule are solutions.

SOAP web service returns data on and off

My source system provides SOAP url (hosted in IIS server) which we use it to get data, but lately we cannot pull data where it fails with nothing more than this msg in my side
"org.apache.axiom.om.OMException: SOAP message MUST NOT contain a Document Type Declaration(DTD)"
When the issue was debugged on the other side we got the following error
DEBUG httpclient.333.content [main] << " [0x9]IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred."
The team that developed this service too cannot provide us anything useful info like where their app fails or any other useful info. A bizzare scenario occurs every now and then, wherein a data pull is successful in a test server but fails in prod server even when both of them point to the same SOAP url.
Everything worked fine as long as they hosted it in Apache tomcat, things worsened after they moved to IIS.
I want to know what settings to be looked at to resolve the issue.

How to enable server stack-trace for Rest calls in IBM Mobile First 8

In MF8, when I try to hit Rest Service URLs I am unable to get the stack trace when server returns a 500 error. I get the below error in POSTMAN.
"Unexpected error in server, see logs"
How can I enable the server stack trace?
It's unclear if you're using the devkit or the Mobile Foundation service.
Assuming you're using the devkit, you can find the logs in the devkit-folder/mfp-server/usr/servers/mfp/logs folder... there you will see a messages.log file.

why getting socket closed error after running script by jmeter?

I am getting "Non HTTP response code: java.net.SocketException
Response message: Non HTTP response message: Connection reset" this type of error after running jmeter script
I bet that you're experiencing the problem described in Connection Reset since JMeter 2.10 ? wiki page
So I would recommend to take the next steps:
Switch "Implementation" of all your HTTP Request Samplers to "HttpClient4". The best way to do this is using HTTP Request Defaults so you will have to change the value in just one place.
As per the wiki page add the next 2 lines to user.properties file (lives under /bin folder of your JMeter installation)
httpclient4.retrycount=1
hc.parameters.file=hc.parameters
Add the next line to hc.parameters file (same location, /lib folder)
http.connection.stalecheck$Boolean=true
Remember to restart JMeter after making these changes, properties change is not dynamic, they're being picked up upon JMeter startup.
Hope this helps.

Glassfish4 execution errors

I have a brand new installation of glassfish4. I added one glassfish server to my list of servers in Eclipse kepler.
I now get the error Unable to start server on time. java.util.concurrent.TimeoutException. In the stack trace, I
see java.net.BindException: Address already in use: bind. I googled the first message and tried to fix it by removing
the osgi folder and replacing a glassfish jar as mentioned here - Unable to find or serve resource
That gave me a new error which said something like antivirus or something else is blocking glassfish. I googled the second
message and got one link which did not help - How do I clear an address for Glassfish 4.0 with default settings?
Finally, I decided to reinstall glassfish4 and try all over again. I get the same error messages again. Now, I don't know what to do. Please help me.
Thanks.

Categories

Resources