Upload
drew-rawlinson
View
214
Download
0
Embed Size (px)
Citation preview
SugarCRM Database Deployment Variants
DB in separate Service TemplateDB external to Service Template
2
Objective
• Consider scenarios when components or services required by a deployment may be:– 1) Shared across deployments– 2) Already existing/provided by a 3rd party not part
of any existing Service Template (i.e. under the control of a separate and autonomous administrative entity)
3
Fully Specified Service Template
R1: ContainerRequirementC1: ContainerCapabilityR2: WebAppContainerRequirementC2: WebAppContainerCapabilityR3: MySqlDbContainerRequirementC3: MySqlDbContainerCapabilityR4: PluginContainerRequirementC4: PluginContainerCapabilityR5: PhpRuntimeRequirementC5: PhpRuntimeCapabilityR6: MySqlDatabaseRequirementC6: MySqlDatabaseCapability
VmApache
[VirtualMachine]
ComputeNodeMySql
[ComputeNode]
ApacheWebServer
[ApacheWebServer]
MySql
[MySql]
SugarCrmApp
[SugarCrmApplication]
SugarCrmDb
[SugarCrmDb]
PhpModule
[PhpModule]
PluginHostedOnContainerOperations: hostOn
MySqlDbConnectionOperations: connectTo
HostedOnType MySqlDbHostedOnMySqlOperations: hostOn
HostedOn HostedOn
AppDependsOnPhpRuntime
R2
C1
C2
R1
C1
R1
C3
R3
R4
C4
C5
R5 R6 C6
IaaS or PaaS cloud hosted DBMS
DBMS capable of hosting the DB
.
.
.
.
.
.
4
Minimally Specified Service Template
SugarCrmApp
[SugarCrmApplication]
SugarCrmDb
[SugarCrmDb]MySqlDbConnection
RH RH
RC CC
• We must decide:– Which components will be hosted in the
deployment versus outside the deployment• Outside the deployment cases:– 1) Part of another deployment (i.e. specified in
another service template)– 2) Hosted in some existing server we don’t control
but are allowed to connect to
DB has DA to initialize in DBMS
5
Splitting Across Multiple Deployments
VmApache
[VirtualMachine]
VmMySql
[VirtualMachine]
ApacheWebServer
[ApacheWebServer]
MySql
[MySql]
SugarCrmApp
[SugarCrmApplication]
SugarCrmDb
[SugarCrmDb]
PhpModule
[PhpModule]
PluginHostedOnContainerOperations: hostOn
MySqlDbConnectionOperations: connectTo
HostedOnType MySqlDbHostedOnMySqlOperations: hostOn
HostedOn HostedOn
AppDependsOnPhpRuntime
R2
C1
C2
R1
C1
R1
C3
R3
R4
C4
C5
R5 R6 C6
PHP App Service Template DB Service Template
Deployments have decoupled lifecycles
6
When To Split?
• DB has a different lifecycle than the PHP App– E.g. DB is really shared across multiple client apps
• DB service is offered by a different Administrative Entity (AE)– DB AE controls lifecycle of the DB. PHP AP AE
consumes DB on DB AE’s terms– AE for App and DB both use TOSCA gaining the
benefit the awareness of each other’s models• Lifecycle awareness• Federation
7
Using an “External” DB
• Single Service Template specifies:– PHP App fully specified as part of deployment as a
complete tier– DB is partially specified• DB is hostedOn a DBMS (R3)• DBMS instance is specified (C3)
– Address and port– DBMS type not necessarily relevant (leave abstract if possible)
• DBMS container/tier is out of scope• TOSCA engine must resolve lifecycle states of DBMS
8
TOSCA Engine Resolves DB
VmApache
[VirtualMachine]
ApacheWebServer
[ApacheWebServer]
SugarCrmApp
[SugarCrmApplication]
SugarCrmDb
[SugarCrmDb]
PhpModule
[PhpModule]
PluginHostedOnContainerOperations: hostOn
MySqlDbConnectionOperations: connectTo
HostedOnType
HostedOn
AppDependsOnPhpRuntime
R2
C1
C2
R1
R3
R4
C4
C5
R5 R6 C6
?
R3 allows TOSCA Engine to find DBMS which can host the DBLifecycle operations of DBMS is out of scope
DbHostedOnDBMS
9
External DB Service Template
VmApache
[VirtualMachine]
ApacheWebServer
[ApacheWebServer]
DBMS
[DBMS]
SugarCrmApp
[SugarCrmApplication]
SugarCrmDb
[SugarCrmDb]
PhpModule
[PhpModule]
PluginHostedOnContainerOperations: hostOn
MySqlDbConnectionOperations: connectTo
HostedOnType DbHostedOnDBMS
HostedOn
AppDependsOnPhpRuntime
R2
C1
C2
R1
C3
R3
R4
C4
C5
R5 R6 C6
?
C3 contains information (e.g. host/port) required to connect to a specific DBMSDBMS lifecycle still out of scope