LDEV-77: The createWorkspaceFolderContent and deleteContentWithVersion calls were not working. The code logged into the content repository, but it had not set up an area in the content repository to create the files (i.e. it had not created the Workspace service's workspace) and it had not defined the credential with the repository. So the login to the repository failed.
Added code to detect the "can't login" error and if it occurs, the code attempts to create the repository workspace and credential and then log in again.