Skip to content

Commit

Permalink
fix: change og_ prefex to platform_
Browse files Browse the repository at this point in the history
  • Loading branch information
artaasadi committed Nov 27, 2024
1 parent e1aca2a commit f862e3c
Show file tree
Hide file tree
Showing 408 changed files with 4,192 additions and 4,201 deletions.
5,933 changes: 2,962 additions & 2,971 deletions pkg/sdk/es/resources_clients.go

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions pkg/sdk/runable/steampipe_es_client_generator/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -384,8 +384,8 @@ func Get{{ .Name }}(ctx context.Context, d *plugin.QueryData, _ *plugin.HydrateD
s.ListFilters[fparts[0]] = fparts[1]
}
}
s.GetFilters["og_account_id"] = "metadata.IntegrationID"
s.ListFilters["og_account_id"] = "metadata.IntegrationID"
s.GetFilters["platform_account_id"] = "metadata.IntegrationID"
s.ListFilters["platform_account_id"] = "metadata.IntegrationID"
}

if s.Index != "" {
Expand Down
34 changes: 17 additions & 17 deletions steampipe-plugin-aws/aws/common_columns.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,19 +46,19 @@ func commonOgColumnsForAccountResource() []*plugin.Column {
Description: "The AWS Account ID in which the resource is located.",
},
{
Name: "og_account_id",
Name: "platform_account_id",
Type: proto.ColumnType_STRING,
Description: "The Platform Account ID in which the resource is located.",
Transform: transform.FromField("Metadata.SourceID"),
},
{
Name: "og_resource_id",
Name: "platform_resource_id",
Type: proto.ColumnType_STRING,
Description: "The unique ID of the resource in opengovernance.",
Transform: transform.FromField("ID"),
},
{
Name: "og_metadata",
Name: "platform_metadata",
Type: proto.ColumnType_STRING,
Description: "Platform Metadata of the AWS resource.",
Transform: transform.FromField("Metadata").Transform(marshalJSON),
Expand Down Expand Up @@ -87,25 +87,25 @@ func commonAwsOgRegionalColumns() []*plugin.Column {
Transform: transform.FromField("Metadata.AccountID"),
},
{
Name: "og_account_id",
Name: "platform_account_id",
Type: proto.ColumnType_STRING,
Description: "The Platform Account ID in which the resource is located.",
Transform: transform.FromField("IntegrationID"),
},
{
Name: "og_resource_id",
Name: "platform_resource_id",
Type: proto.ColumnType_STRING,
Description: "The unique ID of the resource in opengovernance.",
Transform: transform.FromField("PlatformID"),
},
{
Name: "og_metadata",
Name: "platform_metadata",
Type: proto.ColumnType_STRING,
Description: "Platform Metadata of the AWS resource.",
Transform: transform.FromField("Metadata").Transform(marshalJSON),
},
{
Name: "og_description",
Name: "platform_resource_description",
Type: proto.ColumnType_JSON,
Description: "The full model description of the resource",
Transform: transform.FromField("Description").Transform(marshalJSON),
Expand Down Expand Up @@ -153,19 +153,19 @@ func commonOgColumns() []*plugin.Column {
Transform: transform.FromField("Metadata.AccountID"),
},
{
Name: "og_account_id",
Name: "platform_account_id",
Type: proto.ColumnType_STRING,
Description: "The Platform Account ID in which the resource is located.",
Transform: transform.FromField("Metadata.SourceID"),
},
{
Name: "og_resource_id",
Name: "platform_resource_id",
Type: proto.ColumnType_STRING,
Description: "The unique ID of the resource in opengovernance.",
Transform: transform.FromField("ID"),
},
{
Name: "og_metadata",
Name: "platform_metadata",
Type: proto.ColumnType_STRING,
Description: "Platform Metadata of the AWS resource.",
Transform: transform.FromField("Metadata").Transform(marshalJSON),
Expand Down Expand Up @@ -221,19 +221,19 @@ func commonOgColumnsForGlobalRegionResource() []*plugin.Column {
Description: "The AWS Account ID in which the resource is located.",
},
{
Name: "og_account_id",
Name: "platform_account_id",
Type: proto.ColumnType_STRING,
Description: "The Platform Account ID in which the resource is located.",
Transform: transform.FromField("Metadata.SourceID"),
},
{
Name: "og_resource_id",
Name: "platform_resource_id",
Type: proto.ColumnType_STRING,
Description: "The unique ID of the resource in opengovernance.",
Transform: transform.FromField("ID"),
},
{
Name: "og_metadata",
Name: "platform_metadata",
Type: proto.ColumnType_STRING,
Description: "Platform Metadata of the AWS resource.",
Transform: transform.FromField("Metadata").Transform(marshalJSON),
Expand Down Expand Up @@ -261,25 +261,25 @@ func commonAwsOgColumns() []*plugin.Column {
Description: "The AWS Account ID in which the resource is located.",
},
{
Name: "og_account_id",
Name: "platform_account_id",
Type: proto.ColumnType_STRING,
Description: "The Platform Account ID in which the resource is located.",
Transform: transform.FromField("IntegrationID"),
},
{
Name: "og_resource_id",
Name: "platform_resource_id",
Type: proto.ColumnType_STRING,
Description: "The unique ID of the resource in opengovernance.",
Transform: transform.FromField("PlatformID"),
},
{
Name: "og_metadata",
Name: "platform_metadata",
Type: proto.ColumnType_STRING,
Description: "Platform Metadata of the AWS resource.",
Transform: transform.FromField("Metadata").Transform(marshalJSON),
},
{
Name: "og_description",
Name: "platform_resource_description",
Type: proto.ColumnType_JSON,
Description: "The full model description of the resource",
Transform: transform.FromField("Description").Transform(marshalJSON),
Expand Down
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/aws/plugin.go
Original file line number Diff line number Diff line change
Expand Up @@ -541,18 +541,18 @@ func Plugin(ctx context.Context) *plugin.Plugin {

opengovernanceTable := false
for _, col := range table.Columns {
if col != nil && col.Name == "og_account_id" {
if col != nil && col.Name == "platform_account_id" {
opengovernanceTable = true
}
}

if opengovernanceTable {
if table.Get != nil {
table.Get.KeyColumns = append(table.Get.KeyColumns, plugin.OptionalColumns([]string{"og_account_id", "og_resource_id"})...)
table.Get.KeyColumns = append(table.Get.KeyColumns, plugin.OptionalColumns([]string{"platform_account_id", "platform_resource_id"})...)
}

if table.List != nil {
table.List.KeyColumns = append(table.List.KeyColumns, plugin.OptionalColumns([]string{"og_account_id", "og_resource_id"})...)
table.List.KeyColumns = append(table.List.KeyColumns, plugin.OptionalColumns([]string{"platform_account_id", "platform_resource_id"})...)
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion steampipe-plugin-aws/docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ brand_color: "#FF9900"
display_name: "Amazon Web Services"
short_name: "aws"
description: "Steampipe plugin for querying instances, buckets, databases and more from AWS."
og_description: "Query AWS with SQL! Open source CLI. No DB required."
platform_resource_description: "Query AWS with SQL! Open source CLI. No DB required."
og_image: "/images/plugins/turbot/aws-social-graphic.png"
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/docs/table_def/aws_account.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/docs/table_def/aws_account_contact.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/docs/table_def/aws_acm_certificate.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/docs/table_def/aws_amp_workspace.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/docs/table_def/aws_amplify_app.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/docs/table_def/aws_api_gateway_stage.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
6 changes: 3 additions & 3 deletions steampipe-plugin-aws/docs/table_def/aws_api_gatewayv2_api.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<tr><td>partition</td><td>The AWS partition in which the resource is located (aws, aws-cn, or aws-us-gov).</td></tr>
<tr><td>region</td><td>The AWS Region in which the resource is located.</td></tr>
<tr><td>account_id</td><td>The AWS Account ID in which the resource is located.</td></tr>
<tr><td>og_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>og_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>og_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
<tr><td>platform_account_id</td><td>The Platform Account ID in which the resource is located.</td></tr>
<tr><td>platform_resource_id</td><td>The unique ID of the resource in opengovernance.</td></tr>
<tr><td>platform_metadata</td><td>Platform Metadata of the AWS resource.</td></tr>
</table>
Loading

0 comments on commit f862e3c

Please sign in to comment.