├── content
├── screenshots
│ └── main.png
└── images
│ ├── diol-main-banner.png
│ └── diol-main-image.png
├── source
└── Diol
│ ├── src
│ ├── applications
│ │ ├── DiolVSIX
│ │ │ ├── Resources
│ │ │ │ ├── logo.png
│ │ │ │ ├── DiolCommandLogo.png
│ │ │ │ └── DiolToolWindowCommand.png
│ │ │ ├── publishManifest.json
│ │ │ ├── DiolToolWindowControl.xaml.cs
│ │ │ ├── Services
│ │ │ │ ├── VsProcessProvider.cs
│ │ │ │ └── VsApplicationStateService.cs
│ │ │ ├── Properties
│ │ │ │ └── AssemblyInfo.cs
│ │ │ ├── DiolToolWindow.cs
│ │ │ ├── DiolVSIXPackage1.cs
│ │ │ ├── source.extension.vsixmanifest
│ │ │ ├── DiolBootstrapper.cs
│ │ │ ├── DiolVSIXPackage.cs
│ │ │ ├── DiolToolWindowCommand.cs
│ │ │ └── DiolVSIXPackage.vsct
│ │ ├── DiolBackendService
│ │ │ ├── appsettings.Development.json
│ │ │ ├── Properties
│ │ │ │ └── launchSettings.json
│ │ │ ├── Pages
│ │ │ │ └── Index.cshtml.cs
│ │ │ ├── Program.cs
│ │ │ ├── appsettings.json
│ │ │ ├── ReadME.md
│ │ │ ├── setup.ps1
│ │ │ └── DiolBackendService.csproj
│ │ ├── Diol.applications.WpfClient
│ │ │ ├── App.xaml
│ │ │ ├── AssemblyInfo.cs
│ │ │ ├── Diol.applications.WpfClient.csproj
│ │ │ └── App.xaml.cs
│ │ └── Diol.applications.ConsoleClient
│ │ │ ├── Diol.applications.ConsoleClient.csproj
│ │ │ ├── ConsoleConsumer.cs
│ │ │ └── Program.cs
│ ├── Diol.Share
│ │ ├── Diol.Share.csproj
│ │ ├── Consumers
│ │ │ └── IConsumer.cs
│ │ ├── Utils
│ │ │ └── DotnetProcessInfo.cs
│ │ ├── Services
│ │ │ ├── IApplicationStateService.cs
│ │ │ ├── IProcessProvider.cs
│ │ │ ├── DotnetProcessesService.cs
│ │ │ └── SqlQueryService.cs
│ │ └── Features
│ │ │ ├── EntityFrameworks
│ │ │ ├── CommandExecutedDto.cs
│ │ │ ├── ConnectionOpeningDto.cs
│ │ │ └── CommandExecutingDto.cs
│ │ │ ├── Httpclients
│ │ │ ├── RequestPipelineResponseHeaderDto.cs
│ │ │ ├── RequestPipelineRequestHeaderDto.cs
│ │ │ ├── RequestPipelineEndDto.cs
│ │ │ └── RequestPipelineStartDto.cs
│ │ │ ├── Aspnetcores
│ │ │ ├── RequestBodyDto.cs
│ │ │ ├── ResponseBodyDto.cs
│ │ │ ├── ResponseLogDto.cs
│ │ │ └── RequestLogDto.cs
│ │ │ └── BaseDto.cs
│ ├── Diol.Aspnet
│ │ ├── Pages
│ │ │ └── Index.cshtml.cs
│ │ ├── Diol.Aspnet.csproj
│ │ ├── ServiceCollection.cs
│ │ ├── Hubs
│ │ │ └── LogsHub.cs
│ │ ├── Consumers
│ │ │ └── SignalRConsumer.cs
│ │ └── BackgroundWorkers
│ │ │ └── LogsBackgroundWorker.cs
│ ├── Diol.Core
│ │ ├── Diol.Core.csproj
│ │ ├── DiagnosticClients
│ │ │ ├── EventPipeHelper.cs
│ │ │ ├── EventPipeEventSourceBuilder.cs
│ │ │ └── EventPipeEventSourceWrapper.cs
│ │ ├── TraceEventProcessors
│ │ │ ├── EventPublisherUnsubscriber.cs
│ │ │ ├── TraceEventRouterUnsubscriber.cs
│ │ │ ├── IProcessor.cs
│ │ │ ├── EventPublisher.cs
│ │ │ ├── ProcessorFactory.cs
│ │ │ └── TraceEventRouter.cs
│ │ ├── Utils
│ │ │ └── Utilities.cs
│ │ ├── ServiceCollectionExtensions.cs
│ │ └── Features
│ │ │ └── BaseProcessor.cs
│ └── Diol.Wpf.Core
│ │ ├── Views
│ │ ├── MainWindow.xaml
│ │ ├── MainWindow.xaml.cs
│ │ ├── HttpMaster.xaml.cs
│ │ ├── AspnetMaster.xaml.cs
│ │ ├── MainComponent.xaml.cs
│ │ ├── DiolComponent.xaml.cs
│ │ ├── AspnetComponent.xaml.cs
│ │ ├── DiagnosticsView.xaml.cs
│ │ ├── HttpComponent.xaml.cs
│ │ ├── WelcomeComponent.xaml.cs
│ │ ├── EntityFrameworkDetail.xaml.cs
│ │ ├── EntityFrameworkMaster.xaml.cs
│ │ ├── EntityFrameworkComponent.xaml.cs
│ │ ├── DiolComponent.xaml
│ │ ├── HttpComponent.xaml
│ │ ├── AspnetComponent.xaml
│ │ ├── EntityFrameworkComponent.xaml
│ │ ├── HttpDetail.xaml.cs
│ │ ├── AspnetDetail.xaml.cs
│ │ ├── DiagnosticsView.xaml
│ │ ├── WelcomeComponent.xaml
│ │ ├── MainComponent.xaml
│ │ ├── EntityFrameworkDetail.xaml
│ │ ├── EntityFrameworkMaster.xaml
│ │ ├── AspnetMaster.xaml
│ │ └── HttpMaster.xaml
│ │ ├── Diol.Wpf.Core.csproj
│ │ ├── Features
│ │ ├── Https
│ │ │ ├── HttpEvents.cs
│ │ │ ├── HttpModel.cs
│ │ │ └── HttpViewModel.cs
│ │ ├── Aspnetcores
│ │ │ ├── AspnetEvents.cs
│ │ │ ├── AspnetcoreModel.cs
│ │ │ ├── AspnetViewModel.cs
│ │ │ └── AspnetService.cs
│ │ ├── EntityFrameworks
│ │ │ ├── EntityFrameworkModel.cs
│ │ │ ├── EntityFrameworkEvents.cs
│ │ │ └── EntityFrameworkViewModel.cs
│ │ └── Shared
│ │ │ └── SharedEvents.cs
│ │ ├── Services
│ │ ├── RelayCommand.cs
│ │ ├── DiolBuilder.cs
│ │ ├── DiolExecutor.cs
│ │ ├── LocalStore.cs
│ │ └── WpfConsumer.cs
│ │ ├── MainModule.cs
│ │ └── ViewModels
│ │ ├── DiagnosticsViewModel.cs
│ │ ├── HttpComponentViewModel.cs
│ │ ├── AspnetComponentViewModel.cs
│ │ ├── EntityFrameworkComponentViewModel.cs
│ │ ├── WelcomeComponentViewModel.cs
│ │ ├── AspnetMasterViewModel.cs
│ │ ├── HttpMasterViewModel.cs
│ │ ├── EntityFrameworkDetailViewModel.cs
│ │ └── EntityFrameworkMasterViewModel.cs
│ └── tests
│ └── unit
│ └── Diol.Tests.Units
│ ├── Diol.Tests.Units.csproj
│ └── SqlQueryParserTest.cs
├── .github
├── ISSUE_TEMPLATE
│ ├── feature_request.md
│ └── bug_report.md
└── workflows
│ ├── main_build.yml
│ ├── main_vsix_release.yml
│ └── main_diolbackendservice_release.yml
├── SECURITY.md
├── LICENSE
├── CONTRIBUTING.md
├── README.md
└── Promotions
└── 1_DiolReleased.md
/content/screenshots/main.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Dotnet-IO-logger/core/HEAD/content/screenshots/main.png
--------------------------------------------------------------------------------
/content/images/diol-main-banner.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Dotnet-IO-logger/core/HEAD/content/images/diol-main-banner.png
--------------------------------------------------------------------------------
/content/images/diol-main-image.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Dotnet-IO-logger/core/HEAD/content/images/diol-main-image.png
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolVSIX/Resources/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Dotnet-IO-logger/core/HEAD/source/Diol/src/applications/DiolVSIX/Resources/logo.png
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolVSIX/Resources/DiolCommandLogo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Dotnet-IO-logger/core/HEAD/source/Diol/src/applications/DiolVSIX/Resources/DiolCommandLogo.png
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolVSIX/Resources/DiolToolWindowCommand.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Dotnet-IO-logger/core/HEAD/source/Diol/src/applications/DiolVSIX/Resources/DiolToolWindowCommand.png
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolBackendService/appsettings.Development.json:
--------------------------------------------------------------------------------
1 | {
2 | "Logging": {
3 | "LogLevel": {
4 | "Default": "Information",
5 | "Microsoft.Hosting.Lifetime": "Information"
6 | }
7 | }
8 | }
9 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Diol.Share.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | netstandard2.0
5 | AnyCPU;x86
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Aspnet/Pages/Index.cshtml.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.AspNetCore.Mvc;
2 | using Microsoft.AspNetCore.Mvc.RazorPages;
3 |
4 | namespace Diol.Aspnet.Pages
5 | {
6 | public class IndexModel : PageModel
7 | {
8 | public void OnGet()
9 | {
10 | }
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolBackendService/Properties/launchSettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "profiles": {
3 | "DiolBackendService": {
4 | "commandName": "Project",
5 | "dotnetRunMessages": true,
6 | "environmentVariables": {
7 | "DOTNET_ENVIRONMENT": "Development"
8 | }
9 | }
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolBackendService/Pages/Index.cshtml.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.AspNetCore.Mvc;
2 | using Microsoft.AspNetCore.Mvc.RazorPages;
3 |
4 | namespace DiolBackendService.Pages
5 | {
6 | public class IndexModel : PageModel
7 | {
8 | public void OnGet()
9 | {
10 | }
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Consumers/IConsumer.cs:
--------------------------------------------------------------------------------
1 | using Diol.Share.Features;
2 | using System;
3 |
4 | namespace Diol.Share.Consumers
5 | {
6 | ///
7 | /// Represents a consumer that observes and consumes objects.
8 | ///
9 | public interface IConsumer : IObserver
10 | {
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolBackendService/Program.cs:
--------------------------------------------------------------------------------
1 | using Diol.Aspnet;
2 |
3 | var builder = WebApplication.CreateBuilder(args);
4 |
5 | builder.Services.AddRazorPages();
6 |
7 | builder.Services.AddDiolWeb();
8 | builder.Services.AddRazorPages();
9 |
10 | var app = builder.Build();
11 |
12 | app.MapRazorPages();
13 | app.UseDiol();
14 |
15 | app.Run();
16 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolBackendService/appsettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "Logging": {
3 | "LogLevel": {
4 | "Default": "Information",
5 | "Microsoft.Hosting.Lifetime": "Information"
6 | },
7 | "EventLog": {
8 | "LogLevel": {
9 | "Default": "Information",
10 | "Microsoft.Hosting.Lifetime": "Information"
11 | }
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/Diol.applications.WpfClient/App.xaml:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolVSIX/publishManifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "http://json.schemastore.org/vsix-publish",
3 | "categories": ["Coding", "Other", "Testing"],
4 | "identity": {
5 | "internalName": "Diol"
6 | },
7 | "overview": "Readme.md",
8 | "priceCategory": "free",
9 | "publisher": "Diol-devs",
10 | "private": false,
11 | "qna": true,
12 | "repo": "https://github.com/Dotnet-IO-logger/core"
13 | }
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Utils/DotnetProcessInfo.cs:
--------------------------------------------------------------------------------
1 | namespace Diol.Share.Utils
2 | {
3 | ///
4 | /// Represents information about a dotnet process.
5 | ///
6 | public class DotnetProcessInfo
7 | {
8 | ///
9 | /// Gets or sets the ID of the dotnet process.
10 | ///
11 | public int Id { get; set; }
12 |
13 | ///
14 | /// Gets or sets the name of the dotnet process.
15 | ///
16 | public string Name { get; set; }
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Core/Diol.Core.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | netstandard2.0
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Services/IApplicationStateService.cs:
--------------------------------------------------------------------------------
1 | namespace Diol.Share.Services
2 | {
3 | ///
4 | /// Represents an interface for subscribing to application state changes.
5 | ///
6 | public interface IApplicationStateService
7 | {
8 | ///
9 | /// Subscribes to application state changes.
10 | ///
11 | void Subscribe();
12 | }
13 |
14 | public class LocalApplicationStateService : IApplicationStateService
15 | {
16 | ///
17 | public void Subscribe()
18 | {
19 | }
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolVSIX/DiolToolWindowControl.xaml.cs:
--------------------------------------------------------------------------------
1 | using System.Diagnostics.CodeAnalysis;
2 | using System.Windows;
3 | using System.Windows.Controls;
4 |
5 | namespace DiolVSIX
6 | {
7 | ///
8 | /// Interaction logic for DiolToolWindowControl.
9 | ///
10 | public partial class DiolToolWindowControl : UserControl
11 | {
12 | ///
13 | /// Initializes a new instance of the class.
14 | ///
15 | public DiolToolWindowControl()
16 | {
17 | this.InitializeComponent();
18 | }
19 | }
20 | }
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/MainWindow.xaml:
--------------------------------------------------------------------------------
1 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/Diol.applications.WpfClient/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Windows;
2 |
3 | [assembly: ThemeInfo(
4 | ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
5 | //(used if a resource is not found in the page,
6 | // or application resource dictionaries)
7 | ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
8 | //(used if a resource is not found in the page,
9 | // app, or any theme specific resource dictionaries)
10 | )]
11 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/feature_request.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Feature request
3 | about: Suggest an idea for this project
4 | title: ''
5 | labels: ''
6 | assignees: ''
7 |
8 | ---
9 |
10 | **Is your feature request related to a problem? Please describe.**
11 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12 |
13 | **Describe the solution you'd like**
14 | A clear and concise description of what you want to happen.
15 |
16 | **Describe alternatives you've considered**
17 | A clear and concise description of any alternative solutions or features you've considered.
18 |
19 | **Additional context**
20 | Add any other context or screenshots about the feature request here.
21 |
--------------------------------------------------------------------------------
/SECURITY.md:
--------------------------------------------------------------------------------
1 | # Security Policy
2 |
3 | ## Supported Versions
4 |
5 | Use this section to tell people about which versions of your project are
6 | currently being supported with security updates.
7 |
8 | | Version | Supported |
9 | | ------- | ------------------ |
10 | | 5.1.x | :white_check_mark: |
11 | | 5.0.x | :x: |
12 | | 4.0.x | :white_check_mark: |
13 | | < 4.0 | :x: |
14 |
15 | ## Reporting a Vulnerability
16 |
17 | Use this section to tell people how to report a vulnerability.
18 |
19 | Tell them where to go, how often they can expect to get an update on a
20 | reported vulnerability, what to expect if the vulnerability is accepted or
21 | declined, etc.
22 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Diol.Wpf.Core.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net462
5 | true
6 | AnyCPU;x86
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Aspnet/Diol.Aspnet.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net6.0
5 | enable
6 | enable
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Features/Https/HttpEvents.cs:
--------------------------------------------------------------------------------
1 | using Prism.Events;
2 |
3 | namespace Diol.Wpf.Core.Features.Https
4 | {
5 | ///
6 | /// Event raised when an HTTP request is started.
7 | ///
8 | public class HttpRequestStartedEvent : PubSubEvent
9 | {
10 | }
11 |
12 | ///
13 | /// Event raised when an HTTP request is ended.
14 | ///
15 | public class HttpRequestEndedEvent : PubSubEvent
16 | {
17 | }
18 |
19 | ///
20 | /// Event raised when an HTTP item is selected.
21 | ///
22 | public class HttpItemSelectedEvent : PubSubEvent
23 | {
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolBackendService/ReadME.md:
--------------------------------------------------------------------------------
1 | # DiolBackendService
2 |
3 | ## How to install
4 |
5 | 1. Open a `setupAsDotnetTool.ps1` script
6 | 2. Just run step by step the commands in the script
7 |
8 | ### I want to update the version
9 |
10 | In this case please just uninstall the previous version (the command you can find the the ps1 script) and then install the new version (the command you can find in the ps1 script)
11 |
12 | ```powershell
13 |
14 | ## How to use
15 |
16 | After installation you can run the following command to start the server:
17 |
18 | ```powershell
19 | DiolBackendService --urls=http://localhost:62023/
20 | ```
21 |
22 | `---urls` can be changed to any port you want to run the server on.
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Features/EntityFrameworks/CommandExecutedDto.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace Diol.Share.Features.EntityFrameworks
4 | {
5 | ///
6 | /// Represents a data transfer object for a command executed event in Entity Framework.
7 | ///
8 | public class CommandExecutedDto : BaseDto
9 | {
10 | ///
11 | public override string CategoryName => "EntityFramework";
12 |
13 | ///
14 | public override string EventName => nameof(CommandExecutedDto);
15 |
16 | ///
17 | /// Gets or sets the elapsed time in milliseconds for the command execution.
18 | ///
19 | public TimeSpan ElapsedMilliseconds { get; set; }
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Features/Httpclients/RequestPipelineResponseHeaderDto.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 |
3 | namespace Diol.Share.Features.Httpclients
4 | {
5 | ///
6 | /// Represents the response header data for the request pipeline.
7 | ///
8 | public class RequestPipelineResponseHeaderDto : BaseDto
9 | {
10 | ///
11 | public override string CategoryName => "HttpClient";
12 |
13 | ///
14 | public override string EventName => nameof(RequestPipelineResponseHeaderDto);
15 |
16 | ///
17 | /// Gets or sets the dictionary of headers.
18 | ///
19 | public Dictionary Headers { get; set; }
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Features/Httpclients/RequestPipelineRequestHeaderDto.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 |
3 | namespace Diol.Share.Features.Httpclients
4 | {
5 | ///
6 | /// Represents the data transfer object for the request headers in the request pipeline.
7 | ///
8 | public class RequestPipelineRequestHeaderDto : BaseDto
9 | {
10 | ///
11 | public override string CategoryName => "HttpClient";
12 |
13 | ///
14 | public override string EventName => nameof(RequestPipelineRequestHeaderDto);
15 |
16 | ///
17 | /// Gets or sets the dictionary of headers.
18 | ///
19 | public Dictionary Headers { get; set; }
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Features/Aspnetcores/AspnetEvents.cs:
--------------------------------------------------------------------------------
1 | using Prism.Events;
2 |
3 | namespace Diol.Wpf.Core.Features.Aspnetcores
4 | {
5 | ///
6 | /// Represents an event that is raised when an ASP.NET request starts.
7 | ///
8 | public class AspnetRequestStartedEvent : PubSubEvent
9 | {
10 | }
11 |
12 | ///
13 | /// Represents an event that is raised when an ASP.NET request ends.
14 | ///
15 | public class AspnetRequestEndedEvent : PubSubEvent
16 | {
17 | }
18 |
19 | ///
20 | /// Represents an event that is raised when an item is selected in ASP.NET.
21 | ///
22 | public class AspnetItemSelectedEvent : PubSubEvent
23 | {
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/Diol.applications.WpfClient/Diol.applications.WpfClient.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | WinExe
5 | net6.0-windows
6 | enable
7 | true
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/MainWindow.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for MainWindow.xaml
20 | ///
21 | public partial class MainWindow : Window
22 | {
23 | public MainWindow()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/HttpMaster.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for HttpMaster.xaml
20 | ///
21 | public partial class HttpMaster : UserControl
22 | {
23 | public HttpMaster()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/AspnetMaster.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for AspnetMaster.xaml
20 | ///
21 | public partial class AspnetMaster : UserControl
22 | {
23 | public AspnetMaster()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/MainComponent.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for MainView.xaml
20 | ///
21 | public partial class MainComponent : UserControl
22 | {
23 | public MainComponent()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/DiolComponent.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for DiolComponent.xaml
20 | ///
21 | public partial class DiolComponent : UserControl
22 | {
23 | public DiolComponent()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/AspnetComponent.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for AspnetMasterDetail.xaml
20 | ///
21 | public partial class AspnetComponent : UserControl
22 | {
23 | public AspnetComponent()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/DiagnosticsView.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for DiagnosticsView.xaml
20 | ///
21 | public partial class DiagnosticsView : UserControl
22 | {
23 | public DiagnosticsView()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/HttpComponent.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for HttpMasterDetailView.xaml
20 | ///
21 | public partial class HttpComponent : UserControl
22 | {
23 | public HttpComponent()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/WelcomeComponent.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for WelcomeComponent.xaml
20 | ///
21 | public partial class WelcomeComponent : UserControl
22 | {
23 | public WelcomeComponent()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/EntityFrameworkDetail.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for EntityFrameworkDetail.xaml
20 | ///
21 | public partial class EntityFrameworkDetail : UserControl
22 | {
23 | public EntityFrameworkDetail()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/EntityFrameworkMaster.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for EntityFrameworkMaster.xaml
20 | ///
21 | public partial class EntityFrameworkMaster : UserControl
22 | {
23 | public EntityFrameworkMaster()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/EntityFrameworkComponent.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Diol.Wpf.Core.Views
17 | {
18 | ///
19 | /// Interaction logic for EntityFrameworkComponent.xaml
20 | ///
21 | public partial class EntityFrameworkComponent : UserControl
22 | {
23 | public EntityFrameworkComponent()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Views/DiolComponent.xaml:
--------------------------------------------------------------------------------
1 |
13 |
15 |
16 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/Diol.applications.ConsoleClient/Diol.applications.ConsoleClient.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | Exe
4 | net6.0
5 | enable
6 | enable
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolBackendService/setup.ps1:
--------------------------------------------------------------------------------
1 | # if you want to use the tool from nuget feed:
2 | dotnet nuget add source --username [GithubUserName] --password [YourApiKey] --name github-diol https://nuget.pkg.github.com/Dotnet-IO-logger/index.json
3 | dotnet tool install -g DiolBackendService
4 |
5 | # if you want to install it locally
6 | $packageName = 'DiolBackendService'
7 | $packagePath = '.\distrib\release\DiolBackendService'
8 |
9 | $csProjPath = '.\DiolBackendService.csproj'
10 |
11 | # delete old one
12 | dotnet tool uninstall -g $packageName
13 |
14 | # pack and install
15 | dotnet build -c Release
16 | dotnet pack $csProjPath --output $packagePath
17 | dotnet tool install --global --add-source $packagePath $packageName
18 |
19 | # how to use
20 | # from a terminal please run the following command:
21 | # DiolBackendService --urls=http://localhost:62023/
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Features/EntityFrameworks/ConnectionOpeningDto.cs:
--------------------------------------------------------------------------------
1 | namespace Diol.Share.Features.EntityFrameworks
2 | {
3 | ///
4 | /// Represents a data transfer object for opening a connection in Entity Framework.
5 | ///
6 | public class ConnectionOpeningDto : BaseDto
7 | {
8 | ///
9 | public override string CategoryName => "EntityFramework";
10 |
11 | ///
12 | public override string EventName => nameof(ConnectionOpeningDto);
13 |
14 | ///
15 | /// Gets or sets the name of the database.
16 | ///
17 | public string Database { get; set; }
18 |
19 | ///
20 | /// Gets or sets the name of the server.
21 | ///
22 | public string Server { get; set; }
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Features/Aspnetcores/RequestBodyDto.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 |
3 | namespace Diol.Share.Features.Aspnetcores
4 | {
5 | ///
6 | /// Represents the request body data transfer object.
7 | ///
8 | public class RequestBodyDto : BaseDto
9 | {
10 | ///
11 | public override string CategoryName => "AspnetCore";
12 |
13 | ///
14 | public override string EventName => nameof(RequestBodyDto);
15 |
16 | ///
17 | /// Gets or sets the body as a string.
18 | ///
19 | public string BodyAsString { get; set; }
20 |
21 | ///
22 | /// Gets or sets the metadata dictionary.
23 | ///
24 | public Dictionary Metadata { get; set; }
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Features/Aspnetcores/ResponseBodyDto.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 |
3 | namespace Diol.Share.Features.Aspnetcores
4 | {
5 | ///
6 | /// Represents the response body data transfer object.
7 | ///
8 | public class ResponseBodyDto : BaseDto
9 | {
10 | ///
11 | public override string CategoryName => "AspnetCore";
12 |
13 | ///
14 | public override string EventName => nameof(ResponseBodyDto);
15 |
16 | ///
17 | /// Gets or sets the body as a string.
18 | ///
19 | public string BodyAsString { get; set; }
20 |
21 | ///
22 | /// Gets or sets the metadata dictionary.
23 | ///
24 | public Dictionary Metadata { get; set; }
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/DiolVSIX/Services/VsProcessProvider.cs:
--------------------------------------------------------------------------------
1 | using Diol.Share.Services;
2 | using EnvDTE80;
3 |
4 | namespace DiolVSIX.Services
5 | {
6 | public class VsProcessProvider : IProcessProvider
7 | {
8 | private readonly DTE2 dte;
9 |
10 | public VsProcessProvider(DTE2 dte)
11 | {
12 | this.dte = dte;
13 | }
14 |
15 | public int? GetProcessId()
16 | {
17 | int? result = null;
18 |
19 | if (dte.Debugger?.DebuggedProcesses?.Count > 0)
20 | {
21 | foreach (EnvDTE.Process process in this.dte.Debugger.DebuggedProcesses)
22 | {
23 | result = process.ProcessID;
24 | break;
25 | }
26 |
27 | return result;
28 | }
29 |
30 | return result;
31 | }
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Share/Features/Httpclients/RequestPipelineEndDto.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace Diol.Share.Features.Httpclients
4 | {
5 | ///
6 | /// Represents the data transfer object for the end of a request pipeline.
7 | ///
8 | public class RequestPipelineEndDto : BaseDto
9 | {
10 | ///
11 | public override string CategoryName => "HttpClient";
12 |
13 | ///
14 | public override string EventName => nameof(RequestPipelineEndDto);
15 |
16 | ///
17 | /// Gets or sets the status code of the request.
18 | ///
19 | public int StatusCode { get; set; }
20 |
21 | ///
22 | /// Gets or sets the elapsed time in milliseconds for the request.
23 | ///
24 | public TimeSpan ElapsedMilliseconds { get; set; }
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/source/Diol/src/applications/Diol.applications.ConsoleClient/ConsoleConsumer.cs:
--------------------------------------------------------------------------------
1 | using Diol.Share.Consumers;
2 | using Diol.Share.Features;
3 | using System.Diagnostics;
4 | using System.Text.Json;
5 |
6 | namespace Diol.applications.ConsoleClient
7 | {
8 | public class ConsoleConsumer : IConsumer
9 | {
10 | public void OnCompleted()
11 | {
12 | // IObservable has finished.
13 | Debug.WriteLine($"{nameof(ConsoleConsumer)} | {nameof(OnCompleted)}");
14 | }
15 |
16 | public void OnError(Exception error)
17 | {
18 | // write log
19 | Debug.WriteLine($"{nameof(ConsoleConsumer)} | {nameof(OnError)}");
20 | }
21 |
22 | public void OnNext(BaseDto value)
23 | {
24 | Console.WriteLine();
25 | Console.WriteLine(JsonSerializer.Serialize(value, value.GetType()));
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/source/Diol/tests/unit/Diol.Tests.Units/Diol.Tests.Units.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net8.0
5 | enable
6 | enable
7 |
8 | false
9 | true
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/source/Diol/src/Diol.Wpf.Core/Services/RelayCommand.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Windows.Input;
3 |
4 | namespace Diol.Wpf.Core.Services
5 | {
6 | public class RelayCommand : ICommand
7 | {
8 | private readonly Action