Skip to content

Commit 4dada89

Browse files
authored
Add v1.2 conformance report table (#3427)
* Add v1.2 conformance report table Add Kong to v1.2 table * Update conformance report generation to have mode field Update script
1 parent 1fe2b9f commit 4dada89

File tree

4 files changed

+102
-48
lines changed

4 files changed

+102
-48
lines changed

hack/mkdocs-generate-conformance.py

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -57,18 +57,18 @@ def generate_conformance_tables(reports, currVersion):
5757
gateway_grpc_table = pandas.DataFrame()
5858

5959
if currVersion != 'v1.0.0':
60-
gateway_http_table = generate_profiles_report(reports, 'GATEWAY-HTTP')
60+
gateway_http_table = generate_profiles_report(reports, 'GATEWAY-HTTP',currVersion)
6161

62-
gateway_grpc_table = generate_profiles_report(reports, 'GATEWAY-GRPC')
62+
gateway_grpc_table = generate_profiles_report(reports, 'GATEWAY-GRPC',currVersion)
6363
gateway_grpc_table = gateway_grpc_table.rename_axis('Organization')
6464

65-
gateway_tls_table = generate_profiles_report(reports, 'GATEWAY-TLS')
65+
gateway_tls_table = generate_profiles_report(reports, 'GATEWAY-TLS',currVersion)
6666
gateway_tls_table = gateway_tls_table.rename_axis('Organization')
6767

68-
mesh_http_table = generate_profiles_report(reports, 'MESH-HTTP')
68+
mesh_http_table = generate_profiles_report(reports, 'MESH-HTTP',currVersion)
6969
else:
70-
gateway_http_table = generate_profiles_report(reports, "HTTP")
71-
mesh_http_table = generate_profiles_report(reports, "MESH")
70+
gateway_http_table = generate_profiles_report(reports, "HTTP",currVersion)
71+
mesh_http_table = generate_profiles_report(reports, "MESH",currVersion)
7272

7373
gateway_http_table = gateway_http_table.rename_axis('Organization')
7474
mesh_http_table = mesh_http_table.rename_axis('Organization')
@@ -97,29 +97,31 @@ def generate_conformance_tables(reports, currVersion):
9797
f.write(mesh_http_table.to_markdown())
9898

9999

100-
def generate_profiles_report(reports, route):
100+
def generate_profiles_report(reports, route,version):
101101

102102
http_reports = reports.loc[reports["name"] == route]
103103
http_reports.set_index('organization')
104104
http_reports.sort_values(['organization', 'version'], inplace=True)
105105

106106
http_table = pandas.DataFrame(
107107
columns=http_reports['organization'])
108+
108109
http_table = http_reports[['organization', 'project',
109-
'version', 'extended.supportedFeatures']].T
110+
'version','mode', 'extended.supportedFeatures']].T
110111
http_table.columns = http_table.iloc[0]
111112
http_table = http_table[1:].T
112113

113114
for row in http_table.itertuples():
114-
if type(row._3) is list:
115-
for feat in row._3:
115+
if type(row._4) is list:
116+
for feat in row._4:
116117
http_table.loc[row.Index, feat] = ':white_check_mark:'
117118
http_table = http_table.fillna(':x:')
118119
http_table = http_table.drop(['extended.supportedFeatures'], axis=1)
119120

120121
http_table = http_table.rename(
121-
columns={"project": "Project", "version": "Version"})
122-
122+
columns={"project": "Project", "version": "Version", "mode":"Mode"})
123+
if version == 'v1.0.0':
124+
http_table = http_table.drop(columns=["Mode"])
123125
return http_table
124126

125127

@@ -149,7 +151,7 @@ def getYaml(conf_path):
149151

150152
x = load_yaml(p)
151153
profiles = pandas.json_normalize(
152-
x, record_path='profiles', meta=["implementation"])
154+
x, record_path=['profiles'], meta=["mode","implementation"], errors='ignore')
153155

154156
implementation = pandas.json_normalize(profiles.implementation)
155157
yamls.append(pandas.concat([implementation, profiles], axis=1))

mkdocs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ nav:
8484
- Implementations:
8585
- List: implementations.md
8686
- Comparisons:
87+
- v1.2: implementations/v1.2.md
8788
- v1.1: implementations/v1.1.md
8889
- v1.0: implementations/v1.0.md
8990
- FAQ: faq.md

0 commit comments

Comments
 (0)