In a simple agent written to test the use of Domingo I get the following message:
java.lang.ExceptionInInitializerError:
java.lang.SecurityException
at lotus.notes.AgentSecurityManager.checkPropertiesAccess(AgentSecurityManager.java:523)
at java.lang.System.getProperties(System.java:522)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:234)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:214)
at de.bea.domingo.DNotesFactoryFinder.<clinit>(DNotesFactoryFinder.java:50)
at de.bea.domingo.DNotesFactory.newInstance(DNotesFactory.java:155)
at de.bea.domingo.DNotesFactory.getInstance(DNotesFactory.java:82)
at JavaAgent.NotesMain(JavaAgent.java:14)
at lotus.domino.AgentBase.runNotes(Unknown Source)
at lotus.domino.NotesThread.run(NotesThread.java:218)
The agent has the runtime security level set to 3 and the agent signer has Manager access in the ACL and is permitted to run unrestricted Java agents on the server.
The agent code follows at the bottom of this post.
Can anyone give an indication of where to look for this please? The java.policy document?
Thanks.
Tony.
----------------
Agent code:
----------------
import lotus.domino.*;
import de.bea.domingo.*;
public class JavaAgent extends AgentBase {
public void NotesMain() {
try {
System.out.println("");
System.out.println("####### Running Simple Domingo example ########");
System.out.println("");
My original posting contained agent code that was incorrect - I wasn't extending DAgentBase. So now I have taken the actual agent example code from this site and tried that. Here is the code I used:
import lotus.domino.*;
import de.bea.domingo.*;
public class AgentContext extends DAgentBase {
public void main() {
System.out.println("");
System.out.println("---- Start of agent ----");
java.lang.ExceptionInInitializerError:
java.lang.SecurityException
at lotus.notes.AgentSecurityManager.checkPropertiesAccess(AgentSecurityManager.java:523)
at java.lang.System.getProperties(System.java:522)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:234)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:214)
at de.bea.domingo.DNotesFactoryFinder.<clinit>(DNotesFactoryFinder.java:50)
at de.bea.domingo.DNotesFactory.newInstance(DNotesFactory.java:218)
at de.bea.domingo.DNotesFactory.getInstance(DNotesFactory.java:96)
at de.bea.domingo.DNotesFactory.getInstance(DNotesFactory.java:111)
at de.bea.domingo.DAgentBase.NotesMain(DAgentBase.java:81)
at lotus.domino.AgentBase.runNotes(Unknown Source)
at lotus.domino.NotesThread.run(NotesThread.java:218)
Any clues? It must be something basic I'm doing wrong otherwise everyone would be complaining. Could we have some more sample code on the website please?
Thanks.
Tony.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
In a simple agent written to test the use of Domingo I get the following message:
java.lang.ExceptionInInitializerError:
java.lang.SecurityException
at lotus.notes.AgentSecurityManager.checkPropertiesAccess(AgentSecurityManager.java:523)
at java.lang.System.getProperties(System.java:522)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:234)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:214)
at de.bea.domingo.DNotesFactoryFinder.<clinit>(DNotesFactoryFinder.java:50)
at de.bea.domingo.DNotesFactory.newInstance(DNotesFactory.java:155)
at de.bea.domingo.DNotesFactory.getInstance(DNotesFactory.java:82)
at JavaAgent.NotesMain(JavaAgent.java:14)
at lotus.domino.AgentBase.runNotes(Unknown Source)
at lotus.domino.NotesThread.run(NotesThread.java:218)
The agent has the runtime security level set to 3 and the agent signer has Manager access in the ACL and is permitted to run unrestricted Java agents on the server.
The agent code follows at the bottom of this post.
Can anyone give an indication of where to look for this please? The java.policy document?
Thanks.
Tony.
----------------
Agent code:
----------------
import lotus.domino.*;
import de.bea.domingo.*;
public class JavaAgent extends AgentBase {
public void NotesMain() {
try {
System.out.println("");
System.out.println("####### Running Simple Domingo example ########");
System.out.println("");
DNotesFactory factory = DNotesFactory.getInstance();
DSession session = factory.getSession();
DAgentContext agentContext = session.getAgentContext();
System.out.println("####### [.] ########");
System.out.println("");
} catch(Exception e) {
e.printStackTrace();
}
}
}
My original posting contained agent code that was incorrect - I wasn't extending DAgentBase. So now I have taken the actual agent example code from this site and tried that. Here is the code I used:
import lotus.domino.*;
import de.bea.domingo.*;
public class AgentContext extends DAgentBase {
public void main() {
System.out.println("");
System.out.println("---- Start of agent ----");
DSession session = getDSession();
DDocument doc = getDSession().getAgentContext().getDocumentContext();
System.out.println("Done - " + session.getCommonUserName());
}
}
And here is the result:
java.lang.ExceptionInInitializerError:
java.lang.SecurityException
at lotus.notes.AgentSecurityManager.checkPropertiesAccess(AgentSecurityManager.java:523)
at java.lang.System.getProperties(System.java:522)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:234)
at de.bea.domingo.DNotesFactoryFinder$Configuration.<init>(DNotesFactoryFinder.java:214)
at de.bea.domingo.DNotesFactoryFinder.<clinit>(DNotesFactoryFinder.java:50)
at de.bea.domingo.DNotesFactory.newInstance(DNotesFactory.java:218)
at de.bea.domingo.DNotesFactory.getInstance(DNotesFactory.java:96)
at de.bea.domingo.DNotesFactory.getInstance(DNotesFactory.java:111)
at de.bea.domingo.DAgentBase.NotesMain(DAgentBase.java:81)
at lotus.domino.AgentBase.runNotes(Unknown Source)
at lotus.domino.NotesThread.run(NotesThread.java:218)
Any clues? It must be something basic I'm doing wrong otherwise everyone would be complaining. Could we have some more sample code on the website please?
Thanks.
Tony.