【发布时间】:2016-03-02 19:27:14
【问题描述】:
我想知道我是否能够在服务器 A 上运行的代理中打开服务器连接以访问服务器 B 的 notes.ini。我想检查该 notes.ini 中的参数。这可以通过编码实现吗? 我知道 session.getEnvironment 方法,但它们访问运行代理的服务器(或 Notes 客户端)的 notes.ini。 有什么想法吗?
使用了 Egor 的解决方案:
/**
* checks for notes.ini value for
* @return
* @throws NotesException
*/
private boolean checkNoSessionInfo(String serverName) {
boolean result = false;
try {
String console = session.sendConsoleCommand(serverName, "show config *");
result = console.contains("LOG_DISABLE_SESSION_INFO=1");
} catch (NotesException e) {
oli.logErrorEx(e, "Could not check if server's user session info was disabled", OpenLogItem.SEVERITY_MEDIUM, null);
}
return result;
}
像魅力一样工作! :-)
谢谢大家!
【问题讨论】:
标签: lotus-domino