Repurpose KeystoneWorkers add keystone::wsgi::apache::threads
authormarios <marios@redhat.com>
Fri, 1 Jul 2016 10:01:08 +0000 (13:01 +0300)
committermarios <marios@redhat.com>
Mon, 11 Jul 2016 13:31:30 +0000 (16:31 +0300)
Now that keystone is run with wsgi apache the KeystoneWorkers
param has no efffect [1]. This repurposes KeystoneWorkers to now
set wsgi::apache::workers and adds the
keystone::wsgi::apache::threads hardcoding to 1 (can overrride
via extraconfig data)

[1] https://github.com/openstack/puppet-keystone/blob/51c68fb127c28b9748b352871783c3ec6ef5c83b/manifests/init.pp#L396

Closes-Bug: 1598092
Change-Id: I503d1f0d3f4c56abfaf4609ea8290e78668013b6

puppet/services/keystone.yaml

index 0ad6025..e98be11 100644 (file)
@@ -45,10 +45,6 @@ parameters:
     type: string
     default: 'regionOne'
     description: Keystone region for endpoint
-  KeystoneWorkers:
-    default: 0
-    description: Number of workers for Keystone service.
-    type: number
   EndpointMap:
     default: {}
     description: Mapping of service endpoint -> protocol. Typically set
@@ -88,7 +84,10 @@ parameters:
     default: 5672
     description: Set rabbit subscriber port, change this if using SSL
     type: number
-
+  KeystoneWorkers:
+    type: string
+    description: Set the number of workers for keystone::wsgi::apache
+    default: '$::processorcount'
 outputs:
   role_data:
     description: Role data for the Keystone role.
@@ -124,8 +123,6 @@ outputs:
         keystone::endpoint::internal_url: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]}
         keystone::endpoint::admin_url: {get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix]}
         keystone::endpoint::region: {get_param: KeystoneRegion}
-        keystone::admin_workers: {get_param: KeystoneWorkers}
-        keystone::public_workers: {get_param: KeystoneWorkers}
         keystone_enable_db_purge: {get_param: KeystoneEnableDBPurge}
         keystone::public_endpoint: {get_param: [EndpointMap, KeystonePublic, uri_no_suffix]}
         keystone::db::mysql::user: keystone
@@ -135,5 +132,8 @@ outputs:
           - '%'
           - "%{hiera('mysql_bind_host')}"
 
+        keystone::wsgi::apache::workers: {get_param: KeystoneWorkers}
+        # override via extraconfig:
+        keystone::wsgi::apache::threads: 1
       step_config: |
         include ::tripleo::profile::base::keystone