Microsoft

System Center Configuration Manager Feedback

Suggestion box powered by UserVoice

How can we improve Configuration Manager?

Transaction support for PowerShell cmdlets

today when using powershell cmdlet the action is performed direct against the server, as example, if you want to create an application, add couple of deployment types and perform other small changes, you end up with lots of revisions (easily, 10). when you have lots of revisions, this start to impact the performance.

it would be nice if we can have the cmdlets transactional, in this case, you create the object and the changes does not apply to the database, you need to "save" the change.

on the application example, you could create the application, create the dt's, changes, etc. and at the end, user a "save" cmdlet and the data is written to the database, ending up with only 1 revision.

9 votes
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    Signed in as (Sign out)
    You have left! (?) (thinking…)
    Raphael Perez shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    2 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      Signed in as (Sign out)
      Submitting...
      • Ira Malinich commented  ·   ·  Flag as inappropriate

        Currently, to create an application requires at least two separate actions like this:

        New-CMApplication -Name "TestApp1";
        Add-CMMsiDeploymentType -ApplicationName "TestApp1" -ContentLocation "\\TestServer\Share\TestApp1.msi";

        This creates a new application starting at Revision 2 at least, more if I have to work around some bugs in New-CMApplication by using Set-CMApplication afterward, or if dependencies are required. If we could use something like New-CMMsiDeploymentType to create a new deployment type object in memory, then pass it to New-CMApplication which could create the application object in the database, complete with deployment type and any attached dependencies.
        I hope this would be less transactionally expensive when creating multiple applications in a batch, while reducing the revision counter.
        That might look something like this:

        $NewDepType = New-CMMsiDeploymentType -ApplicationName "TestApp1" -ContentLocation "\\TestServer\Share\TestApp1.msi";
        New-CMApplication -Name "TestApp1" -DeploymentTypeObjects $NewDepType;

      Feedback and Knowledge Base