This documentation describes how to start working with the default PapyrusCDOServer.
=How to install and launch PapyrusCDOServer on localhost=
#Download the last version of the PapyrusCDOServer on '''https://hudson.eclipse.org/papyrus/view/Collaborative%20Modeling/job/Papyrus-CDO-Server/ws/products/'''
#Unzip it
#Run PapyrusCDOServer like done on this snapshot.
#:[[File:images/CDO_Start_Server.png|frame|none|]]
#:The CDO server is now launched and you have access to a OSGI terminal.


The database is created in a ''develop'' folder at the root of your system.

=How to connect to it from Papyrus=
#Add in your Eclipse update site, this CDO interim job : '''https://download.eclipse.org/modeling/emf/cdo/drops/I20190208-0100'''
#Install the last version of Papyrus CDO Integration ('''https://hudson.eclipse.org/papyrus/job/Papyrus-CDO/lastSuccessfulBuild/artifact/repository/''')
#Restart Eclipse
#Open the '''CDO Explorer''' Perspective
#Add a new repository from the '''CDO Repository''' View by '''Click''' on the green plus
#:[[File:images/CDO_NewRepository_0.png|frame|none|]]
#a new dialod opens, Select '''Connect To an existing remove repository''' then '''Next''',
#:[[File:images/CDO_NewRepository_1.png|frame|none|]]
#Edit the  fields with these values:
#*''Host'': localhost
#*''Port'': 2036
#*''Repository name'': PapyrusCDOSecuredRepository
#*''User name'': Administrator
#*''Password'': 0000
#*:[[File:images/CDO_NewRepository_2.png|frame|none|]]


=How to create a new Papyrus model on this server=
#Do a Checkout from your newly created repository
#*:[[File:images/CDO_Checkout.png|frame|none|]]
#In the project explorer, you now have a new folder called ''Online Transactional Checkout''. In it, find the home folder corresponding to your user id (here, it is ''Administrator'', select it, then '''Right-Click'''->'''New'''->'''Papyrus model'''.
#*:[[File:images/CDO_CreateANewPapyrusModel.png|frame|none|]]
#Now you can work according to your Papyrus habits

''Note'': The commit on the CDO server is automatically done by the standard save action (CTRL-S).


=How to Add User=
#From the '''CDO Repository''' view, select your server, then '''Right-Click'''->'''Manage Security'''.
#:[[File:images/CDO_Manage_Security.png|frame|none|]]
#The '''CDO Security Manager''' editor is now open.
#:[[File:images/CDO_Manage_Security_Editor.png|frame|none|]]
#'''Click''' on the button in the top right corner to open a Tree Editor with the same information, then expand all contents, select the ''Users'' folder, then '''Right-Click'''->'''Papyrus CDO User Management'''->'''Create User'''. A dialog opens (after some delay the first time). 
#:[[File:images/CDO_Papyrus_User_Creation1.png|frame|none|]]
#In this dialog, you can edit various informations about the new user (some values are already initialized by Papyrus). The required values are the ''ID'' and the ''Password''. These informations will allow to your new user to connect him to the server.
#:[[File:images/CDO_Papyrus_User_Creation2.png|frame|none|]]


''Note'': 
*The user is not yet able to change its own password.
*The user can only edit elements in its own folder.
*The user can't work on the same model with his colleagues. To do that, the CDO Server administrator must create a new folder and give the access to the users wanting work together. 

=How to close properly the CDO Server=
#Select your repository '''PapyrusCDOSecuredRepository''' in the '''CDO Repository''', then '''Right-Click'''->'''Disconnect'''.
#:[[File:images/CDO_Server_Disconnect.png|frame|none|]]
#In the OSGI terminal, type '''close''', then '''y''' (for yes) and the server will shutdown.
#:[[File:images/CDO_CloseServer.png|frame|none|]]

 

