Added initial session creation code