private function getSession($parameter)
    {
        $factory = new RepositoryFactoryJackrabbit();
        $repository = $factory->getRepository(array('jackalope.jackrabbit_uri' => $parameter['jackrabbit_uri']));
        $credentials = new SimpleCredentials($parameter['user'], $parameter['password']);

        return $repository->login($credentials, $parameter['workspace']);
    }