Skip to content

Instantly share code, notes, and snippets.

View BizTalkDocumenterTitlePage
<HTML>
<HEAD>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<TITLE>BizTalk Configuration</TITLE>
<LINK href="CommenTReport.css" type="text/css" rel="stylesheet"/>
</HEAD>
<BODY>
<SPAN class="StartOfFile"/>
<TABLE cellspacing="0" width="100%">
<TR bgcolor="#FAF5F9">
@pacodelacruz
pacodelacruz / mulesoftsql-databaseconfig.xml
Last active Oct 7, 2015
MuleSoft Global Configuration Element for a SQL Server database
View mulesoftsql-databaseconfig.xml
<db:generic-config name="MSSQL_AdventureWorks_Configuration"
url="jdbc:sqlserver://${mssql.server}:${mssql.port};databaseName=${mssql.database};user=${mssql.user};password=${mssql.password}"
driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver"
doc:name="Generic Database Configuration"/>
View wcfclientmutualauth.cs
using System;
using System.Configuration;
using System.IdentityModel.Tokens;
using System.Linq;
using System.Net;
using System.Net.Security;
using System.ServiceModel;
using System.ServiceModel.Security;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
View wcfclientmutualauthconfig.xml
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<appSettings>
<add key="ClientPFX" value="certificates\ClientPFX.pfx" />
<add key="ClientPFXPassword" value="********" />
<add key="TrustedCAPublicKey" value="certificates\ServiceCAPublicKey.cer" />
<add key="ServicePublicKey" value="certificates\ServicePublicKey.cer" />
</appSettings>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
View WebJobApiTriggeredStatus.json
{
"latest_run": {
"id": "201602292350000001",
"name": "201602292350000001",
"status": "Success",
"start_time": "2016-02-29T23:50:00.0001000Z",
"end_time": "2016-02-29T23:51:59.9999999Z",
"duration": "00:01:59.999899",
"output_url": "https://pacodelacruz-webapp.scm.azurewebsites.net/vfs/data/jobs/triggered/mywebjob/201602292350000001/output_log.txt",
"error_url": null,
View Get-KuduApiAuthorisationHeaderValue.ps1
function Get-KuduApiAuthorisationHeaderValue($resourceGroupName, $webAppName, $slotName = $null){
$publishingCredentials = Get-AzureRmWebAppPublishingCredentials $resourceGroupName $webAppName $slotName
return ("Basic {0}" -f [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes(("{0}:{1}" -f $publishingCredentials.Properties.PublishingUserName, $publishingCredentials.Properties.PublishingPassword))))
}
View Get-AzureRmWebAppPublishingCredentials.ps1
function Get-AzureRmWebAppPublishingCredentials($resourceGroupName, $webAppName, $slotName = $null){
if ([string]::IsNullOrWhiteSpace($slotName)){
$resourceType = "Microsoft.Web/sites/config"
$resourceName = "$webAppName/publishingcredentials"
}
else{
$resourceType = "Microsoft.Web/sites/slots/config"
$resourceName = "$webAppName/$slotName/publishingcredentials"
}
$publishingCredentials = Invoke-AzureRmResourceAction -ResourceGroupName $resourceGroupName -ResourceType $resourceType -ResourceName $resourceName -Action list -ApiVersion 2015-08-01 -Force
View WebTestWebJobEscaped.json
"WebTest": "<WebTest Name=\"My Web Job Health Monitor\" Id=\"aaa239ee-097b-46cd-8890-2ae7a05edbbb\"
Enabled=\"True\" CssProjectStructure=\"\" CssIteration=\"\" Timeout=\"120\" WorkItemIds=\"\"
xmlns=\"http://microsoft.com/schemas/VisualStudio/TeamTest/2010\" Description=\"\"
CredentialUserName=\"\" CredentialPassword=\"\" PreAuthenticate=\"True\" Proxy=\"default\"
StopOnError=\"False\" RecordedResultFile=\"\" ResultsLocale=\"\"><Items><Request Method=\"GET\"
Guid=\"aaa5ae9c-35c3-c677-a930-27c90877dbbb\" Version=\"1.1\"
Url=\"https://pacodelacruz-webapp.scm.azurewebsites.net/api/triggeredwebjobs/mywebjob/\"
ThinkTime=\"0\" Timeout=\"120\" ParseDependentRequests=\"False\" FollowRedirects=\"True\"
RecordResult=\"True\" Cache=\"False\" ResponseTimeGoal=\"0\" Encoding=\"utf-8\"
ExpectedHttpStatusCode=\"200\" ExpectedResponseUrl=\"\" ReportingName=\"\"
View WebJobWebTestTemplate.xml
<WebTest Name="My Web Job Health Monitor" Id="aaa239ee-097b-46cd-8890-2ae7a05edbbb" Enabled="True" CssProjectStructure="" CssIteration="" Timeout="120" WorkItemIds="" xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2010" Description="" CredentialUserName="" CredentialPassword="" PreAuthenticate="True" Proxy="default" StopOnError="False" RecordedResultFile="" ResultsLocale="">
<Items>
<Request Method="GET" Guid="aaa5ae9c-35c3-c677-a930-27c90877dbbb" Version="1.1" Url="https://pacodelacruz-webapp.scm.azurewebsites.net/api/triggeredwebjobs/mywebjob/" ThinkTime="0" Timeout="120" ParseDependentRequests="False" FollowRedirects="True" RecordResult="True" Cache="False" ResponseTimeGoal="0" Encoding="utf-8" ExpectedHttpStatusCode="200" ExpectedResponseUrl="" ReportingName="" IgnoreHttpStatusCode="False" />
</Items>
<ValidationRules>
<ValidationRule Classname="Microsoft.VisualStudio.TestTools.WebTesting.Rules.ValidationRuleFindText, Microsoft.VisualStudio.QualityTools.WebTestFramework, Version=10.0.0.0
View WebJobWebTestHeader.xml
<Headers>
<Header Name="Authorization" Value="Basic BAs3643nc0D3dS3Cr3T0k3n0123456789BAs3643nc0D3dS3Cr3T0k3n0123456789BAs3643nc0D3dS3Cr3T0k3nBAs3643nc0D3dS3" />
</Headers>