dsccommunity / dsccommunity/SqlServerDsc
SqlRole: Resource refactoring proposal
Nobody has claimed this yet.
- Dominant language
- PowerShell
- Stars
- 385
- Forks
- 224
- PR merge metrics
- No merged PRs in 30d
Description
Resource proposal
A class-based SqlRole resource would manage SQL Server server-level roles and memberships. It would use commands such as Get-SqlDscRole, New-SqlDscRole, Remove-SqlDscRole.
Proposed properties
| Property | Type qualifier | Data type | Description | Default value | Allowed values |
|---|---|---|---|---|---|
| Ensure | Key | String | Whether the role should be Present or Absent | Present | Present, Absent |
| ServerRoleName | Key | String | The name of the server role | None | Any valid server role name |
| Members | Write | String[] | Members of the role | None | Any valid login list |
| ServerName | Key | String | The SQL Server host name | None | Any valid server name |
| InstanceName | Key | String | The SQL Server instance name | None | Any valid instance name |
Special considerations or limitations
Should ensure proper handling of role membership changes, idempotency, and support all built-in and custom roles. Contributors should validate role existence and membership operations.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the existing SQL Server DSC resource patterns and the proposed Get-SqlDscRole, New-SqlDscRole, and Remove-SqlDscRole command interfaces. Define the class-based SqlRole resource around the listed properties, then validate role existence, membership changes, idempotency, and support for built-in and custom roles.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- powershell, sql
- Domain
- databases
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100