func()

in tools/mc2bq/pkg/export/v1.go [34:45]


func (mc *MCv1) AssetSource(ctx context.Context, pal mcutil.ProjectAndLocation) mcutil.ObjectSource {
	it := mc.client.ListAssets(ctx, &migrationcenterpb.ListAssetsRequest{
		Parent:   pal.String(),
		PageSize: 1000,
	})
	r := newObjectReader[*migrationcenterpb.Asset](it, "asset", mc.schema.AssetTable)
	src := newMigrationCenterLoadSource(r)
	return &struct {
		bigquery.LoadSource
		*objectReader[*migrationcenterpb.Asset]
	}{src, r}
}