move database definitions to server class