-2

I am trying to run a java agent based upon code provided here: Java NullPointerException in Java Agent

I am running the code from a local database and get a similar message:

java.lang.NullPointerException
    at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:727)
    at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:654)
    at COM.ibm.JEmpower.applet.http.HttpURLConnection.getInputStream(HttpURLConnection.java:411)
    at COM.ibm.JEmpower.applet.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:703)
    at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:399)
    at java.net.HttpURLConnection.getResponseMessage(HttpURLConnection.java:456)
    at JavaAgent.NotesMain(Unknown Source)
    at lotus.domino.AgentBase.runNotes(Unknown Source)
    at lotus.domino.NotesThread.run(Unknown Source)

I wonder if settings of the Notes client prevent the code to run properly and if so, how permission can be altered?

Community
  • 1
  • 1
Patrick Kwinten
  • 1,988
  • 2
  • 14
  • 26
  • Please show your code. Also, please verify that the same URL works in a browser on the machine that you are running this agent on. – Richard Schwartz Apr 24 '14 at 02:16
  • I can paste the URL in a browser of the browser embedded in the Notes client, and I get a response. the code is similar as in this example: http://stackoverflow.com/questions/20696245/java-nullpointerexception-in-java-agent . so when I invoke the domino agent it seems to me I can not establish the http connection. am i wrong? – Patrick Kwinten Apr 24 '14 at 07:00
  • ps when I schedule the agent on a server I can establish a connection, but I get a 302 message... ? – Patrick Kwinten Apr 24 '14 at 07:03

1 Answers1

0

As I understand it, your browser on the client brings you a result, the agent running on the server gets a 302, and the agent running on the client gets you a NullPointerException.

Since you don't seem to want to show your code, all I can really do is guess. (Maybe that's all I could do if I saw your code, too, but I'd still feel better about your question if you'd show me all the information that you can see yourself.)

In any case, the 302 suggests to me that there might be a proxy involved, somehow. Perhaps some of the information here will be of help to you.

Community
  • 1
  • 1
Richard Schwartz
  • 14,463
  • 2
  • 23
  • 41