Open yungezz opened 2 years ago
It's likely that the issue here is that this is a -preview
api and we exclude those by default. You can specify
- action: include
group: servicelinker
version: v*api20211101preview
because: We want to export this particular preview version
we will also look into removing the need to specify this.
Thanks @matthchr . Previously I tried with include-transitive
. Will try include
.
This is something we're still interested in supporting, but haven't had time to implement. @yungezz, did you end up trying include
and did it work? We'd be open to accepting a PR for this if you wanted to provide one. Otherwise we will keep it in our backlog.
hi @matthchr, still get the matched no types
error, haven't chance to look at detail. Is there any configuration example of generating an extension resource? thanks
[controller:generate-types] E0719 13:24:09.759853 13872 gen_kustomize.go:111] Error during code generation:
[controller:generate-types] failed during pipeline stage 1/64: Load and walk schema: type filter action: "include": type matcher [Group: "servicelinker"; Version: "v*api20220501"; Name: "ServiceLinker"; Because: "including service linker resources"] matched no types; every group was excluded: no match for "servicelinker" (did you mean servicebus?)
The configuration is below
- action: include
group: servicelinker
version: v*api20220501
name: ServiceLinker
because: including service linker resources
after read latest v2 generator guideline, added below configuration in azure-arm.yaml
, section objectModelConfiguration
as below
servicelinker:
2022-05-01:
Linker:
$export: true
$supportedFrom: v2.0.0-alpha.2
met below error:
[controller:generate-types] I0825 07:07:50.225648 27086 code_generator.go:240] 21/64: Apply export filters to reduce the number of generated types
[controller:generate-types] E0825 07:07:50.279476 27086 gen_kustomize.go:111] Error during code generation:
[controller:generate-types] failed during pipeline stage 21/64: Apply export filters to reduce the number of generated types: group servicelinker not seen (did you mean servicebus?): group servicelinker: version 2022-05-01: type Linker: $export: true not consumed
task: Failed to run task "controller:quick-checks": task: Failed to run task "controller:generate-types": exit status 1
hi @matthchr could you help to look at the error? any guidance on how to generate ServiceLinker RP? thanks
Looks like this stalled back in August, but IIRC somebody reached out over Teams internally. We can revive this effort when we get time, or we would also accept a PR. There have been a lot of changes to the generator in the last 6 months so it might be worth retrying and seeing if what was not working before now works.
No change from above.
We're still interested in exploring this.
Support creation of ServiceLinker in ASOv2.
ServiceLinker is an Azure service to make service to service connection. It's extension resource, such as to Microsoft.Web/sites, Microsoft.Appplatform/app/deployment
ServiceLinker is an extension resource, so it's not listed in https://schema.management.azure.com/schemas/common/autogeneratedResources.json like RoleAssignment, which defined scope like managementgroup, subscription, resourcegroup etc. So when using code generator to generate, met below error:
More reference: