Quantcast
Channel: Category Name
Viewing all 10804 articles
Browse latest View live

Visual Studio for Mac as the default editor for Unity

$
0
0

Unity is a powerful solution to create games for a multitude of platforms, from mobiles to consoles, desktop and web games. Since Unity 5.2, Visual Studio and the Visual Studio Tools for Unity have been the default experience on Windows.

When we released Visual Studio for Mac last year, Unity was among the first scenarios we supported out of the box. I’m happy to share that starting Unity 2018.1, Visual Studio for Mac will be included by default for developers on macOS.

This means that everyone will be able to utilize the benefits of the (currently experimental) .NET 4.6 scripting runtime upgrade in Unity, including all the goodies of C# 6.0 and access to the Microsoft Azure SDK to add powerful cloud services to your games. This is all in addition to the existing one-click debugging, customized solution pad, IntelliSense autocompletion, and many more productivity features.

Check out my post “Unity game development with Visual Studio for Mac” for more information on all that Visual Studio for Mac has to offer for Unity developers, or watch the video below on how Visual Studio 2017 and Visual Studio for Mac boost your development productivity.

You can also read Unity’s announcement for more details.

To get started today, download Visual Studio for Mac and set it as the default editor in Unity. Visual Studio Community for Mac is free to use for students, open-source and individual developers, as well as small teams. Check out the license terms for more information.

As always, let us know what you think in the comments below.

Jb Evain, Principal Software Engineer Manager
@jbevain

Jb runs the Visual Studio Tools for Unity experience He has a passion for developer tools and programming languages, and has been working in developer technologies for over a decade.


This month on Bing: flight status and entertainment & sports predictions

$
0
0
This month at Bing we shipped several new experiences that let you quickly find what you’re looking for.
 
 

Flight status


Checking flight status can be a hassle, whether you’re rushing to pick someone up from arrivals, or if you’re in a terminal and want to check that your flight details haven’t changed.

Bing’s new tracking feature alleviates this by letting you look up flight statuses, even when you don’t have the airline or flight number on hand. Simply search by city name or airport code, and Bing pulls the results for you across airlines.


 
Of course, if you do know the airline or flight number, you can include that information in your search, and Bing will show you narrower results so you can more quickly find the flight you’re looking for. Bing also shows detailed information such as terminal and gate when that data is available.

 

Entertainment & sports

 
Bing not only tracks results from your favorite events so you can keep track of them, it provides predictions in advance so you be a more informed viewer in the moment.
 
Bing provided predictions for the winners of the top 2018 Golden Globes categories, and got 9 of 14 categories correct.


 
Bing also has an up-to-date tracker so users after the ceremony can check who the winners were.
 
And, if awards season has got you with movies on your mind, Bing continues to provide answer carousels for when you want to find out popular and new releases on Netflix and Amazon Prime.


 
Bing has also got you covered if sports are more your thing.
 
It's playoff season for the NFL and we've got predictions of winners in the weekly matchups. Simply search for “NFL”, or for specific stages of the playoffs, and Bing will show you which teams are playing, and closer to the games, what our predictions are for each team’s chance of winning.


 
Bing has got predictions for the Australian Open as well. The first-round matches begin on January 15th, for which we’ll have predictions by February 14th.

We hope you’re as excited by these releases as we are; we’d love to hear your thoughts and feedback at User Voice!

- The Bing Team

.NET Core January 2018 Update

$
0
0

Today, we are releasing the .NET Core January 2018 Update. This includes .NET Core  1.0.9, 1.1.6 and 2.0.5.

Please leave feedback on the release in the comments below or at dotnet/core #1199.

Security

CVE-2018-0786 – Security Feature Bypass in X509 Certificate Validation

Microsoft is aware of a security vulnerability in the public versions of .NET Core where an attacker could present a certificate that is marked invalid for a specific use, but a component uses it for that purpose. This action disregards the Enhanced Key Usage tagging.

The security update addresses the vulnerability by ensuring that .NET Core components completely validate certificates.

CVE-2018-0786

CVE-2018-0764 – Denial of Service when parsing XML documents

Microsoft is aware of a Denial of Service vulnerability in all public versions of .NET core due to improper processing of XML documents. An attacker who successfully exploited this vulnerability could cause a denial of service against a .NET application. A remote unauthenticated attacker could exploit this vulnerability by issuing specially crafted requests to a .NET Core application.

The update addresses the vulnerability by correcting how .NET core handles XML document processing.

CVE-2018-0764

Getting the Update

The .NET Core January 2017 Update is available from the .NET Core download page.

You can always download the latest version of .NET Core at .NET Downloads.

Docker Images

.NET Docker images have been updated for today’s release. The following repos have been updated.

Note: Look at the “Tags” view in each repository to see the updated Docker image tags.

Note: You must re-pull base images in order to get updates. The Docker client does not pull updates automatically.

Previous .NET Core Updates

The last few .NET Core updates follow:

 

.NET Framework 4.7.1 is available on Windows Update, WSUS and MU Catalog!

$
0
0

Today, we are happy to announce the Microsoft .NET Framework 4.7.1 is available on Windows Update, Windows Server Update Services (WSUS) and Microsoft Update (MU) Catalog. This includes reliability fixes based on your early feedback on the release. .NET Framework 4.7.1 is available for the following client and server platforms:

  • Client platforms: Windows 7 SP1, Windows 8.1, Windows 10 Anniversary Update (Version 1607), Windows 10 Creators Update (Version 1703)
  • Server platforms: Windows Server 2008 R2 SP1, Windows Server 2012, Windows Server 2012 R2 and Windows Server 2016

These reliability fixes are also available on Download Center as a standalone update (KB4054856).  If you  installed .NET Framework 4.7.1 via Download Center, please install KB4054856. This update applies on the client and server platforms mentioned above.

.NET Framework 4.7.1 is included in the Windows 10 Fall Creators Update (Version 1709), released in October 2017.  These .NET Framework 4.7.1 reliability fixes will be included in an upcoming Cumulative Update for Windows 10 Fall Creators Update and Windows Server 2016 Version 1709.

Reliability fixes

The following fixes are included:

Base Class Library (BCL)

  1. Applications targeting .NET 4.6.1 that use .NET Standard libraries might be broken when running on .NET Framework 4.7.1.
  2. CultureAwareComparer with ignore casing serialized on previous versions of .NET Framework does not correctly deserialize on .NET Framework 4.7.1.
  3. Applications making heavy use of System.Diagnostics.StackTrace or Exception.StackTrace might run more slowly on the .NET Framework 4.7.1.

Windows Presentation Framework (WPF)

  1. Certain dual GPU machines may experience visual artifacts while running WPF apps in high contrast.
  2. In specific scenarios, the System.Windows.Controls.PrintDialog() throws an Arithmetic Overflow exception.

You can see the complete list of improvements for .NET Framework 4.7.1 in the .NET Framework 4.7.1 release notes.

Knowledge Base Articles

You can reference the following Knowledge Base Articles for the WU/WSUS/Catalog release:

 

.NET Framework 4.7.1 Redistributable
.NET Framework 4.7.1 Reliability fixes 
.NET Framework 4.7.1 Language Pack
Windows 7 SP1 /Windows Server 2008 R2 KB4033342 KB4054852 (Co-installed with KB4033342 on WU/WSUS/Catalog) KB4033339
Windows Server 2012 KB4033345 KB4054853 (Co-installed with KB4033345 on WU/WSUS/Catalog) KB4033343
Windows 8.1/Windows Server 2012 R2 KB4033369 KB4054854 (Co-installed with KB4033369 on WU/WSUS/Catalog) KB4033417
Windows 10 Version 1607 KB4033393 KB4054855 (Co-installed with KB4033393 on WU/WSUS/Catalog) KB4033418
Windows 10 Version 1703 KB4033393 (Catalog Only) KB4054855 (Available for installation with KB4033393 in Catalog only) KB4033418 (Catalog only)
Windows Server 2016 KB4033393 (Catalog Only) KB4054855 (Available for installation with KB4033393 in Catalog only) KB4033418 (Catalog only)

How is this release available?

Automatic Updates

.NET Framework 4.7.1 is being offered as a Recommended update. The reliability fixes for .NET Framework 4.7.1 will be co-installed with .NET Framework 4.7.1. At this time, we’re throttling the release like what we have done with previous .NET Framework releases. Over the next few weeks we will be closely monitoring your feedback and will gradually open throttling.

While the release is throttled, you can use the Check for updates feature to get .NET Framework 4.7.1.

Note: throttled updates are offered at a lower priority than unthrottled updates, so if you have other Recommended or Important updates pending those will be offered before this update.

Once we open throttling, in most cases you will get the .NET Framework 4.7.1 with no further action necessary. If you have modified your AU settings to notify but not install you should see a notification in the system tray about this update.

The deployment will be rolled out to various geographies globally over several weeks. So, if you do not get the update offered on the first day and do not want to wait until the update is offered, you can use the Check for updates feature, as described above.

Windows Server Update Services (WSUS) and Catalog

WSUS administrators will see this update in their WSUS admin console. The update is also available in the MU Catalog for download and deployment.

When you synchronize your WSUS server with Microsoft Update server (or use the Microsoft Update Catalog site for importing updates), you will see the updates for .NET Framework 4.7.1 published for each platform.

More Information

Language Packs

In addition to the language neutral package the .NET Framework 4.7.1 Language Packs are also available on Windows Update. These can be used to if you have a previous language pack for .NET installed as well as if you don’t, but instead have a localized version of the base operating system or have one or more Multilingual User Interface (MUI) pack installed.

Blocking the automatic deployment of .NET 4.7.1

Enterprises may have client machines that connect directly to the public Windows Update servers rather than to an internal WSUS server. In such cases, an administrator may have a need to prevent the .NET Framework 4.7.1 from being deployed to these client machines to allow testing of internal applications to be completed before deployment.

In such scenarios, administrators can deploy a registry key to machines and prevent the .NET Framework 4.7.1 from being offered to those machines. More information about how to use this blocker registry key can be found in the following Microsoft Knowledge Base article:

KB4052152:  How to temporarily block the installation of the .NET Framework 4.7.1 and its corresponding language packs

FAQ

What do I need to do if I already have .NET Framework 4.7.1 product installed?

If you installed .NET Framework 4.7.1 via Download Center, please install KB4054856, also available on Download Center as a standalone updateKB4054856 includes reliability improvements for .NET Framework 4.7.1.

Do I still need to install KB4054856 if I am getting .NET Framework 4.7.1 from Windows Update/WSUS?

No, .NET Framework 4.7.1 via Windows Update and WSUS will co-install the reliability fixes in KB4054856.

How can I get the reliability fixes for Windows 10 Creators Update (Version 1709)?

These reliability fixes will be available via an upcoming Windows Cumulative update for Windows 10 Creators Update (Version 1709).

What is the offering type for .NET Framework 4.7.1 on Windows Update? 

.NET Framework 4.7.1 is being offered as a Recommended update.

 

64 bit ASP.NET Core on Azure App Service

$
0
0

When creating an Azure App Service .NET Core is already pre-installed. However, only the 32 bit .NET runtime is installed. In this post we will look at a  few ways that you can get a 64 bit runtime on Azure App Service

During the 2.1 timeframe we are hoping to have both 32 and 64 bit runtimes installed as well as enabling the portal experience to switch between the two.

1. Deploy a self-contained application

Self-contained deployments don’t require .NET Core to be installed on a machine, because they carry the runtime they need with them. Because of this you can deploy a 64bit self-contained deployment to Azure App Service. For information about self-contained deployments you can look here:

Information: https://docs.microsoft.com/en-us/dotnet/core/deploying/

CLI instructions: https://docs.microsoft.com/en-us/dotnet/core/deploying/deploy-with-cli

Visual Studio instructions: https://docs.microsoft.com/en-us/dotnet/core/deploying/deploy-with-vs

2. Deploy your own runtime

The pre-installed runtime is installed on a local SSD, but you can copy your own runtime onto your server and modify your application to use that instead. To do this you would:

  1. Download a zip of the x64 runtime that you want to use
  2. Go to the Kudu console (under advanced tools, debug console)
  3. Drag the zip of the runtime onto the file explorer section of the Kudu console. Kudu has a feature that will copy up the zip and extract it on the server. The UI should change as you drag the zip showing you a location to drop the zip in order for this feature to work.
  4. Modify your applications web.config to use the dotnet.exe that was just extracted on the server

A web.config file is generated for your ASP.NET Core application when you don’t have one in your App. But if your application already contains one, then it will be used instead. Your web.config would like this:

[PATH_TO_EXE] will point to the location you extracted the dotnet.exe, for example D:homedotnetdotnet.exe. Your application will now use the copy of dotnet.exe that you copied to the server, meaning that it is now using a 64 bit runtime.

NOTE: There are two main caveats with this approach. 1, you must service your own runtime. If a new patch of .NET Core comes out then you will need to deploy it yourself to get any improvements. 2, the cold start time of your application will likely be a bit slower as the runtime is loading from a slower drive.

3. Use Linux Azure App Service

There is no official 32 bit runtime for .NET Core available on Linux. Because of that, if you use Linux Azure App Service then you will have a 64 bit runtime with a normal deployment.

4. Use Web Apps for Containers

Because you are deploying your own container, with whichever runtime you choose, when using Containers you will always have the runtime that you want available. You can find more information about web Apps for Containers here: https://azure.microsoft.com/en-us/services/app-service/containers/

Conclusion

We hope to add 64 bit as a pre-installed option for Azure App Service, but in the meantime you can use the options listed here if you need a 64 bit runtime.

.NET for UWP January 2018 Update

$
0
0

Today, we are releasing the .NET for UWP January 2018 Update.

This post includes the fix included and instructions on how to update your applications.

Security

CVE-2018-0786 – Security Feature Bypass in X509 Certificate Validation

Microsoft is aware of a security vulnerability in the public versions of .NET Core where an attacker could present a certificate that is marked invalid for a specific use, but a component uses it for that purpose. This action disregards the Enhanced Key Usage tagging.

The security update addresses the vulnerability by ensuring that .NET Core components completely validate certificates.

CVE-2018-0786

Getting the Update

.NET for UWP fixes are released differently than .NET Framework. While .NET Framework fixes are released via Windows Update, .NET for UWP requires that applications be re-processed by the .NET native compiler to incorporate the fixes and the re-processed version needs to be distributed via the Windows Store.

We recommend that you update your .NET UWP apps to use the latest minor version of the Microsoft.NETCore.UniversalWindowsPlatform NuGet package so that you can build and verify that your app works as expected when updated. If you are using version 6.0.x, you should update to 6.0.6 and if you’re using 5.2.x, you can update to 5.2.4. Of course, you can update to a higher major version too, but we are distributing security updates for all impacted major versions (currently 5.2.x, 5.3.x, 5.4.x and 6.0.x). Additionally, whether or not you update your NuGet packages, all applications submitted to the store after today will be automatically fixed during submission processing.

If you do not update your app in the Store, it will automatically be reprocessed and distributed via an application update in the next few weeks. Users who have automatic app updates enabled will get the fix with no intervention on your or their parts. Because updated apps are distributed through the Windows Store, sideloaded apps will not be automatically updated. We recommend that developers who distribute sideloaded apps update the affected NuGet packages, rebuild their applications and distribute them to their users.

Microsoft is committed to keeping UWP applications secure and to supporting developers. If you have feedback on the fix distribution process, please let us know at dotnetnative@microsoft.com.

Updated NuGet packages

Nuget Packages impacted: Nuget Packages to update to:
Microsoft.NETCore.UniversalWindowsPlatform 5.2.* (contains .NET native 1.4.*) Microsoft.NETCore.UniversalWindowsPlatform 5.2.4
Microsoft.NETCore.UniversalWindowsPlatform 5.3.* (contains .NET native 1.6.*) Microsoft.NETCore.UniversalWindowsPlatform 5.3.5
Microsoft.NETCore.UniversalWindowsPlatform 5.4.* (contains .NET native 1.7.*) Microsoft.NETCore.UniversalWindowsPlatform 5.4.2
Microsoft.NETCore.UniversalWindowsPlatform 6.0.* (contains .NET native 2.0.*) Microsoft.NETCore.UniversalWindowsPlatform 6.0.6

 

.NET Framework January 2018 Security and Quality Rollup

$
0
0

Today, we are releasing the November 2018 Security and Quality Rollup.

See .NET Framework 4.7.1 is available on Windows Update, WSUS and MU Catalog! for separately available reliability updates for the .NET Framework 4.7.1.

Security

CVE-2018-0786 – Security Feature Bypass in X509 Certificate Validation

Microsoft is aware of a security vulnerability in the public versions of .NET Core where an attacker could present a certificate that is marked invalid for a specific use, but a component uses it for that purpose. This action disregards the Enhanced Key Usage tagging.

The security update addresses the vulnerability by ensuring that .NET Core components completely validate certificates.

CVE-2018-0786

CVE-2018-0764 – Denial of Service when parsing XML documents

Microsoft is aware of a Denial of Service vulnerability in all public versions of .NET core due to improper processing of XML documents. An attacker who successfully exploited this vulnerability could cause a denial of service against a .NET application. A remote unauthenticated attacker could exploit this vulnerability by issuing specially crafted requests to a .NET Core application.

The update addresses the vulnerability by correcting how .NET core handles XML document processing.

CVE-2018-0764

Quality and Reliability

This release contains no new quality and reliability improvements.

Getting the Update

The Security and Quality Rollup is available via Windows Update, Windows Server Update Services, Microsoft Update Catalog, and Docker.

Microsoft Update Catalog

You can get the update via the Microsoft Update Catalog. For Windows 10, .NET Framework updates are part of the Windows 10 Monthly Rollup.

Product Version Security and Quality Rollup KB Security Rollup KB
Windows 10 1709 (Fall Creators Update) Catalog
4056892
N/A
.NET Framework 3.5 4056892 N/A
.NET Framework 4.7.1 4056892 N/A
Windows 10 1703 (Creators Update) Catalog
4056891
N/A
.NET Framework 3.5 4056891 N/A
.NET Framework 4.7 4056891 N/A
Windows 10 1607 (Anniversary Update) Catalog
4056890
N/A
.NET Framework 3.5 4056890 N/A
.NET Framework 4.6.2, 4.7 4056890 N/A
Windows 10 1511 Catalog
4056888
N/A
.NET Framework 3.5 4056888 N/A
.NET Framework 4.6.1 4056888 N/A
Windows 10 1507 Catalog
4056893
N/A
.NET Framework 3.5 4056893 N/A
.NET Framework 4.6 4056893 N/A
Windows 8.1
Windows RT 8.1
Windows Server 2012 R2
Catalog
4055266
Catalog
4055271
.NET Framework 3.5 4054999 4054177
.NET Framework 4.5.2 4054993 4054170
.NET Framework 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1 4055001 4054182
Windows Server 2012 Catalog
4055265
Catalog
4055270
.NET Framework 3.5 4054997 4054175
.NET Framework 4.5.2 4054994 4054171
.NET Framework 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1 4055000 4054181
Windows Server 2008 Catalog
4055267
Catalog
4055272
.NET Framework 2.0, 3.0 4054996 4054174
.NET Framework 4.5.2 4054995 4054172
.NET Framework 4.6 4055002 4054183

Docker Images

Docker images have been updated as part of today’s release (actually, a few days ago).

Note: Look at the “Tags” view in each repository to see the updated Docker image tags.

Note: Significant changes have been made with Docker images recently. Please look at .NET Docker Announcements for more information.

Previous Monthly Rollups

The last few .NET Framework Monthly updates are listed below for your convenience:

Other Updates:

Manage and Auto-scale your IoT solution with a predictable IoT Cloud

$
0
0

As companies continue to fully roll out their IoT projects, management of the various components of the solution becomes a critical part of their operations. The flexibility of Azure IoT Hub to enable customers to start small, paying only for the amount of IoT Hub capacity needed at any point along the device deployment curve, helps drive predictability in the cost of an IoT solution.

However, the potentially irregular rate of device and message growth in an IoT solution does add a unique challenge for operations. When the number of messages ingested from devices in a given day exceeds the limit of the chosen IoT Hub capacity, the IoT Hub will begin to reject messages until either the IoT Hub is scaled-up, or the time rolls over into the next day (UTC time). Wouldn’t it be nice to have IoT Hub just automatically scale up to a higher capacity when a certain threshold of messages is met, before this limit is reached?

While at this point, IoT Hub does not have this capability built into the service, we have published a sample solution for monitoring and automatically scaling your IoT Hub based on reaching a specific threshold of messages. The sample, published on the Azure-Samples site, leverages the Azure Durable Functions framework and the IoT Hub Management Client to continually monitor the consumption of your IoT Hub message quota and, when needed, programmatically scale up your IoT Hub capacity.

Azure Durable Functions

To orchestrate our IoT Hub scaling solution, we leverage the Singleton Orchestrator pattern of the Azure Durable Functions framework. The key benefit of this pattern is the ability to ensure that exactly one instance of the scaling solution for a given IoT Hub is running at a time. That frees us from having to worry about the possible race conditions of multiple instances of our scaling function running concurrently. The pattern really consists of three functions that operate our solution:

  • IotHubScaleInit - this function is executed on a regular timer (by default, once per hour). This function checks to see if an instance of the Orchestrator function is running and, if not, starts one.
  • IotHubScaleOrchestrator - this function implements the Orchestrator for the solution. It’s role in the pattern is to manage the execution of the worker function
  • IotHubScaleWorker - this is the function that performs the actions of checking to see if the IoTHub needs to be scales and, if so, scaling it.

We start with a timer-initiated IoTHubScaleInit function that runs occasionally (in the sample, once an hour) and checks to see if an instance of the orchestrator is already running and, if not, starts one. The relevant code, from the IoTHubScaleInit function is shown below, some code removed for brevity.

const string IotHubScaleOrchestratorInstanceId = "iothubscaleorchestrator_1";

var existingInstance = await starter.GetStatusAsync(IotHubScaleOrchestratorInstanceId);

if (existingInstance == null)
{
    await starter.StartNewAsync(IotHubScaleOrchestratorName,IotHubScaleOrchestratorInstanceId, input: null);
}

The key to this function is the constant instance ID. By default, when you launch an orchestrator, the system will generate a unique instance ID. In our case, by specifying an ID, we can check and see if that instance is already running with the GetStatusAsync function.

The IotHubScaleOrchestrator function, as the name implies, orchestrates the execution of the solution. It recovers from failures in execution, and also allows dehydration of the code while waiting on the next execution. But most importantly, it allows us to make sure we kick off another instance of the scaling function after the existing one finishes. This is the critical part of making sure we never have more than one instance executing at a given time. The key parts of this function are:

await context.CallActivityAsync(IotHubScaleWorkerName);

DateTime wakeupTime = context.CurrentUtcDateTime.Add(TimeSpan.FromMinutes(JobFrequencyMinutes));
await context.CreateTimer(wakeupTime, CancellationToken.None);

context.ContinueAsNew(null);

After calling and waiting on the worker function, we create a timer via the Durable Functions framework. The ContinueAsNew method of the context object then tells the framework to end this instance and schedule another one to fire up when the timer expires. The framework takes care of the rest.

The remainder of the solution is the IotHubScaleWorker function, which performs the actual work of checking the status of the IoT Hub usage and, if necessary, scaling it.

IoT Hub Management Client

The IoT Hub Management Client enables you to interact with the control plane of the IoT Hub service, including creating, deleting, and managing the configuration of your IoT Hubs. Within the worker function, the client does all of the heavy lifting of interacting with the IoT Hub service.

For example, the following two snippets from the code get the current configuration details of the IoT Hub, the most important of which for our purposes is the current SKU (S1, S2, or S3) and the current number of units. The second line gets the current operational metrics of the hub. The primary one of interest is the TotalMessages metric which gives the current number of messages the IoT Hub has ingested that day.

IotHubDescription desc = client.IotHubResource.Get(ResourceGroupName, IotHubName);
IPage<iothubquotametricinfo> mi = client.IotHubResource.GetQuotaMetrics(ResourceGroupName, IotHubName);

Once we have that information, we determine via a couple of helper functions included in the sample, if we need to scale the IoT Hub by comparing the current message count with a defined threshold for that SKU/unit combination. If we need to scale, we simply update the SKU and units within the IoTHubDescription object we obtained above, and leverage the CreateOrUpdate management function to update the configuration of our IoT Hub. This performs the scale up of the IoT Hub with no interruption to existing devices or clients.

desc.Sku.Name = newSkuName;
desc.Sku.Capacity = newSkuUnits;
client.IotHubResource.CreateOrUpdate(ResourceGroupName, IotHubName, desc);

Scaling Down

With the trajectory of most IoT projects being growth, and for simplicity, we focused this sample on scaling-up IoT Hubs. However, there are certainly valid scenarios where an IoT Hub may need to be automatically scaled down to lower costs when previous message volumes drop. In the sample documentation, we offer some suggestions for modifying the solution for scaling down IoT Hubs when necessary.

Give the sample a try and sleep better tonight knowing you have one fewer operational tasks on your plate!

A few notes about the sample

  • The sample only works for the Standard tiers of IoT Hub. The Free tier of IoT Hub can’t be scaled, so it’s not applicable. Also note that you cannot convert directly from the Free tier of IoT Hub to a Standard tier.
  • The sample provides one straightforward implementation of a scaling algorithm, but with the supplied source code, you can customize it to meet your unique scaling needs.
  • For the sake of your IoT budget, due consideration should be given to automatically scaling IoT Hub as you reach the higher service levels, such as S3, as each unit increase adds both significant capacity as well as cost.

Azure Marketplace new offers in December 2017

$
0
0

We continue to expand the Azure Marketplace ecosystem. In December 2017, seven new offers successfully met the onboarding criteria and went live. See details of the new offers below:

image

Heimdall Data SQL Optimization Platform: Heimdall Data is an all-in-one SQL platform for the application developer and DBA.

image

Luminate Security Connector: Luminate Security revolutionizes the way enterprises provide secure access to corporate applications and services hosted in Microsoft Azure.

image

Renku Language Detection Engine: Renku Language Detection Engine performs language detection on natural language text. When given input text, Renku applies statistical methods to determine probabilities of the text belonging to over 100 languages.

image

BeeGFS Free - Community Support: High performance distributed, parallel file system from Thinkparq.

image

Elastic Stack on Kubernetes: Bring your own license enabled. This application, from Visual Studio China, is free to use, without any software fees and is fully functional without limitations or the need to purchase a license.

image

Quartus® Pro and Intel® FPGA SDK For OpenCL™: The revolutionary Intel Quartus Prime design software includes everything you need to design for Intel FPGAs, SoCs, and CPLDs from design entry and synthesis to optimization, verification, and simulation.

image

Wordpress LEMP Max Performance: The maximum performance one click install solution for Wordpress 4 from Jetware. A free and open source content management system (CMS), running on completely integrated, pre-configured and optimized LEMP stack with the freshest PHP 7.

FIT and hhpberlin Build Life-Saving Fire Safety Solution Powered by Bing Maps

$
0
0

Partners combine Augmented Reality and Digital mapping to create a life-saving application on Windows Azure. This Interview with the Fichtner IT Consulting (FIT) architects explains how they enable rapid information sharing to provide first responders with up to the minute logistical details during rescue operations.

FIT is the IT competency center of the globally active Fichtner Group. FIT advises and implements powerful IT solutions for technical networks, plants and infrastructure and combines industry knowledge and process know-how with the latest technology competency to provide innovative and cost-effective solutions. Working with hhpberlin, one of Europe’s market leaders in precautionary fire protection concepts, FIT developed a life-saving fire safety solution called ARE firechief.

ARE firechief is a Sustainable Safety Platform for Communities that provides relevant security information in a digital, interactive and visually attractive way in near or realtime, empowering user groups like fire fighters, facility managers or hotel guests to make better decisions in emergency situations based on actual data. It helps these users quickly find security infrastructure assets, rescue routes and essential information. 

ARE firechief

The Microsoft Bing Maps for Enterprise platform is used as the essential front end module for the user and provides data visualization, geocoding and routing functionality while the complete Azure infrastructure (i.e., SQL Azure / Azure Storage, Azure Active Directory, ExpressRoute and Azure ExpressRoute) handles data management and process workflows. ARE firechief is a true showcase of integrated Microsoft technologies.

“The Microsoft Bing Maps for Enterprise platform empowered us to realize next generation fire engineering with the ARE firechief solution enabling new scalable, cloud-based business models for our customer, hhpberlin,” says Peter Brack, Director Business Geo Intelligence at FIT.

The idea for ARE firechief came about as hhpberlin found that fire fighting, escape and rescue plans are typically static, paper-based plans that can be ineffective in emergency situations. Printed plans often hung on walls in shopping malls, hotel room doors, and in train stations can be difficult to find and understand in an emergency. The “ARE” in ARE firechief stands for Augmented Reality Environment, and with ARE firechief, the Bing Maps platform is integrated as the basic element of the Graphical User Interface displaying infrastructure assets on high-resolution aerial 3D imagery. Also, it fully supports the immersive geocoding and routing capabilities to help enable pedestrian and vehicle navigation and orientation onsite for quicker evacuation and response in emergency scenarios.

Below is Q&A with the FIT team about how they are using Bing Maps in their solution:

What are you using Bing Maps for Enterprise for?

ARE firechief uses Bing Maps in conjunction with the complete Azure infrastructure (i.e., SQL Azure / Azure Storage, Bing Maps for Enterprise, Azure Active Directory, ExpressRoute and Azure ExpressRoute) to enable modern and scalable applications. To particularly support (mobile) devices hhpberlin and Fichtner IT Consulting choose the Universal Windows Platform as prioritized platform for mobile users and a HTML5/ Javascript ASP responsive website as an administration tool including functionality to update infrastructure assets. The HTML5 website platform has been developed using the Bing Maps AJAX API while the Universal Windows Platform app was developed with several UWP Bing Maps powered views to assist users, including personnel from security companies, fire departments, venue staff and even people fleeing from emergency situations. The application utilizes the following features of the Bing Maps platform in the multi-layered views for users:

  • Augmented Reality View
  • 3D View
  • Bird’s Eyes Views
  • Offline Maps

All layers include (augmented) security relevant information (e. g., rescue plan, emergency exits, fire extinguisher, alpha-numeric attributes etc.) displayed on screen plus the precise location of the user. Functionality of course includes augmented reality camera interactivity in terms of display of information based on user position and movements, pedestrian and car routing and an automatic switch of views in case the device is tilted or offline. The immersive Bing Maps routing capabilities are - of course - used to enable evacuation scenarios as well as drive-time calculations for emergency service teams.

Why did you choose Bing Maps for Enterprise in your solution? (E.g., support, features, etc.)

hhpberlin and FIT chose Bing Maps for Enterprise as a web-based mapping platform because of its perfect and seamless integration with Universal Windows Platform and the Azure Cloud Platform services, its coverage with high-resolution aerial imagery, the available 3D models for relevant cities and it’s immersive functionality with respect to geocoding and routing. It additionally provides a massive set of point-of-interests by the Spatial Data Service API, including a perimeter search to recognize infrastructures at risk in the nearby surrounding area. For use in emergency situations when Internet connectivity might be weak, the possibility to display maps in the form of comprehensive offline maps is essential and automatically recognized and switched on by the API.

Another plus has been the professional enterprise support of the platform and the profound documentation of the available for the required APIs. Bing Maps has existed since 2001 and is a proven interface for business-critical applications.

What benefits are you seeing?

ARE firechief clearly shows what is possible when actors and organizations share information and enable barrier-free access. Various actors and organizations can participate, from the caretaker who determines that a hydrant is broken right up to the fire brigade who affects the repair of the same. Digital fire protection documents help, for example in an emergency situation where emergency personnel have to make quick and decisive decisions. In order to shorten the time span until the rescue service arrives, an app alerts volunteers in the near vicinity. By means of a quality management system, the fire brigade is always informed in real-time about the availability of the employees as well as the condition of the buildings and equipment in question.

hhpberlin and FIT are convinced that the innovative Augmented Reality Environment (ARE) solution will change the world of fire protection documents in terms of interactivity, mobility and scalability. ARE is part of the first one-stop shop ”safetynext.one” for fire engineering tools like fire-framework (modelling, simulating and analyses of fires), Emergency Reporting (Fire Records Management), crowd:it (pedestrian flow simulation) and many more.

Our goal for the future is to help shape and promote Secure Smart City. The cities of the future will be intelligent, networked and more secure. To achieve this, it requires courage to change. Digitization is the fuel that can improve civilian security, to make the world a safer place.

To learn more about ARE firechief, go to https://www.safetynext.one/en/tool/firechief.

To learn more about Bing Maps and see other customer stories go to https://www.microsoft.com/en-us/maps.

Support for Continuous Delivery to Containers and TFVC in Visual Studio 15.6 Preview 2

$
0
0

We have an update for the Configure Continuous Delivery feature in Visual Studio. For Solutions with an ASP.NET or ASP.NET Core projects you can right click on the solution node and select “Configure Continuous Delivery…”with and without container support. You can always configure Continuous Delivery for solutions under source control in GitHub and VSTS Git repositories to App Service.

With the release of Visual Studio 2017 15.6 Preview 2, you can also configure Continuous Delivery to Web App for Containers – App Service on Linux for solutions under source control in GitHub, VSTS Git repositories as well as TFVC repositories on VSTS. When you click configure Continuous Delivery on the solution menu, the configure continuous delivery automatically detects the source control provider to determine if it is TFVC or Git and the remote source control host to determine if it is VSTS or GitHub.

Configure Continuous Delivery on Solution Menu

If the remote source control host is VSTS and the source control provider is TFVC, the Configure Continuous Delivery dialog automatically selects the remote server path that your local solution folder is mapped to as your source control folder for the continuous integration build definition.

Remote server path auto selected to match local solution folder mapped to source control folder

You can select the target Azure subscription and Azure service host. When you click OK, CD4VS will automatically configure a build and release definition that will fire a build and release whenever anyone on your team checks in code to that source control folder.

Other enhancements

In this preview, we also introduced inline creation of a new Azure App Service for Linux and an Azure Container Registry (ACR) as well as support for SSH authentication to GitHub and VSTS Git repositories. While you are configuring Continuous Delivery for a containerized solution you can target an existing App Service on Linux and ACR or opt to create new ones.

When configuring continuous delivery for a containerized solution you can target an existing App Service on Linux and ACR

When you opt to create a new ACR, you can edit the new Container Registry details to change its name, resource group and location.

Edit New Container Registry

As you configure Continuous Delivery, the dialog will now recognize solutions under source control in VSTS repositories that only accept authentication over SSH and populate the dialog with repository details and list of available remote branches in that repository.

Please keep the feedback coming!

Thank you to everyone who has reached out and shared feedback and ideas so far. We’re always looking for feedback on where to focus on our efforts. There’s a team alias vsdevops@microsoft.com where you can reach out to the team and others in the community sharing ideas on this topic.

Ahmed Metwally, Senior PM, Visual Studio
@cd4vs

Ahmed is a Program Manager on the Visual Studio Platform team focused on improving team collaboration and application lifecycle management integration.

Visual Studio 2017 Version 15.6 Preview 2 and Visual Studio for Mac Version 7.4 Preview

$
0
0

We’re excited to start the new year off with great updates to the Visual Studio 2017 15.6 Preview for both Windows and Mac, and we hope that you will install and use it, and then tell us what you think. If you’re on a Windows machine, you can either install it from here or, if you already have it installed, click on the notification you’ll receive in the product informing you that the update is available. If you’re on a Mac, switch to the Visual Studio for Mac Beta updater channel to try out the new preview features.

This second preview builds upon the first preview of Visual Studio 2017 version 15.6 and contains new features, bug fixes, and other enhancements that address your feedback. We’re also releasing a new Visual Studio for Mac version 7.4 Preview, available in the Beta channel of the updater.

While this post shares the top highlights in this Preview, you can view the complete list of new features and details on how to enable them in the Visual Studio 2017 version 15.6 Preview release notes. For Mac users, the Visual Studio for Mac Preview release notes contain more details on what’s new for you. We appreciate your early adoption and feedback as it helps us ship the most high-quality tools to everyone in the Visual Studio community. Thank you for engaging in Visual Studio previews!

Performance

We continued our efforts to improve solution load performance, and in this Preview, we specifically focused on scenarios when the project has already been opened on the machine. We optimized our use of the design time build cache and parallelized the way project data is loaded, which enables Visual Studio to leverage disk and CPU more efficiently. Our lab measurements of this change show that large C# and Visual Basic solutions will “warm” load twice as fast as before. If you have a large solution project, we know you’ll appreciate this feature.

Productivity

When you’re in the flow of editing code, we know it’s the little details that often help make you more productive. One such detail: want to quickly duplicate a line of code without losing the contents of your paste buffer? Now you can, with duplicate line (Ctrl+E,V).

We’ve added the ability to navigate to decompiled sources. When enabled, invoking Go To Definition or Peek Definition on any referenced type or member will show its definition with reconstructed method bodies via ILSpy decompilation.

Decompiled

Diagnostics

The CPU Usage Tool, when used during post-mortem profiling with the ALT-F2 Performance Profiler, now displays logical call stacks for asynchronous code (aka ‘Async Call Stack Stitching’). This means that asynchronous code running on behalf of a parent function or Task will appear as a child in the Call Tree and Caller/Callee views. This view makes it easier to navigate asynchronous code and understand its performance characteristics.

CPUUsage Call Stack Stitching

C++ Development

C++17 Standards Conformance: We’ve also made further progress toward implementing the C++17 Standard Library, including APIs such as stable_sort, partition, inline vector::emplace_back in parallel, and <memory_resource>.

Open Folder improvements: Missing include files are now automatically discovered for C++ Open Folder if they exist under the workspace root, even if they are not explicitly added to the include path. Debug options are now available for Embedded ARM GCC support – right click your binary, choose Debug and Launch Settings, and then select C/C++ Debug microcontroller.

C++ IntelliSense in Open Folder & CMake: IntelliSense errors for inactive configurations will now be shown as purple squiggles in the editor (the number of configurations to process is configurable in Tools > Options):

Intellisense

CMake improvements: CTest, Google Test, and Boost.Test tests in CMake projects are automatically discovered and listed in the Test Explorer. If you have the Google Test adapter or the Boost.Test adapter, after you build, you will have an even more granular view of your tests:

Tests

Templates: We’ve included Boost.Test item templates and support for the Boost dynamic library.

C++ Code Analysis enhancements: We’ve added 5 new checks enforcing rules around integer overflow and additional rules from the C++ Core Guidelines, along with a C++ Core Checker extension to detect use of indirections with a lifetime that is out of scope. Additionally, the “Run Code Analysis” command no longer runs code generation, which speeds up analysis runs. We’ve also added support for running single file Code Analysis (or on your selection of files from the Solution Explorer) and have cleaned up the Build and Analyze menus.

Code Analysis

Azure Development

With this Preview, Visual Studio now supports configuring continuous delivery for solutions with ASP.NET Core projects and Docker support targeting Azure Web App for Containers. We also added support for new source control providers. You can now configure Continuous Delivery for your solution if it is under TFVC source control on VSTS or used SSH authentication for Git repositories on GitHub or VSTS. Read more about these features on this post about Continuous Delivery Tools for Visual Studio.

Test Explorer

Hierarchy View: The Test Explorer in Visual Studio now has a hierarchy view that organizes your tests by Project, Namespace, and then Class. This feature not only makes navigating through your tests much easier, but also gives better feedback on tests at a glance. Refer to the release notes for details on how to enable this view and what type of test information you’ll now be able to see. Adding a hierarchy view to the Test Explorer has been at the top of many wish lists and we are excited to hear feedback on the design and how it affects your workflow.

Test Heirarchy

Real time test discovery is a new Visual Studio feature that uses a Roslyn analyzer to discover tests and populate the test explorer in real time without requiring you to build your managed project. This feature was introduced in Visual Studio 2017 15.5 behind a feature flag, and in this Preview is now on by default. This feature not only makes test discovery significantly faster, but it also keeps the test explorer in sync with code changes such as adding or removing tests. Note that unlike Hierarchy View feature described above which is available for all types of projects, the automatic test discovery feature is only available for C# and Visual Basic projects.

Xamarin

Xamarin.Android: Android 8.1 Oreo is the latest version of Android available from Google. Android 8.1 Oreo offers many new features of interest to Xamarin.Android developers. These features include Android Go, Neural Networks API, Autofill Framework updates, SharedMemory API, and many more. These APIs are available to Xamarin.Android apps when you use Xamarin.Android 8.2 and later.

Visual Studio Tools for Xamarin:

Building iOS apps with Visual Studio on Windows just got even easier. This release adds a brand-new feature called macOS environment provisioning. Rather than installing and updating a Mac build machine manually, just connect to the Mac and we will handle the heavy lifting of setup, all from Windows.

You can also now deploy your iOS apps over the network with Wi-Fi debugging – no cables required, on both Windows and Mac. Just make sure you pair a wireless device with Xcode first.

The Xamarin Live Player enables developers to continuously deploy, test, and debug their apps using just Visual Studio and an iOS or Android device. Visual Studio 2017 version 15.5 added support to enable developers to preview real-time XAML changes directly in the Android emulator without requiring a recompile or redeploy. This release brings this functionality to the Remoted iOS Simulator for Windows.

Try it out today!

If you’re not familiar with Visual Studio Previews, take a moment to read the Visual Studio 2017 Release Rhythm. Remember that Visual Studio 2017 Previews can be installed side-by-side with other versions of Visual Studio and other installs of Visual Studio 2017 without adversely affecting either your machine or your productivity. Previews provide an opportunity for you to receive fixes faster and try out upcoming functionality before it becomes mainstream. Similarly, the Previews enable the Visual Studio Engineering team to validate usage, incorporate suggestions, and detect flaws earlier in the development process. We are highly responsive to feedback coming in through the Previews and look forward to hearing from you.

Please install the Visual Studio Preview today, exercise your favorite workloads, and tell us what you think. If you’re on a Mac, switch to the Visual Studio for Mac Beta updater channel to try out the new preview features. You can report issues to us via the Report a Problem tool in Visual Studio or you can share a suggestion on UserVoice. You’ll be able to track your issues in the Visual Studio Developer Community where you can ask questions and find answers. You can also engage with us and other Visual Studio developers through our Visual Studio conversation in the Gitter community (requires GitHub account).

Christine Ruana, Principal Program Manager, Visual Studio

Christine is on the Visual Studio release engineering team and is responsible for making Visual Studio releases available to our customers around the world.

Debugging an embedded ARM device in Visual Studio

$
0
0

We introduced support for ARM GCC cross compilation in Visual Studio 2017 in the 15.5 release. With 15.6 Preview 2, we are adding support for debugging. This overview of debugging capabilities follows from the setup for getting started ARM cross compilation and will be integrated there as an addendum.

First, it is important to ensure your output has debugging symbols. In the case of the GCC projects exported from the ARM online compiler, they do not. To add them, edit the makefile under the tools and flags section and add the -g flag for the GCC and G++ commands like the below.

CC      = 'arm-none-eabi-gcc' '-g' ...
CPP     = 'arm-none-eabi-g++' '-g' ...

Now after you have built your binary and flashed the device, right click on the binary output and select Debug and Launch Settings.

In the dialog that pops up select C/C++ Debug microcontroller (gdbserver).

This will create a launch.vs.json that has many options expressed that are relevant for embedded debugging. There are many ways to debug these kinds of devices so what you fill in here will be specific to your board, the hardware debugger and its associated software that provides a gdbserver interface. We are providing as many defaults and hints as we can to help you. In this preview some of the environment variables emitted are not working yet, you will need to substitute these with the values needed.

  • ${workspaceRootFolderName}, your folder name
  • ${env.gccpath}, your VS installation path followed by Linuxgcc_armbin
  • ${debugInfo.linuxNatvisPath}, path to a Natvis file if you have one. This is fine to remove as it is for specific scenarios.

I will walk through configuring this with the ST Nucleo-F411RE using OpenOCD. The process is similar for most boards.

First, change the program name in the output to point to your .elf file.

"program": "${workspaceRoot}\BUILD\Nucleo_blink_led.elf",

Change the miDebuggerPath to point to the full path to arm-none-eabi-gdb.exe.

"miDebuggerPath": "C:\Program Files (x86)\Microsoft Visual Studio\Internal\Enterprise\Linux\gcc_arm\bin\arm-none-eabi-gdb.exe",

In the “setupCommands”, you can remove the documentation link section (leaving it is not harmful). Change the symbol load to point to your .elf file.

"text": "-file-exec-and-symbols Nucleo_blink_led.elf",

You can execute additional commands to get your board into a proper state for debugging, often you need to halt and then reset the board at the beginning of a session. To do so add those command as part of the setup commands array as follows.

{
"text": "monitor reset halt",
"ignoreFailures": true
},
{
"text": "monitor reset init",
"ignoreFailures": true
}

Make sure the miDebuggerServerAddress matches the location your hardware debugger will provide. This is the default for OpenOCD.

"miDebuggerServerAddress": "localhost:3333",

If you want to launch your hardware interface yourself manually you can omit these lines. If you want VS to start the software to interface with your hardware debugger this is an example for launching OpenOCD with a config file. You should check this command by running it manually to make sure you have the correct config file and that the text used to validate the server has started is correct.

"debugServerPath": "D:\openocd-0.10.0\bin-x64\openocd.exe",
"debugServerArgs": "-f d:/openocd-0.10.0/scripts/board/st_nucleo_f4.cfg",
"serverStarted": "Info : stm32f4x.cpu: hardware has 6 breakpoints, 4 watchpoints",

Now with our configuration done use F5 to start debugging your embedded ARM application on your device from Visual Studio.

What’s next

Download the Visual Studio 2017 Preview, install the Linux C++ Workload, select the option for Embedded and IoT Development and give it a try with your projects.

We’re actively working on additional support for embedded scenarios. Your feedback here is very important to us. We look forward to hearing from you and seeing the things you make.

The best way to reach us is via our GitHub hosted issue list, directly via mail at vcpplinux-support@microsoft.com or find me on Twitter @robotdad.

Now Available: Offer Add-on Subscriptions with Automated Recurring Billing in Your UWP Apps

$
0
0

Today we are extremely excited to announce that subscription add-ons are available to all UWP developers. You can use subscriptions to sell digital products in your app with automated recurring billing while giving your customers a seamless purchase experience. One thing to keep in mind is that the Store fee for recurring billed subscriptions differs from other business models in Microsoft Store. For any add-on subscriptions in apps (but not games), you receive 85% of the subscription price, minus applicable taxes. For game add-on subscriptions, you receive 70% of the subscription price, minus applicable taxes. Please read the Microsoft Store App Developer Agreement for further details on Store Fees and other terms relating to subscriptions.

Creating a subscription add-on

To enable the purchase of subscription add-ons in your app, your project must target Windows 10 Anniversary Edition (10.0; Build 14393) or a later release in Visual Studio (this corresponds to Windows 10, version 1607), and it must use the APIs in the Windows.Services.Store namespace to implement the in-app purchase experience instead of the Windows.ApplicationModel.Store namespace. For more information about the differences between these namespaces, see In-app purchases and trials.

1) Create an add-on submission for your subscription in the Dev Center dashboard and publish the submission.

  • When offering subscription add-ons to your customers, you can choose to offer a subscription period of 1 month, 3 months, 6 months, 1 year or 2 years. You can also add a free trial period of 1 week or 1 month so your customers can try out the add-on before they commit to purchasing.

2) In your app, use APIs in the Services.Store namespace to determine whether the current user has already acquired your subscription add-on and then offer it for sale as an in-app purchase.

3) Test the in-app purchase implementation of your subscription in your app. You’ll need to download your app once from the Store to your development device to use its license for testing.

4) Create and publish an app submission that includes your updated app package, including your tested code.

For a complete overview of add-on subscriptions and how to implement them into your UWP app, please visit our documentation.

Customer management

Customers can manage their purchased subscriptions from the services & subscriptions page for their Microsoft account. Here they’ll find all the subscriptions they have acquired, with options to cancel a subscription or change the form of payment associated with a subscription.

Offering add-on subscriptions can be a great monetization strategy for your apps and games. As you go through the implementation process, please provide us with any feedback via the Feedback link in the upper right corner of the Dev Center dashboard.

The post Now Available: Offer Add-on Subscriptions with Automated Recurring Billing in Your UWP Apps appeared first on Building Apps for Windows.

IntelliSense Enhancements for C++ Open Folder and CMake

$
0
0

Today’s preview of Visual Studio 2017 version 15.6 Preview 2 includes two IntelliSense improvements to streamline code editing for C++ Open Folder and CMake. We added a new type of IntelliSense squiggle to C++ Open Folder and CMake to streamline cross-platform development.  We also now support a new heuristic and wildcard syntax to the include path for C++ Open Folder.

If you are new to CMake or Open Folder in Visual Studio, check out how to get started with CMake or other C++ projects.

Cross-Platform IntelliSense Squiggles

If you do cross-platform development in Visual Studio with CMake or C++ Open Folder you already know that by defining multiple configurations you get high-fidelity IntelliSense for each of the platforms that you’re targeting.  As you switch between these configurations you will immediately see red squiggles for any code that is unsupported or otherwise invalid for that platform.

In the latest preview, you might notice a new kind of IntelliSense squiggle:

Purple IntelliSense Squiggles

These purple squiggles indicate that while the code is valid for the currently selected configuration (in this picture, targeting a remote Linux machine), the line would cause an error for other configurations.  In the example above, the usleep function is not available when targeting Windows.  This IntelliSense feature will give you an early heads-up that you need to introduce platform-specific implementation.

By default, Visual Studio will check up to four configurations defined in either CppProperties.json for C++ Open Folder or CMakeSettings.json for CMake.  One thing to keep in mind with CMake, however, is that you will need to generate the cache for a configuration at least once for it to be considered by the IntelliSense engine.  This can easily be done by selecting that configuration in the dropdown to the left of the “start debugging” button.

This feature can be turned on and off under the advanced C++ options page:

IntelliSense for Inactive Platform Options

Note: These options also apply to the purple squiggles in MSBuild based shared code projects.  C++ shared code projects can be used to share code between UWP and other platforms such as iOS and Android and between Windows and Linux.

Include Path Wildcards for Open Folder

Until today, when you opened a folder in Visual Studio, all include paths had to be manually configured in CppProperties.json.  What this meant in practice was that many codebases would see IntelliSense errors due to missing headers even when those headers were readily available in the codebase itself.

The latest preview of Visual Studio automatically adds all folders under the workspace root to the include path to streamline the detection of header files.  It does this by adding newly introduced wildcard syntax to the default include path:

"includePath": ["${workspaceRoot}/**"]

This behavior is driven by the CppProperties.json file just like the rest of C++ IntelliSense for Open Folder.  As such, opting out of this new behavior is as simple as removing the new wildcard from CppProperties.json.  Keep in mind, though, if you generated a CppPropertie.json file prior to today’s preview, you will need to manually add the syntax above to take advantage of this new behavior.

For example, the heuristic can be enabled and disabled by adding or removing line 10 to the snippet below:

{
  "configurations": [
    {
      "inheritEnvironments": [
        "msvc_x64"
      ],
      "name": "windows-x64",
      "includePath": [
        "${env.INCLUDE}",
        "${workspaceRoot}/**"
      ],
      "defines": [
        "WIN32", "UNICODE", "_UNICODE"
      ],
      "intelliSenseMode": "windows-msvc-x64"
    }
  ]
}

While this new wildcard syntax can be used to recursively include folders other than the workspace root as well, there are a few caveats to keep in mind.  Today, only the IntelliSense include path (which is set with “includePath” in the example above) supports this feature.  For instance, wildcards will not be expanded in custom variables.  You should also use care when including large folders, especially if they contain ambiguously named headers.  It is possible to resolve ambiguously named headers by adding explicit paths earlier in the include path lookup.

Send Us Feedback

We would love to hear about how these features are working for you.  As always, we welcome your feedback.  Feel free to send any comments through email at visualcpp@microsoft.com, through Twitter @visualc, or Facebook at Microsoft Visual Cpp.

If you encounter other problems with Visual Studio 2017 please let us know via Report a Problem, which is available in both the installer and the IDE itself.


CMake Support in Visual Studio – Test Explorer Integration, CMake 3.10

$
0
0

We are excited to announce new CMake features in Visual Studio 2017 version 15.6 Preview 2.  In the latest preview, we have improved CTest’s integration with the IDE, including rich support for the Google and Boost unit testing frameworks.

If you are new to CMake in Visual Studio, check out how to get started.

CTest in the Test Explorer with Google Test and Boost.Test Support

One of the more frequent pieces of feedback we have received since adding basic support for CTest has been Test Explorer integration.  I am excited to announce that CTest is fully integrated into the IDE in the latest Visual Studio preview:

CTest Integration in Test Explorer

Normally, each individual CTest in your CMake project will have an entry in the Test Explorer.  If you take a close look at the screenshot above, however, you may notice that tests are broken out even further.  If your project leverages the Google Test or Boost.Test frameworks in conjunction with CTest, individual tests will be listed in the Test Explorer.

Rich support for Google Test and Boost.Test requires the corresponding test adapters to be installed.  The Google and Boost Test Adapters are now included by Visual Studio and will be installed by default with the C++ workload.  However, you may need to install them manually if you are upgrading an existing installation of Visual Studio.  For more information, check out how to install the Test Adapters for Google Test and Boost.Test.  Test Explorer integration for CTest is still available without these adapters but it is limited in granularity to individual CTests.

All of Visual Studio’s testing features now work with CTest.  In addition to viewing and running CTests from the Test Explorer, you can debug them and calculate their code coverage.  If you use the Google Test or Boost.Test unit testing frameworks, you will also get detailed information about failed tests including stack traces:

Test Explorer CTest Details

If your tests seem to be missing from the Test Explorer, make sure you have built the targets that contain them.  Your tests should be automatically detected once the build is complete.

CMake Tools Upgraded to 3.10

In our effort to make sure you have access to the latest features of CMake, we have upgraded the version of CMake that ships with Visual Studio from 3.9 to 3.10.  You can find the full lists of enhancements in the CMake 3.10 release notes.

Send Us Feedback

Your feedback is a critical part of ensuring that we can deliver the best CMake experience.  We would love to know how Visual Studio 2017 Preview is working for you.  If you have any feedback specific to CMake Tools, please reach out to cmake@microsoft.com.  For general issues please Report a Problem.

Boost.Test Unit Testing: Dynamic Library support and New Item Template

$
0
0

If you’re just getting started and want to learn more about C++ Unit Testing, check out our guide.

We are excited to announce that, in addition to Boost.Test static library support, Visual Studio 2017 15.6 Preview 2 now offers Boost.Test dynamic library support and a Boost.Test item template. This means it is now easier than ever to incorporate Boost.Test unit tests into your Visual Studio projects.

Boost.Test Dynamic Library

If you are already using the Boost.Test dynamic library, your unit tests will be supported immediately. If you don’t already have Boost.Test on your machine, the simplest method for acquiring the Boost.Test dynamic library is via vcpkg.

Using vcpkg, simply run the following commands to install Boost.Test and then make it available to all your VS projects. We only need to install the Boost.Test portion of Boost, but if you would like to acquire the entirety of Boost, just replace “boost-test” with “boost”.

 vcpkg install boost-test
vcpkg integrate install 

That’s it. You can now seamlessly write, discover, and run unit tests using the Boost.Test framework in Visual Studio. If you don’t prefer the dynamic library, please reference this guide to using the Boost static library.

Boost.Test Item Template

Once you have Boost.Test integrated with Visual Studio, we’ve added an item template so you can quickly add unit tests to your project. To do so, Right-click the project and then select Add > New Item… > Visual C++ > Test > Boost.Test

This automatically creates a .cpp file with some placeholder tests that will be automatically colored. After building your project, you can manage your tests in the Test Explorer window. The item template uses the single-header variant of Boost.Test, but you can modify the path to use the standalone library variant. Feel free to learn more about the variants of Boost.Test.

Talk to Us

We are always working to give you the best development experiences possible. Let us know what you would like to see next. If you come across any issues, please file them on the Test Adapter for Boost.Test GitHub.

C++ Static Analysis Improvements for Visual Studio 2017 15.6 Preview 2

$
0
0

We’ve made a few changes to the C++ static analysis feature that should make it faster and easier to use. The behavior has changed slightly, and the menus have been moved around a bit, but we think that the new experience is faster and more consistent. Let’s take a quick look at the changes.

Single File Analysis

Developers tend to focus on a few files at a time when working on code. To make it easier to get analysis results for the files you’re editing, you can now run code analysis on a single file. This lets you get without having to rebuild the entire project. We think this will be especially useful when fixing analysis warnings because it makes it convenient to check and recheck a file. After analysis runs, all analysis warnings for the file will appear in the error list.

Screenshot of single file analysis.

New build menu item to run C++ code analysis on a single file.

 

Screenshot showing single file analysis results.

Code Analysis results for a single file.

If you have a few files you want to check, you can also select multiple files in the Solution Explorer and run code analysis on only those files.

Screenshot showing the code analysis menu for multiple selected files.

Multiple files selected in the Solution Explorer can be analyzed at once.

More Consistent Menus

To make the code analysis menus easier to find, we’ve made them more consistent with their “Build” counterparts. In previous versions, you would find the menu to run code analysis on a project under the “Project Only” menu. Now the menus to start analysis on a solution, project, or file are located near their “Build X” counterpart on the “Build” menu. On the Solution Explorer context menus, look for the “Analyze” menu on the solution, project, and file nodes of the tree.

Build Menu

Screenshot showing the location of new analysis menus on the top Build menu.

New build menu locations for starting solution, project, and per-file code analysis.

Context Menus

Screenshot showing new Solution Explorer context menus for starting analysis.

New Solution Explorer context menus for running solution, project or per-file code analysis.

Analyze Only

We’ve heard from developers that running code analysis takes too long. In previous versions, running code analysis required a full build and link before analysis would run. Now when you run code analysis, we no longer generate code or link. This dramatically reduces analysis run time.

One side effect is that you will no longer see some build warnings during analysis runs. You will get build warnings during builds, and code analysis warnings during analysis runs. If you prefer to see build and analysis warnings at the same time, check the “Enable Code Analysis on Build” box in the project properties and rebuild your project.

Screenshot showing how to enable Code Analysis on Build.

Enable Code Analysis on Build to get build and analysis results at the same time.

C++ Core Guidelines Checker

C++ Core Check is currently not enabled by default, so if you want to try out the new single-file analysis experience with C++ Core Check, the extension must first be enabled on the project.

Screenshot showing C++ Core Check extension enabled for a project.

The C++ Core Check extension has to be enabled per-project if you want the C++ Core Check results when you run code analysis.

Wrap Up

These are just a few simple tweaks to improve the C++ code analysis experience. Download the latest Visual Studio preview and give them a try. We hope you will find it easier to use on your projects and that the tools help you write safer, more modern C++.

As always, we welcome your feedback. Feel free to send any comments through e-mail at visualcpp@microsoft.com, through Twitter @visualc, or Facebook at Microsoft Visual Cpp.

If you encounter other problems with MSVC in VS 2017 please let us know via the Report a Problem option, either from the installer or the Visual Studio IDE itself. For suggestions, let us know through UserVoice. Thank you!

Happy coding.

R jumps to 8th position in TIOBE language rankings

$
0
0

The R language surged to 8th place in the 2017 TIOBE language rankings, up 8 places from a year before. Fellow data science language language Python also saw an increase in rankings, taking the 4th spot (one ahead of its January 2016 ranking).

TIOBEtable

(Click the table for the current top 20 rankings.) TIOBE ranks programming languages according to their search engine rankings, and R has been steadily climbing since the rankings began:

Tiobe-2017

You can find the current TIOBE language rankings, updated monthly, at the link below.

TIOBE: TIOBE Index 

Sharing of Deployment Groups across projects

$
0
0
Last year we released Deployment Groups in Public Preview during the May 2017 timeframe, which enabled customers to deploy software to their IaaS machines.  One of the big pieces of feedback we received was that this only partially addressed the scenario of customers sharing their IaaS machines (deployment targets) across multiple applications. For example, this... Read More
Viewing all 10804 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>