microsoft / vs-dapr

View, manage, and diagnose Dapr services within Visual Studio.
https://dapr.io
MIT License
21 stars 2 forks source link

Visual Studio Dapr Extension

Visual Studio Marketplace Version Visual Studio Marketplace Last Updated

The Dapr extension for Visual Studio enables you to view, manage, diagnose, and debug Dapr services within Visual Studio.

Changelog

Version Update
0.1.109.3 (Preview) Added tool window to monitor Dapr actor instances and state (preview).
0.1.102.1 (Preview) Initial marketplace release with Dapr run file orchestration, debugging, and Dapr tool window to monitor running Dapr applications and state store state (preview).

Prerequisites

Installation

The extension can be downloaded and installed from the Visual Studio Marketplace.

Use

Starting with the Dapr Extension

  1. Open your solution in Visual Studio

  2. Right-click the solution in Solution Explorer and select Add > Dapr Run File

    Screenshot of Visual Studio Solution Explorer with the solution context menu open and showing the Add > Dapr Run File command.

  3. You can now edit and add to the created dapr.yaml file

    Screenshot of Visual Studio with the generated Dapr run file open in the YAML editor.

Preview Features

Enabling the Dapr run file debugging experience was the initial concern for the extension but there is considerable other feature work in progress. While not available by default, this work in progress can be enabled via feature flags.

Enabling Dapr Preview Features

  1. Install the Feature Flags extension, which allows you to view and modify Visual Studio feature flags
  2. Open Tools > Options > Feature Flags
  3. Enable the desired Dapr feature flags
    • Dapr.ToolWindows.Dapr: Enables the new Dapr tool window

[!WARNING] Preview features are not extensively tested, may not meet your quality standards, and are intended for evaluation and feedback purposes. Use at your own risk.

Dapr Tool Window

The Dapr tool window displays information about running Dapr applications, such as its loaded components and various ports, and will be familiar to users of the VS Code Dapr extension. It can be opened via the View > Other Windows > Dapr menu command.

For applications using a "default" state store (i.e. Redis), you can also open an additional Dapr State Stores tool window to show just the state for that application.

Screenshot of Visual Studio with the Dapr and Dapr State Stores tool windows open.

For applications using Dapr actors, you can also open an additional Dapr Actors tool window to show just the state for individual actor instances.

Screenshot of Visual Studio with the Dapr and Dapr Actors tool windows open.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.

When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

Trademarks

This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow Microsoft's Trademark & Brand Guidelines. Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies.