The following exception is thrown and a stack trace is returned when you create a version with a space in the version name in the web UI:
com.hp.hpl.jena.shared.InvalidPropertyURIException: http://localhost:8080/rest/x1/fcr:versions/version 1
Full stack trace: https://gist.github.com/sprater/87554446460660bf957703f33476449e
In addition, the server reports the following warnings and errors:
INFO 16:11:47.567 (FedoraVersioning) Request to add version 'version 1' for 'x1'
WARN 16:11:47.602 (DefaultMessageFactory) MessageFactory event UserData is empty!
WARN 16:11:47.648 (DefaultMessageFactory) MessageFactory event UserData is empty!
WARN 16:11:47.658 (DefaultMessageFactory) MessageFactory event UserData is empty!
ERROR 16:11:47.696 (WildcardExceptionMapper) Exception intercepted by WildcardExceptionMapper: http://localhost:8080/rest/x1/fcr:versions/version 1
This seems to be display issue, as the same exception is thrown on any subsequent attempt to create a version on the same resource; the version appears to be created, but the /fcr:versions data cannot be returned and displayed, due to the exception caused when trying to retrieve the version with the space in the name.
Steps to reproduce:
1. Create a resource (binary or container)
2. Type "version 1" in the "Create version snapshot" text field
3. Click "Create version" button
At this point, the stack trace should be returned.
4. Go back with the browser's back button, and attempt to create another version, with any name (or with an auto-generated name)
The stack trace is shown again.