This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
.SYNOPSIS | |
Applies SQL group membership (unless exists) on availablitiy group nodes using windows login, from a definition file. | |
.DESCRIPTION | |
Applies SQL group membership (unless exists) on availablitiy group nodes using windows logins and groups, from a definition file. | |
Based on a role definition file, SQL snippets are generated and then executed. | |
Removes any login/dbuser mapping that are in conflict with the securityDefinitionFile specification. | |
.PARAMETER masterEndpoints | |
List of FQDN[,<port>] of SQL nodes participating in the availability group | |
.PARAMETER instanceEndpoint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.ComponentModel; | |
using System.Linq.Expressions; | |
using System.Reflection; | |
namespace Extensions | |
{ | |
public static class ComponentModelExtensions | |
{ | |
public static TProperty GetPropertyValueOrDefault<TSource, TProperty>( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<#@ template debug="false" hostspecific="false" language="C#" #> | |
<#@ assembly name="System.Core" #> | |
<#@ import namespace="System" #> | |
<#@ output extension=".cs" #> | |
<# | |
string datePattern = "fffssmmHHddMMyyyy"; | |
string buildTime = DateTime.Now.ToString(datePattern); | |
string humanReadableBuildTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss:fff"); | |
#>using System; | |
using System.Globalization; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-16"?> | |
<Task version="1.2" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task"> | |
<RegistrationInfo> | |
<Date>2014-02-20T16:20:55.1120404</Date> | |
<Author>[account]</Author> | |
<Description>Attempts to start SERVICE_NAME. Logs the attempt to start it to a log file if the service was not started.</Description> | |
</RegistrationInfo> | |
<Triggers> | |
<EventTrigger> | |
<Enabled>true</Enabled> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace Extensions { | |
public static class StreamExtensions | |
{ | |
/// <summary> | |
/// Implementation of <see cref="Stream.CopyTo(System.IO.Stream)"/> with progress reporting | |
/// </summary> | |
/// <param name="fromStream"></param> | |
/// <param name="destination"></param> | |
/// <param name="bufferSize"></param> | |
/// <param name="progressInfo"></param> |
NewerOlder