From 8b95e4c27f7669b741fc6af26c22a121db143471 Mon Sep 17 00:00:00 2001 From: Frode Nordahl Date: Sat, 18 Aug 2018 08:11:28 +0200 Subject: [PATCH] Optimize bundles for faster test execution Give machine deployed for database unit more RAM. Make sure machine used for database unit is deployed first. Change-Id: I3a2f09396629fda52f9b72284d90756da9cc2536 --- tests/bundles/bionic-queens.yaml | 17 +++++++++++++++ tests/bundles/bionic-rocky.yaml | 17 +++++++++++++++ tests/bundles/cosmic-rocky.yaml | 17 +++++++++++++++ tests/bundles/trusty-icehouse.yaml | 32 +++++++++++++++++++--------- tests/bundles/trusty-mitaka.yaml | 34 +++++++++++++++++++----------- tests/bundles/xenial-mitaka.yaml | 17 +++++++++++++++ tests/bundles/xenial-ocata.yaml | 17 +++++++++++++++ tests/bundles/xenial-pike.yaml | 17 +++++++++++++++ tests/bundles/xenial-queens.yaml | 17 +++++++++++++++ 9 files changed, 163 insertions(+), 22 deletions(-) diff --git a/tests/bundles/bionic-queens.yaml b/tests/bundles/bionic-queens.yaml index 7dcc5ab8..ea8c8a75 100644 --- a/tests/bundles/bionic-queens.yaml +++ b/tests/bundles/bionic-queens.yaml @@ -1,4 +1,13 @@ series: bionic +comment: +- 'machines section to decide order of deployment. database sooner = faster' +machines: + '0': + constraints: mem=3072M + '1': + '2': + '3': + '4': relations: - - keystone:shared-db - mysql:shared-db @@ -10,6 +19,8 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 + to: + - '0' keystone: series: bionic charm: ../../../keystone @@ -17,6 +28,12 @@ applications: options: token-provider: 'fernet' token-expiration: 60 + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 + to: + - '4' diff --git a/tests/bundles/bionic-rocky.yaml b/tests/bundles/bionic-rocky.yaml index 1d8b4a22..04f7b5d2 100644 --- a/tests/bundles/bionic-rocky.yaml +++ b/tests/bundles/bionic-rocky.yaml @@ -1,4 +1,13 @@ series: bionic +comment: +- 'machines section to decide order of deployment. database sooner = faster' +machines: + '0': + constraints: mem=3072M + '1': + '2': + '3': + '4': relations: - - keystone:shared-db - mysql:shared-db @@ -10,6 +19,8 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 + to: + - '0' keystone: series: bionic charm: ../../../keystone @@ -17,8 +28,14 @@ applications: options: openstack-origin: cloud:bionic-rocky/proposed token-expiration: 60 + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 options: openstack-origin: cloud:bionic-rocky/proposed + to: + - '4' diff --git a/tests/bundles/cosmic-rocky.yaml b/tests/bundles/cosmic-rocky.yaml index c3fca3b8..61b09b1b 100644 --- a/tests/bundles/cosmic-rocky.yaml +++ b/tests/bundles/cosmic-rocky.yaml @@ -1,4 +1,13 @@ series: cosmic +comment: +- 'machines section to decide order of deployment. database sooner = faster' +machines: + '0': + constraints: mem=3072M + '1': + '2': + '3': + '4': relations: - - keystone:shared-db - mysql:shared-db @@ -10,12 +19,20 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 + to: + - '0' keystone: series: cosmic charm: ../../../keystone num_units: 3 options: token-expiration: 60 + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 + to: + - '4' diff --git a/tests/bundles/trusty-icehouse.yaml b/tests/bundles/trusty-icehouse.yaml index 0131d25a..6d8d9b9d 100644 --- a/tests/bundles/trusty-icehouse.yaml +++ b/tests/bundles/trusty-icehouse.yaml @@ -1,4 +1,18 @@ series: trusty +comment: +- 'machines section to decide order of deployment. database sooner = faster' +- 'virt-type=kvm is workaround while awaiting new release of python-libjuju' +machines: + '0': + constraints: virt-type=kvm mem=3072M + '1': + constraints: virt-type=kvm + '2': + constraints: virt-type=kvm + '3': + constraints: virt-type=kvm + '4': + constraints: virt-type=kvm relations: - - keystone:shared-db - mysql:shared-db @@ -10,22 +24,20 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 - # workaround while awaiting release of next version of python-libjuju with - # model-constraints support - constraints: - virt-type=kvm + to: + - '0' keystone: series: trusty charm: ../../../keystone num_units: 3 - # workaround while awaiting release of next version of python-libjuju with - # model-constraints support constraints: virt-type=kvm + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 - # workaround while awaiting release of next version of python-libjuju with - # model-constraints support - constraints: - virt-type=kvm + to: + - '4' diff --git a/tests/bundles/trusty-mitaka.yaml b/tests/bundles/trusty-mitaka.yaml index 066ee25b..419c5546 100644 --- a/tests/bundles/trusty-mitaka.yaml +++ b/tests/bundles/trusty-mitaka.yaml @@ -1,4 +1,18 @@ series: trusty +comment: +- 'machines section to decide order of deployment. database sooner = faster' +- 'virt-type=kvm is workaround while awaiting new release of python-libjuju' +machines: + '0': + constraints: virt-type=kvm mem=3072M + '1': + constraints: virt-type=kvm + '2': + constraints: virt-type=kvm + '3': + constraints: virt-type=kvm + '4': + constraints: virt-type=kvm relations: - - keystone:shared-db - mysql:shared-db @@ -10,26 +24,22 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 - # workaround while awaiting release of next version of python-libjuju with - # model-constraints support - constraints: - virt-type=kvm + to: + - '0' keystone: series: trusty charm: ../../../keystone num_units: 3 - # workaround while awaiting release of next version of python-libjuju with - # model-constraints support - constraints: - virt-type=kvm options: openstack-origin: cloud:trusty-mitaka + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 - # workaround while awaiting release of next version of python-libjuju with - # model-constraints support - constraints: - virt-type=kvm options: openstack-origin: cloud:trusty-mitaka + to: + - '4' diff --git a/tests/bundles/xenial-mitaka.yaml b/tests/bundles/xenial-mitaka.yaml index ecc542a2..e2ed823d 100644 --- a/tests/bundles/xenial-mitaka.yaml +++ b/tests/bundles/xenial-mitaka.yaml @@ -1,4 +1,13 @@ series: xenial +comment: +- 'machines section to decide order of deployment. database sooner = faster' +machines: + '0': + constraints: mem=3072M + '1': + '2': + '3': + '4': relations: - - keystone:shared-db - mysql:shared-db @@ -10,10 +19,18 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 + to: + - '0' keystone: series: xenial charm: ../../../keystone num_units: 3 + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 + to: + - '4' diff --git a/tests/bundles/xenial-ocata.yaml b/tests/bundles/xenial-ocata.yaml index 4708225b..09d3ae4e 100644 --- a/tests/bundles/xenial-ocata.yaml +++ b/tests/bundles/xenial-ocata.yaml @@ -1,4 +1,13 @@ series: xenial +comment: +- 'machines section to decide order of deployment. database sooner = faster' +machines: + '0': + constraints: mem=3072M + '1': + '2': + '3': + '4': relations: - - keystone:shared-db - mysql:shared-db @@ -10,6 +19,8 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 + to: + - '0' keystone: series: xenial charm: ../../../keystone @@ -18,8 +29,14 @@ applications: openstack-origin: cloud:xenial-ocata token-provider: 'fernet' token-expiration: 60 + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 options: openstack-origin: cloud:xenial-ocata + to: + - '4' diff --git a/tests/bundles/xenial-pike.yaml b/tests/bundles/xenial-pike.yaml index 5ac1f965..bbdaca38 100644 --- a/tests/bundles/xenial-pike.yaml +++ b/tests/bundles/xenial-pike.yaml @@ -1,4 +1,13 @@ series: xenial +comment: +- 'machines section to decide order of deployment. database sooner = faster' +machines: + '0': + constraints: mem=3072M + '1': + '2': + '3': + '4': relations: - - keystone:shared-db - mysql:shared-db @@ -10,6 +19,8 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 + to: + - '0' keystone: series: xenial charm: ../../../keystone @@ -18,8 +29,14 @@ applications: openstack-origin: cloud:xenial-pike token-provider: 'fernet' token-expiration: 60 + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 options: openstack-origin: cloud:xenial-pike + to: + - '4' diff --git a/tests/bundles/xenial-queens.yaml b/tests/bundles/xenial-queens.yaml index c0b29ea6..802b5acf 100644 --- a/tests/bundles/xenial-queens.yaml +++ b/tests/bundles/xenial-queens.yaml @@ -1,4 +1,13 @@ series: xenial +comment: +- 'machines section to decide order of deployment. database sooner = faster' +machines: + '0': + constraints: mem=3072M + '1': + '2': + '3': + '4': relations: - - keystone:shared-db - mysql:shared-db @@ -10,6 +19,8 @@ applications: mysql: charm: cs:~openstack-charmers-next/percona-cluster num_units: 1 + to: + - '0' keystone: series: xenial charm: ../../../keystone @@ -18,8 +29,14 @@ applications: openstack-origin: cloud:xenial-queens token-provider: 'fernet' token-expiration: 60 + to: + - '1' + - '2' + - '3' glance: charm: cs:~openstack-charmers-next/glance num_units: 1 options: openstack-origin: cloud:xenial-queens + to: + - '4'