0

First of all I would like to apologize in case that the question should not be here, because it is not about coding only.

The problem is the following:

I have a solution with several projects, all of those projects but one (a client), run on dapr inside of docker containers. The client is meant to be an outside project that connects to one of the dockerized project, does something and retrieves something back, very simple, for testing purposes, but it is not a test project (there is no xunit, mocking services...).

Ideally, I would like to fire the client and the rest of the projects at the same time. Question is how do I do that?

This is what I have tried:

1.- I have tried to set up the solution to start on multiple projects, marking the client and the other one that I need, and maybe other ones. It gives me the following issues:

  • The port is not the one that should be (5005, instead 22794), this is very minor, but when I try to test the api I get dapr errors, because it is not running.
  • I tried to set up the docker project as a starting project, this was done on the solution explorer window, right click and selecting option. The problem is that the client does not run.
  • Finally, I have tried to set up in the properties of the solution the docker project and the client to run at the same time but the problem is that I don't see the docker project, but the projects that run individually on docker (doing this will go to first problem). So there is no way on solution properties to set up the docker project and the client to run at the same time.
  • The workaround that I have found is to open another VStudio with the client project and fire it from there, and run in the other window the docker project. The problem with this is that it can get very messy if I need to change code in the client, so I would like to fire the docker project and the client from the same VStudio,

how do I do that? or better, can this be done?

Jack J Jun
  • 5,633
  • 1
  • 9
  • 27
Iria
  • 43
  • 1
  • 10
  • are you using .NET - would this help you: https://dev.to/kaiwalter/simple-approach-to-run-and-debug-multiple-net-dapr-projects-w-o-docker-289k – Kai Walter Mar 17 '21 at 16:42
  • yes, .NET 5.0 but I think this is more a tooling question rather than a coding one – Iria Mar 18 '21 at 22:58
  • You can run the client using `dapr run —app-id dotnet run` either from command prompt or the visual studio terminal – Vivek Nuna Dec 10 '21 at 15:24

0 Answers0