Buggy code:
public class AlfrescoContentRepository extends AbstractContentRepository implements SecurityProvider { private static final Logger logger = LoggerFactory . getLogger ( AlfrescoContentRepository . class ) ; @ Override public InputStream getContent ( String path ) throws ContentNotFoundException { } @ Override public boolean contentExists ( String path ) { } @ Override public boolean writeContent ( String path , InputStream content ) { } @ Override public boolean createFolder ( String path , String name ) { } @ Override public boolean deleteContent ( String path ) { } @ Override public boolean copyContent ( String fromPath , String toPath ) { } @ Override public boolean moveContent ( String fromPath , String toPath ) { } public RepositoryItem [ ] getContentChildren ( String path ) { } public String createVersion ( String path , boolean majorVersion ) { } public VersionTO [ ] getContentVersionHistory ( String path ) { } public boolean revertContent ( String path , String version , boolean major , String comment ) { } protected String createFolderInternal ( String path , String name ) { } protected boolean copyContentInternal ( String fromPath , String toPath , boolean isCut ) { } protected InputStream alfrescoGetRequest ( String uri , Map < String , String > params ) throws Exception { } protected String alfrescoPostRequest ( String uri , Map < String , String > params , InputStream body , String bodyMimeType ) throws Exception { } protected String alfrescoMultipartPostRequest ( String uri , Map < String , String > params , InputStream body , String bodyMimeType , String charSet ) throws Exception { } protected String buildAlfrescoRequestURL ( String uri , Map < String , String > params ) throws Exception { } protected String getAlfTicket ( ) { } @ Override public Map < String , String > getUserProfile ( String username ) { } @ Override public Set < String > getUserGroups ( String username ) { } @ Override public String getCurrentUser ( ) { } @ Override public String authenticate ( String username , String password ) { } @ Override public boolean validateTicket ( String ticket ) { } private void addDebugStack ( ) { } protected String getNodeRefForPathCMIS ( String fullPath ) throws ContentNotFoundException { } protected InputStream getContentStreamCMIS ( String fullPath ) throws ContentNotFoundException { } protected RepositoryItem [ ] getContentChildrenCMIS ( String fullPath ) { } protected boolean writeContentCMIS ( String fullPath , InputStream content ) { } protected boolean deleteContentCMIS ( String fullPath ) { } protected VersionTO [ ] getContentVersionHistoryCMIS ( String fullPath ) { } protected boolean revertContentCMIS ( String fullPath , String version , boolean major , String comment ) { } protected String createFolderInternalCMIS ( String fullPath , String name ) { } protected boolean copyContentInternalCMIS ( String fromFullPath , String toFullPath , boolean isCut ) { } private void copyFolder ( Folder parentFolder , Folder toCopyFolder ) { } private void copyChildren ( Folder parentFolder , Folder toCopyFolder ) { } private void copyDocument ( Folder parentFolder , AlfrescoDocument sourceDocument ) { } protected Session getCMISSession ( ) { } protected Session getCMISSession ( boolean alfrescoCMIS ) { SessionFactory sessionFactory = SessionFactoryImpl . newInstance ( ) ; Map < String , String > parameter = new HashMap < String , String > ( ) ; String ticket = getAlfTicket ( ) ; parameter . put ( USER , "ROLE_TICKET" ) ; parameter . put ( PASSWORD , ticket ) ; <START_BUG> parameter . put ( ATOMPUB_URL , "http:////localhost:8080//alfresco//api//-default-//public//cmis//versions//1.0//atom//" ) ; <END_BUG> parameter . put ( BINDING_TYPE , ATOMPUB . value ( ) ) ; if ( alfrescoCMIS ) { parameter . put ( OBJECT_FACTORY_CLASS , "org.alfresco.cmis.client.impl.AlfrescoObjectFactoryImpl" ) ; } List < Repository > repositories = new ArrayList < Repository > ( ) ; repositories = sessionFactory . getRepositories ( parameter ) ; Repository repository = repositories . get ( 0 ) ; parameter . put ( REPOSITORY_ID , repository . getId ( ) ) ; Session session = sessionFactory . createSession ( parameter ) ; return session ; } public void lockItem ( String site , String path ) { } protected String expandRelativeSitePath ( String site , String relativePath ) { } public void unLockItem ( String site , String path ) { } @ Override public void addUserGroup ( String groupName ) { } @ Override public void addUserGroup ( String parentGroup , String groupName ) { } @ Override public String getCurrentToken ( ) { } protected String alfrescoUrl ; public String getAlfrescoUrl ( ) { } public void setAlfrescoUrl ( String url ) { } No newline ; at end ; of file ; }

Fix:
parameter . put ( ATOMPUB_URL , ( ( alfrescoUrl ) + "//api//-default-//public//cmis//versions//1.0//atom//" ) ) ;