Skip to content
Snippets Groups Projects
Commit 9734c67a authored by geant-release-service's avatar geant-release-service
Browse files

Finished release 0.64.

parents 1d1d837a 474ccd93
No related branches found
No related tags found
No related merge requests found
......@@ -61,6 +61,7 @@ DEFAULT_ORGANIZATIONS = [
"excluded_folders": {
"Aggregates": ["CAE1"],
"EUMETSAT Multicast": True,
"NREN Access LEGACY": True
}
},
{
......@@ -92,7 +93,7 @@ DEFAULT_ORGANIZATIONS = [
"GWS Direct": True,
"GWS Indirect": True,
"EUMETSAT Multicast": True,
"NREN Access BETA": True
"NREN Access LEGACY": True
}
},
{
......@@ -112,7 +113,8 @@ DEFAULT_ORGANIZATIONS = [
"EUMETSAT"
],
"excluded_folders": {
"EUMETSAT Multicast": True
"EUMETSAT Multicast": True,
"NREN Access LEGACY": True
}
},
{
......@@ -142,7 +144,7 @@ DEFAULT_ORGANIZATIONS = [
"IAS UPSTREAM": True,
"GWS PHY Upstream": True,
"EUMETSAT Multicast": True,
"NREN Access BETA": True
"NREN Access LEGACY": True
}
}
]
......
......
......@@ -39,7 +39,7 @@ from brian_dashboard_manager.templating.helpers import \
from brian_dashboard_manager.templating.gws import generate_gws, generate_indirect
from brian_dashboard_manager.templating.eumetsat import generate_eumetsat_multicast
from brian_dashboard_manager.templating.render import (
render_complex_dashboard,
render_with_aggregate_dashboard,
render_simple_dashboard,
)
......@@ -47,9 +47,9 @@ logger = logging.getLogger(__name__)
MAX_WORKERS = 4
DASHBOARDS = {
'NRENBETA': { # needed for POL1-642 BETA
'tag': ['customersbeta'],
'folder_name': 'NREN Access BETA',
'NRENLEGACY': {
'tag': ['customerslegacy'],
'folder_name': 'NREN Access LEGACY',
'interfaces': []
},
'NREN': {
......@@ -226,18 +226,16 @@ def provision_folder(token_request, folder_name, dash, services,
# dashboard should include error panels
errors = dash.get('errors', False)
is_nren_beta = folder_name == "NREN Access BETA" # needed for POL1-642 BETA
is_nren_legacy = folder_name == "NREN Access LEGACY"
is_nren = folder_name == "NREN Access"
is_re_peer = folder_name == "RE Peer"
is_service = 'service_type' in dash
# todo: figure out a neater way to do this?
is_complex = is_nren or is_nren_beta or is_re_peer or is_service
has_aggregate_panels = is_nren or is_nren_legacy or is_re_peer or is_service
if is_nren:
if is_nren_legacy:
data = get_nren_interface_data_old(interfaces)
dash_data = get_nren_dashboard_data(data, ds_name, tag)
elif is_nren_beta:
# needed for POL1-642 BETA
elif is_nren:
data = get_nren_interface_data(
services, interfaces, excluded_dashboards)
dash_data = get_nren_dashboard_data(data, ds_name, tag)
......@@ -259,8 +257,8 @@ def provision_folder(token_request, folder_name, dash, services,
with ThreadPoolExecutor(max_workers=MAX_WORKERS) as executor:
for dashboard in dash_data:
if is_complex:
rendered = render_complex_dashboard(**dashboard)
if has_aggregate_panels:
rendered = render_with_aggregate_dashboard(**dashboard)
else:
rendered = render_simple_dashboard(**dashboard)
......@@ -354,8 +352,6 @@ def excluded_folder_dashboards(org_config, folder_name):
excluded_folders = org_config.get('excluded_folders', {})
excluded = excluded_folders.get(folder_name, [])
# in is needed for POL1-642 BETA ('NREN Access BETA' folder)
# revert to == 'NREN Access' when beta is over
if 'NREN Access' in folder_name:
excluded_nrens = org_config.get('excluded_nrens', [])
excluded = list(set(excluded).union(set(excluded_nrens)))
......@@ -418,10 +414,9 @@ def _provision_interfaces(config, org_config, ds_name, token):
ifaces = DASHBOARDS[dash_name]['interfaces']
ifaces.append(iface)
# TODO: remove all references to NRENBETA
# when NREN service BETA is over (homedashboard/helpers)
if dash_name == 'NREN':
ifaces = DASHBOARDS['NRENBETA']['interfaces']
# add to NRENLEGACY list of interfaces, used for legacy NREN dashboards (not service-based)
ifaces = DASHBOARDS['NRENLEGACY']['interfaces']
ifaces.append(iface)
# add to matched aggregate dashboard
......
......
......@@ -126,9 +126,9 @@ def _render_links(staff):
{
"asDropdown": True,
"icon": "external link",
"tags": ["customersbeta"],
"tags": ["customerslegacy"],
"targetBlank": True,
"title": "NREN Access BETA",
"title": "NREN Access LEGACY",
"type": "dashboards",
}
)
......
......
......@@ -271,7 +271,7 @@ def create_infobox():
}
def render_complex_dashboard(
def render_with_aggregate_dashboard(
nren_name, aggregate_panels, dropdown_groups, tag=None, tags=None, **_
):
assert tag or tags
......
......
......@@ -2,6 +2,9 @@
All notable changes to this project will be documented in this file.
## [0.64] - 2024-08-14
- POL1-841 - Promote NREN Access Beta and keep Legacy dashboard for GEANT staff
## [0.63] - 2024-07-18
- POL1-700 - Managed Wavelength Service dashboard
- Service-type based dashboard support
......
......
......@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
setup(
name='brian-dashboard-manager',
version="0.63",
version="0.64",
author='GEANT',
author_email='swd@geant.org',
description='',
......
......
......@@ -631,15 +631,15 @@ def populate_inventory(data_config):
@pytest.mark.parametrize(
"folder_name, excluded_nrens, expected_nrens",
[
("NREN Access", [], ["GEANT", "KIAE", "SWITCH"]),
("NREN Access", ["GEANT", "KIAE"], ["SWITCH"]),
("NREN Access", [], ['ASNET-AM', 'CESNET', 'GEANT', 'KIAE', 'LITNET', 'SWITCH']),
("NREN Access", ["GEANT", "KIAE"], ['ASNET-AM', 'CESNET', 'LITNET', 'SWITCH']),
(
"NREN Access BETA",
"NREN Access",
[],
["ASNET-AM", "LITNET", "CESNET", "GEANT", "KIAE", "SWITCH"],
),
(
"NREN Access BETA",
"NREN Access",
["ASNET-AM", "GEANT"],
["LITNET", "CESNET", "KIAE", "SWITCH"],
),
......@@ -690,8 +690,8 @@ def test_provision_nren_folder(
excluded_nrens,
)
assert len(result) == len(expected_nrens)
for i, nren in enumerate(expected_nrens):
assert result[i]["title"] == nren
for i, nren in enumerate(result):
assert result[i]["title"] in expected_nrens
if "NREN" in folder_name:
# Every NREN dashboard must have at least 4 panels
# (3 default panels and 1 per ifc)
......
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment