You are here

Feed aggregator

IntelliTest - One Test to rule them all

MSDN Blogs - 2 hours 33 min ago

In traditional unit test suites, each test case represents an exemplary usage scenario, and the assertions embody the relationship between the input and output.  Verifying a few such scenarios might well be enough, but experienced developers know that bugs lurk even in well-tested code, when correct but untested inputs provoke wrong responses.

Generating traditional unit tests

IntelliTest generates traditional unit test suites. When run on a piece of code-under-test, the IntelliTest engine tries to generate a test suite with high code coverage (in particular, it focuses on branch coverage by default). It does so by iteratively synthesizing precise concrete inputs that let it execute deeper and deeper into the code-under-test. The generated traditional test suite contains an individual test case for each such concrete input and assertions on the corresponding observed output. The inputs include edge cases that the developer might have missed.

'How is that testing whether the code is correct or not? How useful is a test suite that provides high code coverage for an add method that might actually be doing a multiplication?' one might think.

Even without knowing about the intended and correct behaviour, the IntelliTest generated test suite describes the actual observed behaviour of the code under test. By itself this is useful as characterization tests, protecting existing behaviour against unintended changes.

Testing for correctness

Testing for correctness can be introduced naturally into this approach using assertions. Assertion statements (for e.g. Debug.Assert) are all compiled down to branches - an if statement with a then branch and an else branch representing the outcome of the predicate being asserted. Since the engine computes inputs to exercise branches, it ends up exercising such assertions as well. Thus, if the code-under-test contains assertions representing its correct behaviour, then IntelliTest ends up generating a test suite that validates such correctness. Assertions connect code coverage and correctness.

One Test to rule them all

As a developer our understanding of the code-under-test will eventually grow beyond what can be represented by a few individual example test cases. By understanding the code-under-test and the individual unit tests, we might arrive at a more general representation of its behaviour. Instead of saying ‘for this input, this is the expected result’ we might be able to say ‘this method performs this kind of a computation on its inputs’ - instead of saying ‘codeUnderTest(2) should return 4’ one might be able to say ‘codeUnderTest takes an integer and doubles it’. We have hoisted exemplary usage scenarios to a level where they capture a general relationship between inputs and outputs. Such a relationship can be encapsulated in a method that looks like a test method but is universally quantified - any assertions we make must hold for all possible input values - universally quantified assertions or "for all" assertions, if you will. For example, the following is one such universally quantified method that asserts that after adding an element to a non-null list, the element is indeed contained in the list:

Assumptions work well in such cases, placing restrictions on the input data and exposing developer intent along the way, and IntelliTest provides a rich Assumptions API. The example shows the use of the special assertion API that IntelliTest provides, but we can as well use the ones that come with the test framework. IntelliTest emits a stub for such a universally quantified method - this is the parameterized unit test method (PUT or “the” IntelliTest) we discussed in the previous post. It serves as the partial specification for the code-under-test. Elaborating it does not require or introduce any new language or artifact. It’s written at the level of the actual APIs implemented by the software product, and in the programming language of the software product. IntelliTest exploration can be launched directly on the code-under-test or on this parameterized unit test to generate and update the suite of traditional unit tests. This unlocks the full potential of IntelliTest.

We started this post saying that IntelliTest tries to generate a suite with high code coverage. The organization and complexity of the code-under-test present IntelliTest several barriers in this. In a future post we will walk through how they may be achieved.

Integrating Testing into the CI and CD pipelines

MSDN Blogs - 3 hours 22 min ago
Testing in Continuous Integration and Continuous Deployment Workflows

At a high level DevOps is a focus on increasing customer value by reducing cycle times in the development process.  As a result of these faster cycle times testing as part of the DevOps workflow can be challenge. This section will look at integrating testing into CI/CD pipelines using to ensure less friction in the testing process and a high quality application.   While it probably makes sense to run these tests as part of the CD pipeline at the time of this authoring that is not working so we will implement this as part of the CI Build process.


Step 1. Creating a machine group.  In the Test menu, click on the machines menu.  Click the Action button (Green Plus) to create new machine group.  If we are running low on time consider reusing the Xlab Machine Group that already exists. Even if you do decide to reuse the the preexisting Machine Group as a corner stone of the Testing CI offering please at least open the Test hub and the “Machines” menu.  Select the Test CI machine group and select edit and take a look at the definition.  

Step 2.  Adding Machines to a machine group. To enable testers to very easily run the same test against multiple machines we can add several computers to a machine group.  For user name type in your domain credentials in the DOMAIN/NAME syntax.  For The machine name, please enter an IP Address or FQDN i.e.

There several caveats for computers to be access with this early version of the Test CI agent and workflow.

  1. We do not have the support for test machines residing in Azure yet. However this is coming soon.
  2. We do not support the Hosted Build controller.
  3. The build agent and test agent machines should be on-premises machines and the build machine should be able to communicate with the target test machine.
  4. The build agent being used for the Test CI tasks must be domain joined
  5. The computer being added the machine group must be domain joined
  6. Need to enable winrm on your test agent machine (run winrm quickconfig to enable this)
  7. We do not support use of the “hosted” build pool for the Test CI tasks
  8. Do not install test agents for visual studio 2015 on a machine with VS2015RC.  There is known issue here that we have fixed for RTM.

Step 3. Edit the Build definition to Add the Test CI Tasks to the CI Pipeline.

Step 4. Add the Test CI tasks

While this is shown in the CD pipleine

Step 5 Configure the Deploy Agent step

Step 6 Configure the Windows Test Agent Deployment


Step 7 Configure the run with Agent

Step 8 Running the build

Step 9 Monitoring the execution

Azure Web Apps - 如何針對特定錯誤進行除錯

MSDN Blogs - 7 hours 59 min ago

對於Azure Web Apps的使用者來說, Azure App Service Support 是我們的好朋友,還不知道該如何使用,請參考 這篇

若Azure Web Apps 持續出現特定錯誤,可利用Azure App Service Support 中的Analyze功能快速找到問題點:


先至Azure Portal - Web Apps - Diagnostics Logs - Failed Request Tracing 功能設定為[On]。

圖一, 在Azure Portal中,將Web App的log功能開啟


待問題重現後,訪問 Azure App Service Support site - Analyze - FREB Logs ,就可以找到對應錯誤log。

圖二, Azure App Service Support site中的Analyze功能


在FREB log中可以檢查完整的錯誤訊息內容,可幫助快速釐清問題原因並解決問題。

圖三, FREB log



OpsMgr: Sample Object Health Dashboard with “RAINBOW Bar” Columns

MSDN Blogs - 8 hours 3 min ago

This article features another sample dashboard that consist of a state widget with Rainbow Bar columns created from a custom column generator component. In each row, there is a monitored server object, the total number of its related monitoring objects, how many of these objects are in Critical state, Warning state, Healthy or Not Monitored.      
I also added a book plug with this summary dashboard to help spread the word about this free e-book:
Microsoft System Center Data Protection for the Hybrid Cloud, authored by Shreesh Dubey, Vijay Tandra Sistla, Shivam Garg, and Aashish Ramdas with Mitch Tulloch as Series Editor.

For more information, please visit here.

The e-book can be downloaded from the Microsoft Virtual Academy here.

The management pack bundle (MPB) for this Sample Object Health Dashboard can now be downloaded from the TechNet Gallery.

The key component used here to generate the custom columns with “Rainbow Bars” per row is the “Microsoft.Exchange.15.Visualization.Components.Common.DataObjectColumnGenerator" component defined in the Microsoft Exchange Server 2013 Visualization Library management pack (Microsoft.Exchange.15.Visualization.Components).

This component is used within the Exchange 2013 Organization and Server Summary Dashboards. Here’s an example of what the Exchange 2013 Organization Dashboard looks like ( Current Version: ):

Important Note:

The Microsoft Exchange Server 2013 Visualization Library management pack has a dependency on the main Microsoft Exchange Server 2013 Monitoring management pack, hence both management packs will need to be imported together if not already in order for the “Microsoft.Exchange.15.Visualization.Components.Common.DataObjectColumnGenerator" component to be available for use by other dashboards/widgets.  

A warning message as follows will be presented for a final confirmation to import the Microsoft Exchange Server 2013 Monitoring management pack.

3 new Datasets will be created for Exchange 2013 in the data warehouse database.

Before MP Import:

After MP Import:

Here is the PowerShell script used in the PowerShell Datasource component to retrieve health state of each of the objects related to the a server object, convert results to “RAINBOWDATA” type and return the collection to the column generator component of the State Widget:


$WindowsServerClass = Get-SCOMClass -Name "Microsoft.Windows.Server.Computer"
$serverObjects = Get-SCOMClassInstance -class $WindowsServerClass

$dataObjects = @()

$yellow = [double]0
  $green = [double]0
  $red   = [double]0
  $gray   = [double]0
$white   = [double]0
  $all   = [double]0

foreach ($serverObject in $serverObjects) {
  $dataObject = $ScriptContext.CreateFromObject($serverObject, "Id=Id,HealthState=HealthState,Name=Name", $null)

if ($dataObject -ne $null)  {    

#Get & record the health state of each of the objects related to the a server object(Microsoft.Windows.Server.Computer)

$relatedItems = $serverObject.GetRelatedMonitoringObjects()

    foreach ($relatedItem in $relatedItems)
         If($relatedItem.HealthState.toString() -eq "Success"){$green++}
         ElseIf($relatedItem.HealthState.toString() -eq "Warning"){$yellow++}
         ElseIf($relatedItem.HealthState.toString() -eq "Error"){$red++}
          ElseIf($relatedItem.HealthState.toString() -eq "Uninitialized"){$gray++}
    If($relatedItem.IsAvailable -ne $True){$white++}

$dataObject["TotalRelatedObjectField"] = "TotalRelatedObjects:"
$Overallstat = $ScriptContext.CreateInstance("RAINBOWDATA") 
   $Overallstat["GreenValue"] = $green
   $Overallstat["YellowValue"] = $yellow
   $Overallstat["RedValue"] = $red
   $Overallstat["GrayValue"] = $gray  
   $Overallstat["Sum"] = $relatedItems.count
   $dataObject["AppPoolCount"] = $Overallstat
Resulting Columns:

$dataObject["CriticalRelatedObjectField"] = "InCritical:"
$Criticalstat = $ScriptContext.CreateInstance("RAINBOWDATA")

  $Criticalstat["RedValue"] = $red 
  $dataObject["HealthStateCritical"] = $Criticalstat
Resulting Columns:

$dataObject["WarningRelatedObjectField"] = "InWarning:"
$Warningstat = $ScriptContext.CreateInstance("RAINBOWDATA")
  $Warningstat["YellowValue"] = $yellow 
  $dataObject["HealthStateWarning"] = $Warningstat
Resulting Columns:

$dataObject["HealthyRelatedObjectField"] = "Healthy:"
$Healthystat = $ScriptContext.CreateInstance("RAINBOWDATA")
  $Healthystat["GreenValue"] = $green 
  $dataObject["HealthStateHealthy"] = $Healthystat
Resulting Columns:

$dataObject["GrayRelatedObjectField"] = "NotMonitored:"
$Graystat = $ScriptContext.CreateInstance("RAINBOWDATA")
  $Graystat["GrayValue"] = $gray 
  $dataObject["HealthStateGray"] = $Graystat #////////////////////////////////////////////////////////////////////////////////////////
Resulting Columns:

  $white   = [double]0   
  $gray   = [double]0   
  $yellow = [double]0
  $green = [double]0
  $red   = [double]0
  $all   = [double]0

  $dataObjects += $dataObject 

foreach ($dataObject in $dataObjects)

#////////////////////////// Script End /////////////////////////////////  

The RainbowData is a complexType with the following double typed elements:     

<xs:complexType name="RainbowData" xmlns:sc="" xmlns:xs="">
  < xs:sequence minOccurs="1" maxOccurs="1">
    < xs:element name="WhiteValue" type="xs:double" />
    < xs:element name="GreenValue" type="xs:double" />
    < xs:element name="YellowValue" type="xs:double" />
    < xs:element name="RedValue" type="xs:double" />
    < xs:element name="GrayValue" type="xs:double" />
    < xs:element name="Sum" type="xs:double" />
< /xs:complexType>


When the sample MP is imported into a OpsMgr 2012 environment, the summary dashboard will appear at the root of the Monitoring Workspace with display name as: Sample Rainbow Bar Health Dashboard:


When selected, a summary health dashboard that looks similar to the following example will be displayed:

Important Note:

The reason why column headers were not used for the state widget of the sample health dashboard was because the column generator was hardcoded to only display the strings defined in the Microsoft Exchange Server 2013 Visualization Library management pack on the headers of the columns generated.

Therefore, any other strings used for the column header names would not appear on the state widget, example as follows:

Here is the list of string resources and their corresponding display string that are defined in the Microsoft Exchange Server 2013 Visualization Library management pack:

If StringResource ID is used: Will display: Microsoft.Exchange.15.Visualization.Components.HealthStateCriticalDisplayString Critical Microsoft.Exchange.15.Visualization.Components.HealthStateWarningDisplayString Warning Microsoft.Exchange.15.Visualization.Components.HealthStateHealthyDisplayString Healthy Microsoft.Exchange.15.Visualization.Components.HealthStateDescUnknownDisplayString Unknown Microsoft.Exchange.15.Visualization.Components.HealthStateDescNormalDisplayString Pass "Microsoft.Exchange.15.Visualization.Components.HealthStateDescErrorDisplayString Fail Microsoft.Exchange.15.Visualization.Components.AlertsTextDisplayString alerts Microsoft.Exchange.15.Visualization.Components.NewAlertsTextDisplayString new Exchange.15.Visualization.OrganizationGridData.HealthState State Exchange.15.Visualization.OrganizationGridData.InMaintenanceMode Maintenance Mode Exchange.15.Visualization.OrganizationGridData.Name Organization Exchange.15.Visualization.OrganizationGridData.AlertsCount Alerts Exchange.15.Visualization.OrganizationGridData.DagRainbow DAGs Exchange.15.Visualization.OrganizationGridData.ADSiteRainbow AD Sites Exchange.15.Visualization.OrganizationGridData.CasRainbow CA Servers Exchange.15.Visualization.OrganizationGridData.MbxRainbow Mailbox Servers Exchange.15.Visualization.OrganizationGridData.EtRainbow ET Servers Exchange.15.Visualization.OrganizationGridData.MbxDbCount Mailbox Databases Exchange.15.Visualization.OrganizationGridData.MailboxCount Mailboxes Exchange.15.Visualization.ServerGridData.HealthState State Exchange.15.Visualization.ServerGridData.InMaintenanceMode Maintenance Mode Exchange.15.Visualization.ServerGridData.Name Name Exchange.15.Visualization.ServerGridData.Organization Organization Exchange.15.Visualization.ServerGridData.ServerRole Roles Exchange.15.Visualization.ServerGridData.ADSite AD Site Exchange.15.Visualization.ServerGridData.Dag DAG Exchange.15.Visualization.ServerGridData.CAArray CA Array Exchange.15.Visualization.ServerGridData.NTServiceRainbow Windows Services Exchange.15.Visualization.ServerGridData.AppPoolCount IIS Application Pools Exchange.15.Visualization.ServerGridData.ServerResourcesHealthSetRainbow Server Resources Exchange.15.Visualization.ServerGridData.ServiceComponentsHealthSetRainbow Service Components Exchange.15.Visualization.ServerGridData.CustomerTouchPointsHealthSetRainbow Customer Touch Points Exchange.15.Visualization.ServerGridData.KeyDependenciesHealthSetRainbow Key Dependencies Exchange.15.Visualization.ServerGridData.AlertsCount Alerts Exchange.15.Visualization.ServerGridData.MbxDbCount Mailbox Databases Exchange.15.Visualization.ServerGridData.MbxCount Mailboxes Exchange.15.Visualization.ServerGridData.CpuUsage CPU (%) Exchange.15.Visualization.ServerGridData.MemoryUsage Memory (MB) Exchange.15.Visualization.ServerGridData.Version Version Exchange.15.Visualization.ServerGridData.IPAddress IP Address Exchange.15.TestObject.State State Exchange.15.TestObject.IntValue Number Exchange.15.TestObject.PercentBarValue Blue cell Exchange.15.TestObject.RainbowBarValue Rainbow Exchange.15.TestObject.DoubleValue Double Exchange.15.TestObject.StringValue Status String Exchange.15.TestObject.SecondStringValue Second String

Related post:
Sample OS Summary Dashboard with “Blue Bar” Columns

For more information about OpsMgr 2012 Dashboard Component Types and Implementations, go to:

Thank you for your support !


All information on this blog is provided on an as-is basis with no warranties and for informational purposes only. Use at your own risk. The opinions and views expressed in this blog are those of the author and do not necessarily state or reflect those of my employer.


如何針對 Azure Web App / Azure Websites 進行除錯

MSDN Blogs - 10 hours 9 min ago

過去我們都會運用Azure Web KUDU console 進行問題排除或除錯,目前有更好的工具提供給Azure Web App 管理及開發人員: Azure App Service Support



  1. 若已經登入Azure Portal,則可以自動登入Azure App Service Support 網站。
  2. 若尚未登入Azure Portal,則可以透過,進行登入。

圖一, 選擇要進行除錯的Web App


功能一: 效能觀察

目前有提供平均每秒訪問數量(Avg. Requests/sec) 及平均每秒伺服器錯誤 (Avg. Server Errors/sec) 這兩個觀察指標供管理人員進行初步判斷此Web App是否有效能問題。

圖二, Observe 功能提供整體效能觀察


功能二: 問題分析

若Web App 有效能問題,可點選 [Diagnose Now] 進行立即診斷,稍等片刻後即可在下方得到Event log, Memory dump, HTTP log, PHP error log及PHP Process report 等log檔案,這些檔案就可以提供後續問題分析的依據。

圖三, Analyze 提供相關log收集及分析功能


功能三: 問題緩解

若問題在短時間內無法被解決或是想要有個快速解決方案,Mitigate功能提供了快速解藥: 可以針對[Max Request], [Status Code], [Slow Request], [Memory Private Set] 這四種常見問題情況進行設定,

圖四, Mitigate提供常見問題緩解規則設定


後續我會繼續提供Analyze及Mitigate深入應用範例。 Enjoy! 



MSDN Blogs - 11 hours 27 min ago










うまい人って無意識にやっていると思うんだけど違うかな? 僕はここはしっかり押さえます。登壇すると極度に緊張するたちなので。その時の空気で適当に話しているように見えますが、いつもぎりぎりまで頭で考えています。






2.そこに行きつくストーリーと盛り上げを考えたり: 基礎で言えばホラーストリートかあるけどね。


SharePoint Check Permissions on site permissions page works intermittently with SAML claims Auth..

MSDN Blogs - Sat, 07/04/2015 - 22:23


Came Across an interesting situation , where when we use "Check Permissions" to find out permissions of user on a SharePoint site , it would Show as "None" & then work occasionally work without any changes being done to permissions in SharePoint or User account . This started happening after customer Implemented ADFS for SAML authentication on this Specific Web-application .

Here is the scenario for the setup

You setup ADFS SAML authentication for a Sharepoint Web-application. The ADFS is configured to use LDAP attributes as claims with following being used

Identity claim : Email Address

Role : Token-groups -Unqualified Names

Permissions were defined by Means of End users being added to Active Directory groups & these being indeed added to Inbuilt Sharepoint Groups .

Note : While adding an AD group to a Sharepoint Group , AD Groups Role Claims was Selected.

Interestingly One day you go check effective permissions for a User they show up but the very next day they don't .

Here is what is happening in the background …

When we perform the check permissions, we call the spite constructor with the user token we have for the desired permission check. Certain information is passed through by the Identity provider (like group memberships) and only exists on the SharePoint side in the token.

This token will not contain the group membership if either the user is not in the userinfo table --- ( Hasn't logged in Yet to the site )


if the ExternalToken stored by SharePoint is expired or incomplete (does not contain group membership). The only way to rebuild the token is by sending the user on a round trip to ADFS to re-authenticate

So interestingly, if the user has signed in Recently enough , then there will be an existing token which can be used for performing the check, otherwise it returns that there are no permissions..

Following interesting observations come out of this explanation

Scenario1 : New User : You Create a new User in AD & add to required AD group which has been added to SharePoint group & go check his permissions .

Observation: Check Permissions fails till the user logs on to the site & once logged in then continues to work for that day.

Scenario 2 : Modified Group Membership : Added or Removed a User from a Group to Provide /Remove additional permissions

Observations: Actual Permissions or Access works as Expected , but Check Permissions does not show updated Membership till about a day ( 24 hrs from last logon) & Shows updated Permissions only when user logs in the next day as token gets refreshed .

Scenario 3 : No changes : If the user shows Required permission on the Site as Seen by check permission today , Trying again tomorrow it may show "None" again .

Observation: This user does not log in for couple of days , Check Permissions with show "None" till he logs back in,,

Note : This Issue does not occur with Windows Classic , Windows Claims or Forms Mode Authentication for the Web-application . This is same for SharePoint 2010 & 2013 .


POST BY :Rajan Kapoor [MSFT]

Speaking at Live! 360 Orlando

MSDN Blogs - Sat, 07/04/2015 - 18:41
I’ll be speaking at Live! 360 Orlando, November 16-20. Surrounded by your fellow industry professionals, Live! 360 provides you with immediately usable training and education that will keep you relevant in the workforce. I’ll be presenting the following sessions: Windows 10 Deployment with Config Man OSD - Planning and Strategy Workshop: Application Deployment - The Configuration Manager Way SPECIAL OFFER: As a speaker, I can extend $600 savings on the 5-day package...(read more)

Certificates not visible in Server Certificates console of IIS 7/IIS 8 Manager

MSDN Blogs - Sat, 07/04/2015 - 10:29

You are planning to deploy SSL certificate for your website. You go ahead and get the required certificates from the Certificate Authority (CA) and install it in the Local Machine store via Certificate Manager.

Next, you go to Server Certificate feature to check for the installed certificate before you can bind the certificate with the website.

But the Certificate you just installed is not showing in the console, its missing! What do you do?

You verify the certificate is valid by checking the following -

  1. That the current date and time is within the "Valid from" and "Valid to" date range on the certificate.
  2. That the certificate's "Common Name" (CN) matches the host header in the request. For example, if the client is making a request to, then the CN must also be
  3. That the issuer of the certificate is a known and trusted CA

All the above conditions are true but still the certificate is not showing up.

It happens that the Server Certificates module in IIS manager displays a list of certificates from the Local Machine SSL store. But it only lists the certificate if - 

1. The certificate has a private key

2. The certificate is meant for Server Authentication

In my case I found that the private key was missing in the certificate.

We can recover the private key by following the below steps –

To recover the private key on the certificate, we need to repair the certificate using the following command –

certutil –repairstore my <serial number>

where serial number can be obtained by looking up the certificate properties as indicated below.

Once the certificate was repaired, we were able to get back the private key.

If the above commands completes successfully but does not work to get back the private key then you may have to recreate the certificate.

Once my private key was retrieved, the Server Certificates console starting showing up the certificate as well.


Certutil -

Disclaimer: The information in this weblog is provided "AS IS" with no warranties, and confers no rights. This weblog does not represent the thoughts, intentions, plans or strategies of my employer. It is solely my opinion. Inappropriate comments will be deleted at the author’s discretion. All code samples are provided "AS IS" without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular.

修改域密码后对Windows Azure Pack 的影响和解决办法(虚拟机云)

MSDN Blogs - Sat, 07/04/2015 - 00:02

在Windows Azure Pack (后简称WAP)的实际使用场景中我们无法避免的会遇到各种密码到期需要更改的情况。而在WAP的环境中又有许多的组件都依赖于域密码,那么究竟改动一次密码后会有多大影响我们来做一个测试。


在我的测试环境中我使用BC-TEST\WAPadmin作为所有组件的管理员密码(包括:Admin Site ; SCVMM ; SPF ; Automation;SQL)

在确保Windows Azure Pack 当前运行状态正常的前提下,我将WAPadmin的密码更改.(如下图)

之后我再次登录和检查了WAP admin site , SCVMM admin Console ,SQL server都可以正常登录和使用,由此可见大部分的组件是支持和DC同步密码的。

而问题主要出现在Automation(自动化) 组件上有报错。(如下图)尝试在Admin Site直接更改Automation信息时会发现:Automation 组件无法选择而通过VM 云进入的Automation 注册界面为灰色无法更改。



我们需要强制移除当前SMA(Service Management Automation)的信息,并再将它重新注册到Admin Site 内。

参照博客 我们可以在WAP服务器运行下列几步Power Shell 命令来解决这个问题:


1.    $Credential = Get-Credential   (输入后会弹出需要输入当前管理员帐号密码的需求,如下图)

2. $Token = Get-MgmtSvcToken -Type Windows -AuthenticationSite https://请输入当前WAP portal 的地址:30072 -ClientRealm http://azureservices/AdminSite -User $Credential -DisableCertificateValidation   

    Get-MgmtSvcResourceProvider -AdminUri "https://localhost:30004"-Token $Token -DisableCertificateValidation -name "Automation"  

     命令执行成功后请记录下图中的Instance ID 用于下一条命令

3. Remove-MgmtSvcResourceProvider -AdminUri "https://localhost:30004" -Token $Token -DisableCertificateValidation -Name "Automation" -InstanceId "将上条命令中得到的Instance ID 填入此"

   命令成功执行后按照提示(如下图)选择 Y 之后即可成功移除SMA组件

之后我们回到WAP的 Admin Site 检查状态,可以看到Automation的红色惊叹号报错已经消失,并出现了可以注册新的SMA终结点的选项。


5. 重新注册并输入新的密码之后故障排除。








Visual Studio 2015 讓 JavaScript 編輯器更威了!

MSDN Blogs - Fri, 07/03/2015 - 21:06

想要在多種不同的平台上進行開發,像是 web、mobile app 和伺服器程式設計,JavaScript 可以說是相當重要的技術。在 Visual Studio 2013 上,我們已經支援 IntelliSense、查看定義、語法上色和 JavaScript 程式碼的格式化以及其他功能。這些功能我們都將帶到 Visual Studio 2015 上,另外,為了讓 JavaScript 開發人員可以有更好的開發體驗,我們針對以下三大關鍵領域做了強化:

  1. 在使用 JavaScript 函式庫時可以有更好的開發體驗
  2. 添加對新 JavaScript ECMAScript 2015 (也被稱為 ES2015 和以前的 ES6) 語言和 web 瀏覽器的 API 支援
  3. 在複雜的 JavaScript 程式碼中提高您的生產力

之所以會選擇上述三大方向,是因為我們統整了 UserVoice在 Visual Studio 中的發送笑臉 / 哭臉功能、社群網站及一些面對面的開發者大會上得到的資訊,進而決定出來的。

在這篇文章中,我們將介紹 JavaScript 編輯器於上述三大關鍵領域上的新特點,而您可以在所有 Visual Studio 支援的 JavaScript 專案上進一步試試看這些新功能。

對 JavaScript 函式庫的支援 AngularJS 1.x 和 RequireJS 的支援

在預設情況下,Visual Studio 2015 支援現在非常流行的 AngularJSRequireJS 函式庫。在之前的文章中我們曾討論過在 Visual Studio 2013 中使用這兩個函式庫的設定需求 (在 VS 中使用 AngularJS在 VS 中使用 RequireJS)。在 Visual Studio 2015 中,這些都是內建的,無需再進行任何額外安裝。

每當您在程式碼中引用的 angular.js (或 angular.min.js) 函式庫,編輯器會自動提供 IntelliSense、查看定義和導覽等功能的支援:

上圖顯示 IntelliSense 對 Angular 1.3 的支援,在這裡了秀出對 routeProvider 服務的建議選項

同樣地,當您使用 require.js 函式庫,RequireJS IntelliSense 和導覽等功能會自動開啟,若要自訂 RequireJS 支援,請參閱 於 RequireJS 中自訂 IntelliSense一文。

上圖顯示使用 RequireJS 時會提供給模組的 IntelliSense 建議選項

JSDoc 文件註解

文件註解可於您的應用程式內提供 API 細節,可以說是一個很了不起的工具。更重要的是,它幫助你在撰寫程式碼時,讓 Visual Studio 可以提供更好的 IntelliSense 建議。在 Visual Studio 2015 中,編輯器將可以理解 JSDoc 樣式的文件註解,並可使用它們來提升您的的程式體驗。JSDoc 已成為 JavaScript 非官方的標準,被用於像是 AngularEmber 這樣的函式庫中。以下是一個簡單的例子,將說明如何使用這些註解,並顯示 IntelliSense 提示工具對 getPhotos() 函式的支援。

上圖為 IntelliSense 提示工具中所顯示的 JSDoc 註解

當你引用註解中的參數類型 (如陣列),您可以使用標準內建的 JavaScript 類型和物件,像是字串、 數字或陣列。您還可以定定義出一個自訂物件,這對記錄參數的自訂屬性 (如配置設定) 來說相當實用。在下面的範例中,您可以看到使用 savePhoto() 函式時,提供給 options 這個物件的建議。

上圖顯示如何使用 JSDoc 來記錄設置物件

除了 JSDoc 註解, Visual Studio 2013 版中的 XML 樣式文件註解 也會繼續提供支援。編輯器對 JSDoc 標籤支援的完整清單可以在 MSDN 上找到。


隨著語言標準和 Web API 的進化,JavaScript 編輯器也會更新,在此版本中我們將介紹對於 ES2015 標準(原名 ES6) 和一組組新的 DOM API,所提供的新語言功能支援。這些更新都將對應到我們最近宣布的 Microsoft Edge 瀏覽器

ECMAScript 2015 (原名 ECMAScript 6) 的支援

如同 Microsoft Edge 瀏覽器,現在將支援一整組的 ES2015 功能,Visual Studio 2015 JavaScript 編輯器會支援 ES2015Specifically 和以下項目:


上圖顯示 ES2015 中新的語言功能

注意上圖中 LayoutManager> 類別使用了 class 這個關鍵字,而在 message 變數中使用了範本字串的功能,還有在 addEventListener API 中使用了箭頭(=>)來定義 callback 函式。如果想要瞭解更多詳情,可以參閱由 Eric Douglas 所整理公開在 GitHub 上的 ES6 Learning,或是檢閱 ES2015 version of JavaScript 規格書

你可能已經注意到一些 ES2015 功能還沒被支援,例如模組。我們了解支援最新的 ES2015 語言功能是相當重要的,所以我們將儘快支援完整的 ES2015。

新網頁瀏覽器 API 的 IntelliSense

Visual Studio 2015 將於 Microsoft Edge 中提供新網頁瀏覽器 API IntelliSense 支援。下面是幾個 API 亮點:

您可以看到在 http://status.modern.ie於預覽版中釋出的可用 API中看到完整清單。

在複雜的 JavaScript 程式碼中工作

最後,我們從開發人員中聽到了一個狀況,在複雜的 JavaScript 原始程式碼中,有時會很容易迷路。我們已添加了兩個編輯器功能,來幫助您在 JavaScript 原始程式碼中挖掘出重要的註解和 API,如此一來您將可以更輕鬆地進行程式設計。


您可以使用 Visual Studio 工作清單來持續追蹤 // TODO,// HACK,// UNDONE,或您程式碼中的自訂註解標記。這將有助於您偵測出程式碼中的技術問題。

上圖顯示使用工作清單來查看 JavaScript 原始程式碼中的 TODO 和 HACK 註解


導覽列對於 JavaScript 開發人員來說,是很常被使用的功能,因為它可以幫助您快速跳到您常使用的地方,大大減少肉眼審視原始檔案的時間。

在下面的範例中,您可以看到編輯器是如何理解 ECMAScript 5 原始程式碼:

上圖顯示使用 ES5 編寫時,使用導覽列來瀏覽 JavaScript 原始程式碼

另外一個例子,您可以看到導覽列支援新的 ES2015 物件類別關鍵字 (從而大大簡化了上個範例中的程式碼):

上圖顯示使用 ES5 編寫時,使用導覽列來瀏覽 JavaScript 原始程式碼


除了上述強調的功能,像是各種 bug 修復、性能強化和其他更新,都將給予您一個頂級的 JavaScript 編輯器使用經驗。展望未來,我們將繼續擴展編輯器的可能性,進而構建大規模的 JavaScript 解決方案。

我們也知道對您來說,擁有一個支援最新 JavaScript 語言的編輯器,是多麼重要的事,像是 ES2015 modules 和 generators,我們正努力讓 Visual Studio 可以完美支援它們。

想要嘗試這些功能,今天就下載 Visual Studio 2015 。如果你是 Open Source 開發人員、學生、業餘愛好者,或在一個小的專業團隊中工作,在此推薦您免費的 Visual Studio 2015 Community 版本。也請透過發送一個笑臉或哭臉來告訴我們您的 JavaScript 編輯器使用體驗。

本文翻譯自 JavaScript Editor Improvements in Visual Studio 2015

Connect Cloudera to Azure ML Hive Reader

MSDN Blogs - Fri, 07/03/2015 - 18:33

Azure Machine Learning supports Hive as a data source using WebHCat API.  In this post, I will show you how to configure Cloudera to connect to Azure ML through WebHCat.  These steps have been verified on a Cloudera cluster created from Azure Marketplace.  If you don't already have a cluster, you can follow this blog post to deploy one.  We will use Cloudera Manager to configure the cluster.     

Step 1: Enable WebHCat 

By default, Cloudera cluster created from Azure Marketplace doesn't have WebHCat enabled.  To enable it, go to Cloudera Manager, select Hive, and Add Role Instances:

 You can see WebHCat server doesn't have a host, so click Select Hosts:


Follow the wizard to select a host, and start the WebHCat server.  

Step 2: Expose WebHCat Endpoint

In order to run Hive queries, we need to configure the Azure VM endpoint to expose WebHCat.  To do this, login to the Azure Portal, select the VM that's running WebHCat server, then go to the ENDPOINTS tab to add an endpoint.  By default, WebHCat runs on 50111.  You can choose a public port that's different from the private port.  But for simplicity, we will keep them same here:

Now we can run DDL commands using WebHCat.  For example, to list Hive databases, run:


To list tables in the default database, run:


However, we are not able to run Hive queries yet.  This is because the default WebHCat configuration includes jars that are not in the Cloudera cluster environment, and Hive meta store URIs need to be updated.   

Step 3: Configure WebHCat

To update WebHCat configuration, go to Cloudera Manager, select Hive, Configuration, and type "webhcat" in the Search box to narrow down the configuration.  Update "WebHCat Server Advanced Configuration Snippet (Safety Valve) for webhcat-site.xml" section as following: 

The configuration should include the following.  Note that the settings here correspond to the Cloudera environment deployed by Azure Marketplace, if you are using a different cluster, you might need to adjust the settings to match your cluster.

    <description>Jars to add to the classpath.</description>
    <description>The path to the Hive executable.</description>
    <description>Properties to set when running hive.</description>

After the configuration is updated, restart WebHCat server for the update to take effect.  Now, we should be able to run Hive queries via WebHCat. For example, to select all rows from table "example1" in the default database, run:

curl -s -d -d execute="select+*+from+default.example1;" 'http://<webhcatserver>'

WebHCat writes its job output to /templeton-hadoop, so Hive user must have access to this hdfs folder.  You can go to Hadoop UI or Hue to view the job status. 

Step 4: Connect to Azure ML

Log in to Azure ML Studio, click on your Reader module, and select "Hive Query".  Configure Hive as following with your own WebHCat server URL, HDFS user, and HDFS Server URL:

Run the experiment, and verify that the result of the job is written to /user/hive/warehouse/ in HDFS:

Azure ML also logs job status to /DataLabReaderStore:

Updates to ASP.NET 5 yeoman generators for beta 5

MSDN Blogs - Fri, 07/03/2015 - 16:39

Hi everyone the blog post below is written by Peter Blazejewicz, who is a core contributor to the yeoman generators for ASP.NET 5. Peter took care of the majority of the updates for beta 5. I hope you enjoy, please leave your thoughts below in the comments.

Hi folks!

This week marks the release of ASP.NET 5 Beta5 and the related update to Yeoman generator for ASP.NET 5! There are many new things that are introduced to ASP.NET 5 generator with this update, both to client and server side. Here is the list of the most important additions:

  • New simple Web MVC application project template (without Membership and Authorization)
  • AngularJS 1.* templates
  • React template
  • TypeScript templates updates
  • CSS/Less/SCSS templates
  • Interface, Middleware, TagHelper templates

Nearly all existing templates have been updated, rewritten and revised during beta5 development. We have also expanded tests to cover nearly all content generation by generator too!.

Here's an animated gif showing yo aspnet in action on Mac OSX.

There are also changes in how templates are organized within the project, we use the same files structure now both in template content and in generated content, we unified files and subgenerators names and character-case. There is a simple pattern used during subgenerator implementation, which we hope will be easy to follow. As we changed templates organization, the futures changes and upgrades are expected to be easier to add and develop.

We hope this will ease contribution to the project - and we have already received PRs after beta5 update <3!

If you want to shape future of ASP.NET with us, help us by submitting issue or just discussing a topic and adding your own contribution to the project.

In case you missed them we have blogged on the ASP.NET 5 yo generators in the past.

Peter Blazejewicz

Freakonomics by Steven Levitt and Stephen Dubner

MSDN Blogs - Fri, 07/03/2015 - 15:46

This post originally appeared on my old blog, dirtyDogStink, which has since been removed. I'm adding it here for reference purposes.


Freakonomics by Steven Levitt and Stephen Dubner

I could not believe how fast this book read. I started it last Thursday and finished it Saturday afternoon. Especially for a book on economics...I am completely astounded at how easy this was to read and comprehend. The authors have a great knack for taking the complicated and translating it into layman's terms that make sense and deliver their points succinctly. Economics is not the sexiest topic nor is it the easiest to comprehend, but the two Steves actually made it interesting and thought provoking.

Just look at these chapter titles, does this sound like an economics book?

  1. What Do Schoolteachers and Sumo Wrestlers Have in Common?
  2. How is the Ku Klux Klan Like a Group of Real-Estate Agents?
  3. Why Do Drug Dealers Still Live with Their Moms?
  4. Where Have All the Ciminals Gone?
  5. What Makes a Perfect Parent?
  6. Perfect Parenting, Part II; or: Would a Roshanda by Any Other Name Smell as Sweet?


Here are some interesting pieces of information taken from the book:

  • "There are enough guns in the United States that if you gave one to every adult, you would run out of adults before you ran out of guns. Nearly two-thirds of U.S. homicides involve a gun, a far greater fraction than in other industrialized countries. Our homicide rate is also much higher than in those countries....In Switzerland, every adult male is issued an assault rifle for militia duty and is allowed to keep the gun at home. On a per capita basis, Switzerland has more firearms than just about any other country, and yet it is one of the safest places in the world. In other words, guns do not cause crime."
  • "Cheating is a primordial economic act: getting more for less....Consider what happened one spring evening at midnight in 1987: seven million American children suddenly disappeared....It was the night of April15, and the Internal Revenue Service had just changed a rule. Instead of merely listing each dependent child, tax filers were now required to provide a Social Security number for each child. Suddenly, seven million children...vanished, representing about one in ten of all dependent children in the United States."
  • "Had the Internet been around when Kennedy infiltrated the Klan, he probably would have rushed home after each meeting and blogged his brains out." This one made me laugh-out-loud. 
  • "If you were to assume that many experts use their information to your detriment, you'd be right. Experts depend on the fact that you don't have the information they do. Or that you are so befuddled by the complexity of their operation that you wouldn't know what to do with the information if you had it. Or that you are so in awe of their expertise that you wouldn't dare challenge them."
  • "Listed below are ten terms commonly used in real-estate ads. Five of them have strong positive correlation to the ultimate sales price, and five have a strong negative correlation....Higher Sales Price: Granite, State-of-the-Art, Corian, Maple, Gourmet.... Lower Sales Price: Fantastic, Spacious, !, Charming, Great Neighborhood....
  • "Consider the parents of an eight-year-old girl named, say, Molly. Her two best friends, Amy and Imani, each live nearby. Molly's parents know that Amy's parents keep a gun in their house, so they have forbidden Molly to play there. Instead, Molly spends a lot of time at Imani's house, which has a swimming pool in the backyard. Molly's parents feel good about having made such a smart choice to protect their daughter....The likelihood of death by pool (1 in 11,000) versus death by gun (1 in 1 million-plus) isn't even close: Molly is roughly 100 times more likely to die in a swimming accident at Imani's house than in gunplay at Amy's."
  • "Compare the four hundred lives that a few swimming pool precautions might save to the number of lives saved by far noisier crusades: child-resistant packaging (an estimated fifty lives a year), flame-retardant pajamas (ten lives), keeping children away from airbags in cars (fewer than five young children a year have been killed by airbags since their introduction), and safety drawstrings on children's clothing (two lives)."
  • "Fryer cites the recollections of a young Kareem Abdul-Jabbar, known then as Lew Alcindor, who had just entered the fourth grade in a new school and discovered that he was a better reader than even the seventh graders: 'When the kids found this out, I became a target....It was my first time away from home, my first experience in an all-black situation, and I found myself being punished for everything I'd ever been taught was right. I got all A's and was hated for it; I spoke correctly and was called a punk. I had to learn a new language simply to be able to deal with the threats. I had good manners and was a good little boy and paid for it with my hide.'" This is taken out of a section discussing the black-white income and education gaps and I simply found Kareem's experience with discrimination interesting.
  • "...a child with many books in his home has indeed been found to do well on school tests. But regularly reading to a child doesn't affect test scores." I found this particularly interesting and his explanation is way too long to put go read it. 

This quote sums up the book nicely: "What this book is about is stripping a layer or two from the surface of modern life and seeing what is happening underneath."

Update: I forgot to add that the authors have a blog [and it is posted to regularly] at


Getting Things Done by David Allen

MSDN Blogs - Fri, 07/03/2015 - 15:40

This post originally appeared on my old blog, dirtyDogStink, which has since been removed. I'm adding it here for reference purposes.



Getting Things Done: The Art of Stress-Free Productivity by David Allen

A month or more ago I attended a day-long class about improving my productivity through organizing my tasks and information in Outlook.  In fact, I discuss getting my email organized with the 4 Ds using the techniques from the class. I'm really digging it. I decided to take the class a few steps further and see what else I can do in my life to get more organized so I went to our group's organizational expert [hi Ed!] for some advice. He pointed me in the direction of David Allen so I picked up Getting Things Done and started reading. 

I liked it and found a lot of value. Honestly, it was another pretty easy read. I didn't do too many of [read that as 'none of'] the exercises in the book and was able to finish it in less than a week. I figured with my first read through I would just try to digest the overall concepts and then see where/how I could fit them into my life. It helped solidify several of the concepts I pulled out of the day-long class.

As is my custom, here are some specific areas that I found interesting and helpful:

  • Allen bases his methodology on two key objectives:
    • "capturing all the things that need to get done -- now, later, someday, big, little, or in between -- into a logical and trusted system outside of your head and off your mind"
    • "disciplining yourself to make front-end decisions about all of the 'inputs' you let into your life so that you'll always have a plan for 'next actions' that you can implement or renegotiate at any moment"
    • Both of these objectives really rang true for me. I have always been organized, but with a bad habit of procrastinating with my decisions. Forcing myself to make decisions up front [like applying the 4 Ds when processing email] has been a tremendously positive change.
  • "if it's on your mind, your mind isn't clear." Allen discusses a zen-like approach to clarity of thought and how it leads to drastic advances in our thought processes. The gist of it is that if your mind is freed from having to keep track of grocery lists, project to-dos, meeting reminders, etc. then you can let it work on the bigger issues in your life like how to design a new product or what it really might take for you to go on that dream vacation to Europe. If you write it down (physically or electronically) and store it somewhere you trust, the mental benefits/gains are exponential.
  • "The big difference between what I do and what others do is that I capture and organize 100 percent of my 'stuff' in and with objective tools at  hand, not in my mind. And that applies to everything -- little or big, personal or professional, urgent or not. Everything." - I have started doing this using Outlook tasks and it really is refreshing to know that I have one place to go whenever I need to look up notes, lists or next-actions. It takes a certain amount of discipline to capture everything, as David does, but it really is liberating after awhile.
  • "What's the Next Action? ... The 'next action' is the next physical, visible activity that needs to be engaged in, in order to move the current reality toward completion." - This is often an elusive thing when dealing with projects or even worse, multiple projects at the same time. Simplifying a project down to the single next action that needs to take place in order to move forward can provide clear direction...not only for yourself, but others you are working with. I see way too many project meetings that end without any clear action items and these are the projects that inevitably stall and then fizzle into nothing. Months later you find yourself asking someone 'whatever happened to project X?' Ugh.
  • The Natural Planning Model -
    1. Defining purpose and principles
    2. Outcome visioning
    3. Brainstorming
    4. Organizing
    5. Identifying next actions
    • I see so many projects that exclude, ignore or forget one or more of these pieces and they always seem so unorganized. In fact, just a few weeks ago I was in a 3 hour meeting that included loads of brainstorming.  Early in the meeting I became confused [I am a late-comer to the project] and asked for # 1 or 2 above to give me some clarity. I got blank stares in return. D'oh! How can we effectively brainstorm a design or concept if we don't even know what the purpose and vision are?
  • Don't be afraid to ask why. Why are we meeting? Why am I in this meeting? Why are we trying to accomplish this? Why do the requestors think they need this solution? Yada-yada-yada... Here are Allen's listed benefits of asking "why?" and I couldn't agree more:
    • It defines success.
    • It creates decision-making criteria.
    • It aligns resources.
    • It motivates.
    • It clarifies focus.
    • It expands options.
  • Mind-mapping as a brainstorming exercise. This looks pretty interesting.
  • Filing systems: "the lack of a good general-reference system can be one of the greatest obstacles to implementing a personal management system, and for more of the executives I have personally coached, it represents one of the biggest opportunities for improvement." - I'm a pack-rat when it comes to documents and such. I had a huge file cabinet full of stuff going back 20+ years. A lot of it was irrelevant, but more importantly it was filed very inefficiently. The system only made sense to me and was cumbersome. In a nutshell, Allen recommends making your filing system as simple as possible. Start with a simple set of folders labeled A-Z and only make specific-labeled folders for those things you need. So I spent a weekend purging my files and re-organizing them. Not only was I able to shred 65% of the files, but I simplified the system so that everything is easy to find. Bills are under B instead of a separate folder for each company, house information is in H, medical stuff is under M, etc. That was a big monkey off my back. 
  • Organizing action reminders - I'm still working this one out to find a way that works well for me, but Allen gives a lot of good suggestions. Basically, if something needs to be done on a certain date/time then put it on your calendar. Other next actions should be organized by context, whatever context makes the most sense to you (phone calls, errands, office, read/review, at computer, etc.).
  • Weekly review - Probably one of the most important aspects to implementing Allen's system! Once you start collecting all of your thoughts/ideas/actions in a trusted place you need to review them regularly so they're not missed. The weekly review is one such point-in-time where you spend a few hours organizing the loose things (email, papers, notes, lists, etc.), reviewing your next actions, clearing your mind and double-checking yourself. Here are the things that Allen suggests for a weekly review:
    • Process all loose papers.
    • Process your notes from journal entries, meetings or scribbled reminders.
    • Review past calendar dates for remaining action items, reference information, etc.
    • Look at future calendar events for any prep work you might need to do.
    • Clear your mind by writing down all of your project ideas, action items, etc.
    • Evaluate your projects for status and any action items.
    • Review your lists (next actions, waiting for, someday/maybe) for any items that can be marked as finished or needs to be updated.
  • "Your negative feelings are simply the result of breaking those agreements." Allen is referring to our agreements with ourselves when we have something in our 'inbox' or tell ourselves we will do something, but then we don't complete it. "If you tell yourself to draft a strategic plan, when you don't do it, you'll feel bad. Tell yourself to get organized, and if you fail to, welcome to guilt and frustration." We are our own worst critic, right?

Interesting quotes from the book:

  • It is hard to fight an enemy who has outposts in your head. - Sally Kempton
  • It does not take much strength to do things, but it requires a great deal of strength to decide what to do. - Elbert Hubbard
  • Fanaticism consists of redoubling your efforts when you have forgotten your aim. - George Santayana
  • The best way to get a good idea is to get lots of ideas. - Linus Pauling
  • If you're not totally sure what your job is, it will always feel overwhelming. - David Allen
  • Let our advance worrying become advance thinking and planning. - Winston Churchill
  • People are always blaming their circumstances for what they are. I don't believe in circumstances. The people who get on in this world are the people who get up and look for the circumstances they want, and, if they can't find them, make them. - George Bernard Shaw

The thing I really liked about this book, besides all of the organizational tips/suggestions, is that Allen's basic premise is that you should find a system that works best for you. The same system will not work for everyone and he states that frequently. He suggests you use his processes, but also realizes that you might want to take a hybrid approach [what I have done] and is ok with that. He writes the book with an open mind which, in my opinion, makes him even more credible.


Don't Make Me Think by Steve Krug

MSDN Blogs - Fri, 07/03/2015 - 15:28

This post originally appeared on my old blog, dirtyDogStink, which has since been removed. I'm adding it here for reference purposes.



Don't Make Me Think: A Common Sense Approach to Web Usability by Steve Krug

I especially like this book because it is exactly what it claims to be: a relatively short, easy to read book about web usability. In fact, the author explicitly states that he "worked hard to keep this book short - hopefully short enough you can read it on a long plane ride." Being a very busy person at work and home I really, really appreciate this!

I highly recommend this book for: anyone who is the slightest bit involved in developing or designing a web site's user interface...period. The reason I say this is because:

  • it's a great starting point for someone who has no experience with web site usability.
  • it seems like a great [and quick] refresher for anyone who does have usability experience.
  • it's an interesting read because the author's character really comes through [versus being dry and boring].
  • it really is short enough for a long plane ride or a few nights 'bedtime reading.'

A few highlights of things I learned and/or appreciated:

  • First and foremost, don't make your users think! For example, descriptions [for categories, products, lists, etc.] should be clear and concise.
  • Users really don't read web pages, they just scan them for keywords.
  • Users satisfice when selecting where to go next on any given page. This basically means we tend to choose the first reasonable option instead of examining all of them before selecting one. And yes, I realized that I do this. 
  • Following conventions is a good thing. Forget about reinventing the wheel and just use techniques and design patterns that people are already comfortable with.
  • Keep the visual noise to a minimum [don't try to cram in everything and the kitchen sink].
  • Omit needless words. Get rid of half of the words on every single page. When you're done with it again. It may sound harsh, but it's true.
  • The "You Are Here" theory. Make it blatantly obvious where you are in the site structure at all times [using page titles, highlighting, home link, tabs, etc.].
  • Always have a search box...unless your site is a single static .htm page. 
  • Keep the home page simple! Remember, it's purpose is simply to get across the big picture.
  • Usability testing doesn't have to be hard, in fact, it can be down right simple. Just grab your neighbor for 15 minutes.
  • Usability tests...small scope frequent testing is better than a single (or few) large scope test(s).
  • "The Reservoir of Goodwill" - Don't use it all up and try to refill it when you do use some!
  • Last, but certainly not least. Always keep accessibility in mind when designing. Steve is referring to Section 508 of the 1988 Amendments to the Rehabilitation Act, which specifies accessibility standards for information technology (like web sites).

Check out Steve's website,, for more information about him and his book(s).


The Mythical Man-Month by Frederick P. Brooks, Jr.

MSDN Blogs - Fri, 07/03/2015 - 15:23

This post originally appeared on my old blog, dirtyDogStink, which has since been removed. I'm adding it here for reference purposes.



The Mythical Man-Month by Frederick P. Brooks, Jr.

Originally written in 1975 and then revised in 1995, I think this book truly withstands the test of time for the field of software development. It isn't full of checklists and to-dos that are guaranteed to make your projects work [no snake-oil here], but rather wisdom from an experienced software project manager. Several of the chapters are actually stand-alone essays and this book simply collates them in a logical manner. Most of the information is easy to read and moves pretty quickly, in fact, I actually finished it in about 10 days. As a busy person with several personal/professional interests and responsibilities, that means a lot to me because then I actually read the book instead of letting it drag out for months without ever finishing it.

Your first reaction might be "the book is 30 years old, what could possibly be relevant towards today's technologies?" You're right to be curious about that, as was I, since technology has made so many changes in the past 30 years. The wonderful thing about this book is that even in the initial publication the author recognizes the extreme rate at which technology advances and addresses it constantly. For the most part, Brooks speaks to technology as an idea/concept instead of talking directly to this or that programming language. That perspective allows the conversations to transcend most technological limitations that would have been present had he addressed explicit hardware or software technologies.

Although the title is The Mythical Man-Month, Brooks delves into several aspects of software development and highlights the challenges we face on a daily basis. As is my normal process, here are several points from the book that I found interesting:

  • Using the concept of a man-month [I suppose person-month would be the PC way of saying this] as a unit of estimating time to complete a project is really a fallacy. It is often assumed that men and months are "interchangeable commodities," but that only holds true if "a task can be partitioned among many workers with no communication among them." Adding more developers to a project will not result in it being completed sooner, in fact, most of the time it will increase the time due to the added complexities of communication.
  • Time estimation is the Achilles heel of software development projects [my words, not Brooks'] because "our techniques of estimating are poorly developed" and "fallaciously confuse effort with progress." Based on my 1-1/2 years of limited experience this still holds true today.
  • The surgical team concept as proposed by Harlan Mills - Each programming team should consist of a surgeon, copilot, administrator, editor, two secretaries, program clerk, toolsmith, tester and language lawyer. Some of the role responsibilities are obvious by their name, while the others are defined in the book. Suffice it to say that I equate this to the current process of agile programming with small teams.
  • "The Second-System Effect" - "As he designs the first work, frill after frill and embellishment after embellishment occur to him. These get stored away to be used 'next time.' ...This second is the most dangerous system a man ever designs....The general tendency is to over-design the second system....the a 'big pile.'"
  • In the chapter, Why Did The Tower of Babel Fail?, Brooks states that lack of communication and the subsequent lack of organization are the culprits. He applies this theory to programming projects and how the increase of workers will drastically increase the likelihood of miscommunication, hence failure. Oh so true in my experience.
  • Catastrophic failures can be avoided by reducing a boss' role conflict. They must "distinguish between action information and status information. He must discipline himself not to act on problems his managers can solve, and never to act on problems when he is explicitly reviewing status." If front-line managers know their manager will not over react during status reports then they are much more likely to be honest in those status reports. Top-level management needs to trust their line managers to resolve conflicts and react only when asked to do so or when they absolutely have to.
  • One of the most interesting ideas presented [No Silver Bullet chapter] was that high-level languages (such as .NET and Java today) would not be a large breakthrough in the software development field. Brooks hypothesizes that "at some point the elaboration of a high-level language becomes a burden that increases, not reduces, the intellectual task of the user who rarely uses the esoteric constructs." I see his point, but I must disagree to an extent. While high-level languages obfuscate several fundamental concepts in software development they have broken down some of the traditional barriers by allowing non-CS graduates [like myself] to enter the field and be successful. I don't have a background in C or C++, but I am learning how to be a good developer through the massive resources available to me. Regardless of that, I was able to jump in and be productive within a very short time using .NET because I am a quick study and didn't have to learn memory management or object oriented programming first. Just to be clear, that first application I wrote looks un-Godly awful according to my standards today, but my point is that I was able to do it...not how well it was done.

I highly recommend this book for both software developers and project managers. Actually, I would like everyone involved in software development (developers, program managers, architects, testers, people managers, etc.) to read this book!




Friday Five on Windows

MSDN Blogs - Fri, 07/03/2015 - 12:45

Go into your weekend with these five tips on Windows from MVPs:

Windows Platform Development MVP – Brian Lagunas @brianlagunas
First Look at the Prism for Xamarin Forms

Windows Embedded MVP – Ken Marlin @WindowsChamp
It’s Time for Windows 10 IOT

Windows Platform Development MVP – Karthikeyan Anbarasan @f5Debug
Steps to Send Emails from Windows Store App for Developers

Windows Platform Development MVP – Michael Crump @mbcrump
5 Steps to an Ideal Windows 10 App Development Environment

Windows Platform Development MVP – Amr Khamise @amrKhamise
Build a Windows Universal App that Targets Windows 8.1 Devices

Part1: Introduction to N-Tier Modern Web Application

MSDN Blogs - Fri, 07/03/2015 - 12:35

We are living in the era of modern applications development where customer needs are changing all the time, I’ll be writing this blog Set to give the Developers who are struggling to build a modern, enterprise ready, that can scale based on customer needs. The Number of Technologies around us are too many and changing rapidly. So I’ll try to give everyone a startup architecture and design that they can use it to design and implement their solution as quickly as possible

Let’s Start this thread a start and think about what are the tools and Ideas We will be using to get this up and running.

We will be running our Solution on 2 Major Points, The Backend Planning and the Technology of Choice will be webAPIs on top of DBaaS and ASP.NET. The Front end will be JQuery Application and Will dicuss this in details after understanding what are we these 2 technologies provide us.

Back end Planning and What is Web APIs Web API Features
  1. It supports convention-based CRUD Actions since it works with HTTP verbs GET,POST,PUT and DELETE.
  2. Responses have an Accept header and HTTP status code.
  3. Responses are formatted by Web API’s MediaTypeFormatter into JSON, XML or whatever format you want to add as a MediaTypeFormatter.
  4. It may accepts and generates the content which may not be object oriented like images, PDF files etc.
  5. It has automatic support for OData. Hence by placing the new [Queryable] attribute on a controller method that returns IQueryable, clients can use the method for OData query composition.
  6. It also supports the MVC features such as routing, controllers, action results, filter, model binders, IOC container or dependency injection that makes it more simple and robust.
Why to choose Web API ?
  1. If we need a Web Service and don’t need SOAP, then ASP.Net Web API is best choice.

  2. It is Used to build simple, non-SOAP-based HTTP Services on top of existing WCF message pipeline.

  3. Its Readable and Browser friendly it returns a string at the end of the day and how you want to format this string it’s all about your design needs

  4. It doesn't have tedious and extensive configuration like WCF REST service.

  5. Simple service creation with Web API. With WCF REST Services, service creation is difficult.

  6. It is only based on HTTP and easy to define, expose and consume in a REST-ful way.

  7. It is light weight architecture and good for devices which have limited bandwidth like smart phones.

  8. It is open source.


With that said our Backend will be designed on top of SQL and Web APIs N-Tier Architecture we will discuss this in details later on this blog.


Modern Web Apps

What is the Definition of a Modern web app this is a good question that comes to every developer mind when we think about their application is it a modern web app or no? The Answer is in the next few lines


Characteristics of Modern Web Applications

While there are many types of modern web applications, addressing many different needs, they all have some characteristics in common.

  • They are standards-focused. To have the broadest reach across multiple platforms and devices, applications attempt to implement the current and evolving standards and adopt future standards once ratified.
  • They are interactive. Modern web applications keep the user engaged by providing constant feedback on their actions. This feedback can come in the form of messages, animations to hide or show elements, mouse-over effects, drag and drop feedback, the automatic refreshing of screen data, animation of various elements, or the implementation of fade-in or fade-out effects. Interactive applications leverage the fast JavaScript engines in modern browsers to perform their client-side tasks.
  • They limit full-page reloads. Modern web applications seek to limit the number of full-page reloads. Reloads are much slower than a localized Ajax call to update a portion of the UI. Full-page reloads also limit the ability to animate state or page changes. By not performing a full-page reload, users can be kept in context, providing a fluid experience as they navigate from one task to another.
  • They are asynchronous. Modern web applications use Ajax to dynamically load data, page fragments, or other assets instead of performing a full-page reload to acquire data or HTML content. Because the loading of data is asynchronous, the UI is able to stay responsive and keep the user informed while the data request is being fulfilled. This asynchronous on-demand loading also reduces application response time because requests can be tuned to return only the data and other content that needs to change.
  • They manage data. When applicable, modern web applications provide client-side data caching and prefetching to boost client-side performance. This enables the UI to immediately respond to user input gestures because it does not have to make a call to the server for data. Data caching also serves to minimize the impact on server resources, increasing application scalability because fewer calls to the server are required.

We will be using Lots of Technologies on this Project and since I am Just Getting Started to let’s List the Basic Technologies we will be using and More will be added based on the needs of each section.


For over 10 years, the web has benefited from the ability to replace full-page reloads with Ajax calls. But given the advances in standards such as CSS3 and HTML5, browsers adherence to those standards, and the arrival of powerful, cross-browser JavaScript frameworks, we have all the tools necessary to build highly engaging client-side experiences.

Ajax facilitates a paradigm change in web development from the traditional full-page reload model of server-centric applications to rich, responsive client-centric applications. The client receives data and updates the UI using JavaScript. Bandwidth requirements are minimized because the server responds to requests by returning just the requested data instead of HTML pages (and all their elements) along with the data. The application runs faster because the data requests take less time to complete, and the UI is quickly updated without a full-page reload. Asynchronous calls are essential to keeping interactive and immersive applications responsive from the user's perspective.


JavaScript is a dynamic, functional, prototypal language that has a very close relationship with the document object model (DOM). For both JavaScript and the DOM, there are features you can use with confidence and others you should avoid. Over the past ten years, the web development community has learned a great deal about how to use these together to maximize success. See the "Further Reading" section for resources that explain the recommended ways of using JavaScript. Project Silk adheres to these practices, but we do not present a primer here.

As is true with all environments, you will be most successful using it as intended. If you aren't presently writing JavaScript code according to the patterns currently accepted in the JavaScript community, be sure your team has time to become familiar with them, because you may be surprised. For example, the Project Silk team members who had recently worked in the Microsoft .NET environment needed to ramp up on the following aspects of JavaScript:

  • JavaScript uses object-oriented concepts, but classes and inheritance hierarchies are not the same as in other .NET languages such as Visual C# and Visual Basic.NET.
  • Understanding closures and variable scoping is important. They are used intentionally and often by allowing variables defined within one scope to be used in another function.
  • The object that the this keyword refers to changes based on where it is used. For example in a single method, this may refer to the object the method is defined on, and in a loop within that same method this may refer to the current item of the collection being iterated over. You should understand its rules.
  • Objects without type definitions are very common and use an object literal syntax. The commas between properties and functions used in these object literals may cause syntax errors until you are familiar with them.

jQuery is an open-source JavaScript library that addresses the challenges of working with the DOM across browsers. It has a straightforward API that can be divided into two calling conventions:

  • Functions are called on the jQuery object itself. For example, the extend function merges the properties and methods of two different objects together. It looks like this: $.extend(targetObject, objectToMerge).
  • Methods are called on the wrapped set. A wrapped set is the result of a query that uses a selector to find elements in the DOM. To call a method on a wrapped set of elements, a selector is used to select elements in the DOM. For example, to add the listing CSS class to all ul elements directly inside a div element, $('div ul').addClass('listing') can be used.

jQuery also provides features to raise and handle events, make Ajax requests, and process the data returned from Ajax requests. To be successful developing with jQuery, you should:

  • Know that the selector syntax uses and extends the CSS selector syntax. The better you're able to leverage this syntax, the cleaner your HTML can be.
  • Understand what the wrapped set is, how it's different from an array of DOM elements, and which you're working with at any given time. For example, when using $.each, inside the callback, this is not wrapped.
  • Understand that animations are asynchronous and are queued. Use a named queue or the stop method to gain more control over how the animations behave.

In the past, the client-side application would use navigator.userAgent to determine which browser was in use and choose its code paths accordingly. Today, the accepted practice is to explicitly detect each feature the application intends to use.

Modernizr is an open-source JavaScript library that detects the support for browser features (geolocation, canvas, SVG, border-radius, etc.) and exposes its findings in CSS and JavaScript. Once a script reference to Modernizr is included, Modernizr will add a CSS class to the html element for each feature it can detect. If the feature isn't supported, the CSS class will start with no-. For example, if a browser supports canvas and not webgl, its html element will look like this: <html class="canvas no-webgl ...">. Modernizr also exposes a Modernizr JavaScript object that has Boolean properties for each feature it can detect.


Lets Have a Break for now and The next Post will be about the Back end Basic Architecture so we can have something to kick of our Web Project with.


Windows 10 upgrade considerations for screen reader and magnifier users

MSDN Blogs - Fri, 07/03/2015 - 10:02

If you currently use Assistive Technologies (AT), like screen readers or magnifiers, your experience on Windows 10 will be similar in many ways to what you are accustomed to on Windows 7 and Windows 8.1. In addition, Windows 10 introduces new features and applications that will continue to improve as we deliver Windows as a service to our customers over time. Learn a few tips for a more accessible Windows 10 experience at the accessibility blog.

...(read more)


Subscribe to Randy Riness @ SPSCC aggregator
Drupal 7 Appliance - Powered by TurnKey Linux