Fill in openstack-others project type
All projects located in 'openstack' organization, but not listed in the official projects list are grouped into 'openstack-others' project type. Change-Id: Ib7caee39294a24e0030de6c8a5116c9a31147a27
This commit is contained in:
@@ -15638,7 +15638,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"release_name": "Mitaka",
|
"release_name": "Mitaka",
|
||||||
"end_date": "2015-Apr-07",
|
"end_date": "2016-Apr-07",
|
||||||
"refs": {
|
"refs": {
|
||||||
"governance": {
|
"governance": {
|
||||||
"type": "big_tent",
|
"type": "big_tent",
|
||||||
@@ -15668,7 +15668,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "tc-approved-release",
|
"id": "tc-approved-release",
|
||||||
"title": "tc-approved",
|
"title": "tc-approved-release",
|
||||||
"child": true,
|
"child": true,
|
||||||
"modules": ["tc-approved-release"]
|
"modules": ["tc-approved-release"]
|
||||||
},
|
},
|
||||||
@@ -15684,6 +15684,11 @@
|
|||||||
"child": true,
|
"child": true,
|
||||||
"modules": ["type:library"]
|
"modules": ["type:library"]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"id": "openstack-others",
|
||||||
|
"title": "OpenStack Others",
|
||||||
|
"modules": ["openstack-others", "unknown"]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"id": "stackforge",
|
"id": "stackforge",
|
||||||
"title": "Stackforge",
|
"title": "Stackforge",
|
||||||
|
@@ -247,7 +247,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"release_name": "Mitaka",
|
"release_name": "Mitaka",
|
||||||
"end_date": "2015-Apr-07",
|
"end_date": "2016-Apr-07",
|
||||||
"refs": {
|
"refs": {
|
||||||
"governance": {
|
"governance": {
|
||||||
"type": "big_tent",
|
"type": "big_tent",
|
||||||
@@ -273,7 +273,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "tc-approved-release",
|
"id": "tc-approved-release",
|
||||||
"title": "tc-approved",
|
"title": "tc-approved-release",
|
||||||
"child": true,
|
"child": true,
|
||||||
"modules": ["tc-approved-release"]
|
"modules": ["tc-approved-release"]
|
||||||
},
|
},
|
||||||
@@ -289,6 +289,11 @@
|
|||||||
"child": true,
|
"child": true,
|
||||||
"modules": ["type:library"]
|
"modules": ["type:library"]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"id": "openstack-others",
|
||||||
|
"title": "OpenStack Others",
|
||||||
|
"modules": ["openstack-others", "unknown"]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"id": "stackforge",
|
"id": "stackforge",
|
||||||
"title": "Stackforge",
|
"title": "Stackforge",
|
||||||
|
@@ -57,7 +57,8 @@ Stackalytics {% if page_title %}| {{ page_title }} {% endif %}
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="drop">
|
<div class="drop">
|
||||||
<label for="project_type_selector" title="Project type groups modules of same kind: all official (listed in governance's projects.yaml), having the same tag and complementary">Project Type</label>
|
<label for="project_type_selector" title="Project type groups modules of the same kind. 'OpenStack' are projects defined in the official governance projects.yaml.
|
||||||
|
'OpenStack Others' are projects not included into any program. 'Complementary' are projects related to OpenStack ecosystem">Project Type</label>
|
||||||
<input type="hidden" id="project_type_selector" style="width: 140px" data-placeholder="Select project type"/>
|
<input type="hidden" id="project_type_selector" style="width: 140px" data-placeholder="Select project type"/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@@ -30,6 +30,7 @@ def _make_module_group(module_groups, name):
|
|||||||
m = module_groups[name] # object created by defaultdict
|
m = module_groups[name] # object created by defaultdict
|
||||||
m['tag'] = 'project_type'
|
m['tag'] = 'project_type'
|
||||||
m['module_group_name'] = name
|
m['module_group_name'] = name
|
||||||
|
m['releases'] = collections.defaultdict(list)
|
||||||
return m
|
return m
|
||||||
|
|
||||||
|
|
||||||
@@ -37,15 +38,6 @@ def read_legacy_programs_yaml(module_groups, release_name, content):
|
|||||||
all_official = module_groups['openstack-official']
|
all_official = module_groups['openstack-official']
|
||||||
|
|
||||||
for name, info in six.iteritems(content):
|
for name, info in six.iteritems(content):
|
||||||
# for one program
|
|
||||||
# group_id = name.lower()
|
|
||||||
# if 'codename' in info:
|
|
||||||
# name = '%s (%s)' % (info['codename'], name)
|
|
||||||
# group_id = '%s-group' % info['codename'].lower()
|
|
||||||
#
|
|
||||||
# module_groups[group_id]['module_group_name'] = name
|
|
||||||
# module_groups[group_id]['tag'] = 'program'
|
|
||||||
|
|
||||||
for module in info['projects']:
|
for module in info['projects']:
|
||||||
mn = module['repo'].split('/')[1] # module_name
|
mn = module['repo'].split('/')[1] # module_name
|
||||||
|
|
||||||
@@ -57,10 +49,6 @@ def read_early_big_tent_projects_yaml(module_groups, release_name, content):
|
|||||||
all_official = module_groups['openstack-official']
|
all_official = module_groups['openstack-official']
|
||||||
|
|
||||||
for name, info in six.iteritems(content):
|
for name, info in six.iteritems(content):
|
||||||
# group_id = '%s-group' % name.lower()
|
|
||||||
# module_groups[group_id]['module_group_name'] = '%s Official' % name
|
|
||||||
# module_groups[group_id]['tag'] = 'program'
|
|
||||||
|
|
||||||
for module in info['projects']:
|
for module in info['projects']:
|
||||||
repo_split = module['repo'].split('/')
|
repo_split = module['repo'].split('/')
|
||||||
if len(repo_split) < 2:
|
if len(repo_split) < 2:
|
||||||
@@ -94,7 +82,7 @@ def read_big_tent_projects_yaml(module_groups, release_name, content):
|
|||||||
tags = deliverable.get('tags', [])
|
tags = deliverable.get('tags', [])
|
||||||
for tag in tags:
|
for tag in tags:
|
||||||
if tag in TAGS:
|
if tag in TAGS:
|
||||||
module_groups[tag]['modules'].append(mn)
|
module_groups[tag]['releases'][release_name].append(mn)
|
||||||
|
|
||||||
|
|
||||||
def _make_default_module_groups():
|
def _make_default_module_groups():
|
||||||
@@ -103,8 +91,9 @@ def _make_default_module_groups():
|
|||||||
|
|
||||||
# openstack official
|
# openstack official
|
||||||
_make_module_group(module_groups, 'openstack-official')
|
_make_module_group(module_groups, 'openstack-official')
|
||||||
module_groups['openstack-official']['releases'] = (
|
|
||||||
collections.defaultdict(list))
|
# openstack others
|
||||||
|
_make_module_group(module_groups, 'openstack-others')
|
||||||
|
|
||||||
# tags
|
# tags
|
||||||
for tag in TAGS:
|
for tag in TAGS:
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
from oslo_config import cfg
|
from oslo_config import cfg
|
||||||
from oslo_log import log as logging
|
from oslo_log import log as logging
|
||||||
import psutil
|
import psutil
|
||||||
from six.moves.urllib import parse
|
import six
|
||||||
|
|
||||||
from stackalytics.processor import bps
|
from stackalytics.processor import bps
|
||||||
from stackalytics.processor import config
|
from stackalytics.processor import config
|
||||||
@@ -129,7 +129,8 @@ def _process_repo(repo, runtime_storage_inst, record_processor_inst,
|
|||||||
for branch in branches:
|
for branch in branches:
|
||||||
LOG.debug('Processing commits in repo: %s, branch: %s', uri, branch)
|
LOG.debug('Processing commits in repo: %s, branch: %s', uri, branch)
|
||||||
|
|
||||||
vcs_key = 'vcs:' + str(parse.quote_plus(uri) + ':' + branch)
|
vcs_key = 'vcs:' + str(six.moves.urllib.parse.quote_plus(uri) +
|
||||||
|
':' + branch)
|
||||||
last_id = runtime_storage_inst.get_by_key(vcs_key)
|
last_id = runtime_storage_inst.get_by_key(vcs_key)
|
||||||
|
|
||||||
commit_iterator = vcs_inst.log(branch, last_id)
|
commit_iterator = vcs_inst.log(branch, last_id)
|
||||||
@@ -144,7 +145,8 @@ def _process_repo(repo, runtime_storage_inst, record_processor_inst,
|
|||||||
|
|
||||||
LOG.debug('Processing reviews for repo: %s, branch: %s', uri, branch)
|
LOG.debug('Processing reviews for repo: %s, branch: %s', uri, branch)
|
||||||
|
|
||||||
rcs_key = 'rcs:' + str(parse.quote_plus(uri) + ':' + branch)
|
rcs_key = 'rcs:' + str(six.moves.urllib.parse.quote_plus(uri) +
|
||||||
|
':' + branch)
|
||||||
last_id = runtime_storage_inst.get_by_key(rcs_key)
|
last_id = runtime_storage_inst.get_by_key(rcs_key)
|
||||||
|
|
||||||
review_iterator = rcs_inst.log(repo, branch, last_id,
|
review_iterator = rcs_inst.log(repo, branch, last_id,
|
||||||
@@ -247,12 +249,21 @@ def process_project_list(runtime_storage_inst, project_list_uri):
|
|||||||
LOG.debug('Update module groups with official: %s', official_module_groups)
|
LOG.debug('Update module groups with official: %s', official_module_groups)
|
||||||
module_groups.update(official_module_groups)
|
module_groups.update(official_module_groups)
|
||||||
|
|
||||||
|
others = module_groups['openstack-others']
|
||||||
|
off_rm = module_groups['openstack-official']['releases']
|
||||||
|
official = dict((r, set(m)) for r, m in six.iteritems(off_rm))
|
||||||
|
|
||||||
# register modules as module groups
|
# register modules as module groups
|
||||||
repos = runtime_storage_inst.get_by_key('repos') or []
|
repos = runtime_storage_inst.get_by_key('repos') or []
|
||||||
for repo in repos:
|
for repo in repos:
|
||||||
module = repo['module']
|
module = repo['module']
|
||||||
module_groups[module] = utils.make_module_group(module, tag='module')
|
module_groups[module] = utils.make_module_group(module, tag='module')
|
||||||
|
|
||||||
|
# check if repo is official or not
|
||||||
|
for r, off_m in six.iteritems(official):
|
||||||
|
if module not in off_m:
|
||||||
|
others['releases'][r].append(module)
|
||||||
|
|
||||||
# register module 'unknown' - used for emails not mapped to any module
|
# register module 'unknown' - used for emails not mapped to any module
|
||||||
module_groups['unknown'] = utils.make_module_group('unknown', tag='module')
|
module_groups['unknown'] = utils.make_module_group('unknown', tag='module')
|
||||||
|
|
||||||
|
@@ -77,19 +77,30 @@ class TestGovernance(testtools.TestCase):
|
|||||||
'tc-approved-release': {
|
'tc-approved-release': {
|
||||||
'id': 'tc-approved-release',
|
'id': 'tc-approved-release',
|
||||||
'module_group_name': 'tc-approved-release',
|
'module_group_name': 'tc-approved-release',
|
||||||
'modules': ['sahara', 'sahara-extra', 'sahara-image-elements'],
|
'modules': [],
|
||||||
|
'releases': {
|
||||||
|
'liberty': ['sahara', 'sahara-extra',
|
||||||
|
'sahara-image-elements'],
|
||||||
|
},
|
||||||
'tag': 'project_type'
|
'tag': 'project_type'
|
||||||
},
|
},
|
||||||
'type:library': {
|
'type:library': {
|
||||||
'id': 'type:library',
|
'id': 'type:library',
|
||||||
'module_group_name': 'type:library',
|
'module_group_name': 'type:library',
|
||||||
'modules': ['python-saharaclient', 'sahara-dashboard'],
|
'modules': [],
|
||||||
|
'releases': {
|
||||||
|
'liberty': ['python-saharaclient', 'sahara-dashboard'],
|
||||||
|
},
|
||||||
'tag': 'project_type'
|
'tag': 'project_type'
|
||||||
},
|
},
|
||||||
'type:service': {
|
'type:service': {
|
||||||
'id': 'type:service',
|
'id': 'type:service',
|
||||||
'module_group_name': 'type:service',
|
'module_group_name': 'type:service',
|
||||||
'modules': ['sahara', 'sahara-extra', 'sahara-image-elements'],
|
'modules': [],
|
||||||
|
'releases': {
|
||||||
|
'liberty': ['sahara', 'sahara-extra',
|
||||||
|
'sahara-image-elements'],
|
||||||
|
},
|
||||||
'tag': 'project_type'
|
'tag': 'project_type'
|
||||||
},
|
},
|
||||||
'openstack-official': {
|
'openstack-official': {
|
||||||
@@ -103,6 +114,13 @@ class TestGovernance(testtools.TestCase):
|
|||||||
},
|
},
|
||||||
'tag': 'project_type'
|
'tag': 'project_type'
|
||||||
},
|
},
|
||||||
|
'openstack-others': {
|
||||||
|
'id': 'openstack-others',
|
||||||
|
'module_group_name': 'openstack-others',
|
||||||
|
'modules': [],
|
||||||
|
'releases': {},
|
||||||
|
'tag': 'project_type'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
releases = [{
|
releases = [{
|
||||||
|
Reference in New Issue
Block a user