Close session on codeHintProvider when needed