I have an applicationScope managed bean that loads a bunch of information about a series of applications into a Map. Then the following method is part of the bean:
public Database getAppDB() {
Database appDB = null;
try{
Session s = ExtLibUtil.getCurrentSession();
serverName = s.createName(s.getCurrentDatabase().getServer()).getCommon();
appDB = s.getDbDirectory(serverName).openDatabaseByReplicaID(this.getAppRepID());
return appDB;
}catch (NotesException e){
System.out.println(e.toString());
return appDB;
}
}
Now this method declares two Objects (Session and appDB). Not sure if they need to be recycled before returning and if so how would one do that because appDB is the returned value. The Session can easily be recycled. Now clearly if I call this method from some SSJS:
var thisDB:NotesDatabase = appProps[ssApplication].appDB;
I need to recycle thisDB in the SSJS.
also if I do something like this in SSJS:
var cNames = appProps[ssApplication].appDB.getView("vwFTSearch").getColumnNames();
I'm assuming that there is nothing to recycle?