Hello Mohan,
I would check if "custURL" and "sessionObjs" are valid in your context first.
Try the following 3 lines after "n.addReference("MyAppModule.AppSettings_Session", sessionObjs[0].getGuid());" and then check your logs for the expected objects:
console.log(custURL);
console.log(sessionObjs[0]);
console.log(n.getReference("MyAppModule.AppSettings_Session");