jdamata / terraform-provider-sonarqube

Terraform provider for managing Sonarqube configuration
GNU General Public License v3.0
64 stars 58 forks source link

Data Source: Bulk retrieve rules #84

Open tbutler-qontigo opened 2 years ago

tbutler-qontigo commented 2 years ago

Hi there,

It would be very useful to be able to retrive rules matching a set of supplied criteria as we can with the api/rules/search endpoint.

Terraform Version

Terraform v1.2.2 on windows_amd64

Affected Data Source

Expected Behavior

I would like to be able to retrieve a set of rules rather than just a single rule.

Actual Behavior

No way to achieve this using the provider - it is necessary to use a http provider to interact with the API directly/

References

http://localhost:9000/web_api/api/qualityprofiles/search

e.g. to retrieve all non-deprecated CRITICAL code smells: http://localhost:9000/api/rules/search?ps=500&languages=cs&types=CODE_SMELL&statuses=READY&severities=CRITICAL