microsoft / mindaro

Bridge to Kubernetes - for Visual Studio and Visual Studio Code
MIT License
307 stars 106 forks source link

Effective workflow with Bridge to Kubernetes #148

Open mgj opened 3 years ago

mgj commented 3 years ago

Is your feature request related to a problem? Please describe. I really want to love the Visual Studio (and Code) Bridge to Kubernetes plugin/extension, it has the potential to become essential in my development efforts but the workflow is... I dont know. It's not obvious to me how you can use it effectively.

Describe the solution you'd like I'm seeing a couple of issues:

Describe alternatives you've considered I would very much like to use the Visual Studio extension but I'm forced to use the Visual Studio Code extension because only it allows me to connect to my local minikube cluster. The Visual Studio extension tries to load from a "Local Kube Config" but this fails with "Something went wrong." - See screenshot here: https://i.imgur.com/D3Cgq4O.png

Additional context

pragyamehta commented 3 years ago

Hi @mgj Thanks for opening this issue!

> You cannot attach to a running process within your kluster, you can only forward traffic to a new process - This is not a problem for me, but it's limiting

What you are asking for would require the ability of a remote debugger. This is not an approach we take with Bridge to Kubernetes and we do not plan to support this scenario.

> Because you can only forward traffic to a new process running locally, you currently do NOT get either environment variables NOR is your local process able to connect to other microservices within the cluster (DNS lookup fails) - This is the most troublesome issue for me, it severely limits my ability to debug issues

Please refer to the below link to setup the product for more advanced features. You can setup environment variables of your choice, access specific services and download volume mounts locally as well. Once you start debugging, we do make all services in the same namespace available to you during the debugging session, and if there are others you want to setup access for, you can do so by using the KubernetesLocalProcessConfig.yaml file https://docs.microsoft.com/en-us/visualstudio/containers/configure-bridge-to-kubernetes?view=vs-2019

> I would very much like to use the Visual Studio extension but I'm forced to use the Visual Studio Code extension because only it allows me to connect to my local minikube cluster. The Visual Studio extension tries to load from a "Local Kube Config" but this fails with "Something went wrong." - See screenshot here: https://i.imgur.com/D3Cgq4O.png

We do support debugging a local minikube cluster using the latest VS bits. If you are facing problem with the same, please send us logs from the following locations so that we can investigate:

wayne-o commented 3 years ago
2021-05-05T09:43:35.0391088Z | Library | TRACE | Pulling kubeconfig...\nOperation context: <json>{"clientRequestId":null,"correlationId":"257b6afc-8d8e-47d5-a6b1-d60258483d68:42fa2fa2129d:ede323dfb8c3","requestId":null,"userSubscriptionId":null,"startTime":"2021-05-05T09:43:34.9926487Z","userAgent":"LPK/2.1.20210411.1-5dda536c VisualStudio/16.8.31019.35","requestHttpMethod":null,"requestUri":null,"version":"1.0.20210408.1","requestHeaders":{},"loggingProperties":{"applicationName":"Library","deviceOperatingSystem":"Microsoft Windows 10.0.19042","framework":".NET Core 3.1.12","macAddressHash":"1c3e790aa64d59c8dcce72f6bf25f1e91690b878cd794b467f7392b62cf6e85a","processId":50888,"targetEnvironment":"Production"}}</json>
2021-05-05T09:43:35.3268355Z | Library | TRACE | Event: CloudProvider <json>{"properties":{"clusterFQDNDomain":"Local IP"},"metrics":null}</json>
2021-05-05T09:43:36.0041400Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListServicesInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-05T09:43:36.1901274Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListPodsInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-05T09:43:36.1958188Z | Library | TRACE | Detected headless service with selectors. Using selectors to look for endpoints...\nOperation context: <json>{"clientRequestId":null,"correlationId":"257b6afc-8d8e-47d5-a6b1-d60258483d68:42fa2fa2129d:3c24e3dc3e7c","requestId":null,"userSubscriptionId":null,"startTime":"2021-05-05T09:43:34.9926487Z","userAgent":"LPK/2.1.20210411.1-5dda536c VisualStudio/16.8.31019.35","requestHttpMethod":null,"requestUri":null,"version":"1.0.20210408.1","requestHeaders":{},"loggingProperties":{"applicationName":"Library","deviceOperatingSystem":"Microsoft Windows 10.0.19042","framework":".NET Core 3.1.12","macAddressHash":"1c3e790aa64d59c8dcce72f6bf25f1e91690b878cd794b467f7392b62cf6e85a","processId":50888,"targetEnvironment":"Production","isRoutingEnabled":false}}</json>
2021-05-05T09:43:36.2243330Z | Library | TRACE | Detected headless service with selectors. Using selectors to look for endpoints...
2021-05-05T09:43:36.2620409Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListEndpointsInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-05T09:43:36.2620485Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListEndpointsInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-05T09:43:36.2637957Z | Library | TRACE | Found 2 endpoint(s) matching headless service 'sonatribe-rabbitmq-headless'
2021-05-05T09:43:36.2639087Z | Library | TRACE | Found 2 endpoint(s) matching headless service 'sonatribe-pgsql-postgresql-headless'
2021-05-05T09:43:36.2783560Z | Library | TRACE | Event: KubernetesRemoteEnvironmentManager-GetReachableServices <json>{"properties":{"result":"Failed"},"metrics":{"durationInMs":880.0}}</json>
2021-05-05T09:43:36.2832956Z | Library | TRACE | Event: ConnectManagementClient-GetElevationRequests <json>{"properties":{"result":"Failed"},"metrics":{"durationInMs":909.0}}</json>
2021-05-05T09:43:36.2846259Z | Library | ERROR | Failed to get elevation requests.
2021-05-05T09:43:36.3269518Z | Library | ERROR | Logging handled exception: System.InvalidOperationException: {"ClassName":"System.InvalidOperationException","Message":"Collection was modified; enumeration operation may not execute.","Data":null,"InnerException":null,"HelpURL":null,"StackTraceString":"   at System.Collections.Generic.List`1.Enumerator.MoveNextRare()\r\n   at System.Collections.Generic.List`1.Enumerator.MoveNext()\r\n   at System.Linq.Enumerable.Any[TSource](IEnumerable`1 source, Func`2 predicate)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_1.<_CollectServicesToRouteAsync>b__1(V1Endpoints e)\r\n   at System.Collections.Generic.IEnumerableExtensions.ExecuteForEach[T](IEnumerable`1 items, Action`1 action, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_0.<<_CollectServicesToRouteAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.GetReachableServicesAsync(String namespaceName, ILocalProcessConfig localProcessConfig, IProgress`1 progress, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ConnectManagementClient.<>c__DisplayClass13_0.<<GetElevationRequestsAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ManagementClientExceptionStrategy.RunWithHandlingAsync[T](Func`1 func, FailureConfig failureConfig)","RemoteStackTraceString":null,"RemoteStackIndex":0,"ExceptionMethod":null,"HResult":-2146233079,"Source":"System.Private.CoreLib","WatsonBuckets":null}
2021-05-05T09:43:34.9083183Z | MindaroCli | TRACE | Event: Command.Start <json>{"properties":{"arguments":"prep-connect --namespace highstreetly-live --output json","isRoutingEnabled":"false"},"metrics":null}</json>\nOperation context: <json>{"clientRequestId":null,"correlationId":"257b6afc-8d8e-47d5-a6b1-d60258483d68:42fa2fa2129d","requestId":null,"userSubscriptionId":null,"startTime":"2021-05-05T09:43:34.6341661Z","userAgent":"LPK/2.1.20210411.1-5dda536c VisualStudio/16.8.31019.35","requestHttpMethod":null,"requestUri":null,"version":"1.0.20210408.1","requestHeaders":{},"loggingProperties":{"applicationName":"MindaroCli","deviceOperatingSystem":"Microsoft Windows 10.0.19042","framework":".NET Core 3.1.12","macAddressHash":"1c3e790aa64d59c8dcce72f6bf25f1e91690b878cd794b467f7392b62cf6e85a","processId":50888,"targetEnvironment":"Production","commandId":"42fa2fa2129d"}}</json>
2021-05-05T09:43:35.0128873Z | MindaroCli | TRACE | Running Microsoft.BridgeToKubernetes.Exe.Commands.Connect.PrepConnectCommand...
2021-05-05T09:43:35.0163287Z | MindaroCli | TRACE | Initializing progress reporter...
2021-05-05T09:43:36.3399954Z | MindaroCli | ERROR | Dependency: Prep Connect <json>{"target":null,"success":false,"duration":null,"properties":{"requestId":"null","clientRequestId":"null","correlationRequestId":"null"}}</json>
2021-05-05T09:43:36.8385759Z | MindaroCli | ERROR | An unexpected error occurred: 'Collection was modified; enumeration operation may not execute.'\n
2021-05-05T09:43:36.8392125Z | MindaroCli | ERROR | To see our active issues or file a bug report, please visit https://aka.ms/bridge-to-k8s-report.\n
2021-05-05T09:43:36.8397077Z | MindaroCli | ERROR | For diagnostic information, see logs at 'C:\Users\cloud\AppData\Local\Temp\Bridge To Kubernetes'.\n
2021-05-05T09:43:36.8459534Z | MindaroCli | ERROR | Logging handled exception: System.InvalidOperationException: {"ClassName":"System.InvalidOperationException","Message":"Collection was modified; enumeration operation may not execute.","Data":null,"InnerException":null,"HelpURL":null,"StackTraceString":"   at System.Collections.Generic.List`1.Enumerator.MoveNextRare()\r\n   at System.Collections.Generic.List`1.Enumerator.MoveNext()\r\n   at System.Linq.Enumerable.Any[TSource](IEnumerable`1 source, Func`2 predicate)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_1.<_CollectServicesToRouteAsync>b__1(V1Endpoints e)\r\n   at System.Collections.Generic.IEnumerableExtensions.ExecuteForEach[T](IEnumerable`1 items, Action`1 action, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_0.<<_CollectServicesToRouteAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.GetReachableServicesAsync(String namespaceName, ILocalProcessConfig localProcessConfig, IProgress`1 progress, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ConnectManagementClient.<>c__DisplayClass13_0.<<GetElevationRequestsAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ManagementClientExceptionStrategy.RunWithHandlingAsync[T](Func`1 func, FailureConfig failureConfig)\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ConnectManagementClient.GetElevationRequestsAsync(IProgress`1 progress, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Exe.Commands.Connect.PrepConnectCommand.ExecuteAsync()\r\n   at Microsoft.BridgeToKubernetes.Exe.CliApp.RunCommandAsync(String[] args, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Exe.CliApp.ExecuteAsync(String[] args, CancellationToken cancellationToken)","RemoteStackTraceString":null,"RemoteStackIndex":0,"ExceptionMethod":null,"HResult":-2146233079,"Source":"System.Private.CoreLib","WatsonBuckets":null}
2021-05-05T09:43:36.8487729Z | MindaroCli | TRACE | Event: Command.End <json>{"properties":{"arguments":"prep-connect --namespace highstreetly-live --output json","result":"Failed","failureReason":"Collection was modified; enumeration operation may not execute."},"metrics":{"duration":2013.0}}</json>
wayne-o commented 3 years ago
{
  "timestamp": "2021-05-05 10-43-37.651",
  "message": "Begin a connect session",
  "exception": {
    "type": "Microsoft.VisualStudio.Kubernetes.Debugging.RpcContracts.DscException",
    "message": "Something went wrong.",
    "stack": "   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.DscClient.<InvokeAsync>d__15`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.DscClient.<PrepConnectionAsync>d__17.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.Connect.ConnectService.<>c__DisplayClass9_0.<<GetElevationRequestsAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.RpcContracts.Telemetry.KubeConnectScopeBase`1.<ExecuteWithErrorHandlingAsync>d__27`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.Connect.ConnectService.<GetElevationRequestsAsync>d__9.MoveNext()",
    "code": -2146233088,
    "inner": {
      "type": "Microsoft.VisualStudio.Kubernetes.Debugging.RpcContracts.DscException",
      "message": "An unexpected error occurred: 'Collection was modified; enumeration operation may not execute.'\r\nTo see our active issues or file a bug report, please visit https://aka.ms/bridge-to-k8s-report.\r\nFor diagnostic information, see logs at 'C:\\Users\\cloud\\AppData\\Local\\Temp\\Bridge To Kubernetes'.\r\n",
      "stack": "   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.DscClient.<InvokeAsync>d__15`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)",
      "code": -2146233088,
      "inner": null
    }
  },
  "operationName": "ConnectionManagerService.ConnectAsync",
  "stage": "End",
  "elapsedTime": "00:00:05.5955093",
  "completionState": "Error"
}
{
  "timestamp": "2021-05-05 10-43-37.652",
  "message": "Query the debug targets for debug launch of Connect service",
  "exception": {
    "type": "Microsoft.VisualStudio.Kubernetes.Debugging.RpcContracts.DscException",
    "message": "Something went wrong.",
    "stack": "   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.DscClient.<InvokeAsync>d__15`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.DscClient.<PrepConnectionAsync>d__17.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.Connect.ConnectService.<>c__DisplayClass9_0.<<GetElevationRequestsAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.RpcContracts.Telemetry.KubeConnectScopeBase`1.<ExecuteWithErrorHandlingAsync>d__27`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.Connect.ConnectService.<GetElevationRequestsAsync>d__9.MoveNext()",
    "code": -2146233088,
    "inner": {
      "type": "Microsoft.VisualStudio.Kubernetes.Debugging.RpcContracts.DscException",
      "message": "An unexpected error occurred: 'Collection was modified; enumeration operation may not execute.'\r\nTo see our active issues or file a bug report, please visit https://aka.ms/bridge-to-k8s-report.\r\nFor diagnostic information, see logs at 'C:\\Users\\cloud\\AppData\\Local\\Temp\\Bridge To Kubernetes'.\r\n",
      "stack": "   at Microsoft.VisualStudio.Kubernetes.Debugging.ServiceHub.DscClient.<InvokeAsync>d__15`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)",
      "code": -2146233088,
      "inner": null
    }
  },
  "operationName": "AzureDevSpacesLocalDebugProfileLaunchTargetsProvider.QueryDebugTargetsForDebugLaunchAsync",
  "stage": "End",
  "elapsedTime": "00:00:05.6209023",
  "completionState": "Error"
}
wayne-o commented 3 years ago

it seems to only work directly after installing it - but now I have uninstalled and re-installed and it won't work at all

daniv-msft commented 3 years ago

Thank you for reporting this issue, and sorry you encounter it. From the logs you share, this seems to be the same issue as https://github.com/microsoft/mindaro/issues/169 Do you have any headless services deployed in your cluster?

We have released the fix for this in VS Code, but it's not yet released in Visual Studio. Would using VS Code be an acceptable workaround in the meantime?

mgj commented 3 years ago

Hi, thanks for the response. Sorry for not providing logs sooner. The KubernetesLocalProcessConfig.yaml link is very useful, thank you.

I think I'm seeing the same error as wayne-o . I do have headless services deployed in my cluster. Unfortunately using VS Code is not an option for me, i'll wait for the visual studio update

Logs

2021-05-08T11:36:06.5948772Z | Library | TRACE | Pulling kubeconfig...\nOperation context: <json>{"clientRequestId":null,"correlationId":"2fdc7720-d31a-4a1b-be41-90916651df5a:4e43bc2bfb22:0191675ab715","requestId":null,"userSubscriptionId":null,"startTime":"2021-05-08T11.36.06.5590738Z","userAgent":"LPK/2.1.20210411.1-5dda536c VisualStudio/16.9.31205.134","requestHttpMethod":null,"requestUri":null,"version":"1.0.20210408.1","requestHeaders":{},"loggingProperties":{"applicationName":"Library","deviceOperatingSystem":"Microsoft Windows 10.0.19041","framework":".NET Core 3.1.14","macAddressHash":"a97709168e78ad9727eb24fc00bdf3b0aa2007c2bd477de8c31220fd647b7cb9","processId":10484,"targetEnvironment":"Production"}}</json>
2021-05-08T11:36:06.7484086Z | Library | TRACE | Event: CloudProvider <json>{"properties":{"clusterFQDNDomain":"Remote IP"},"metrics":null}</json>
2021-05-08T11:36:07.0951340Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListServicesInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-08T11:36:07.1810051Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListPodsInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-08T11:36:07.1849037Z | Library | TRACE | Detected headless service with selectors. Using selectors to look for endpoints...\nOperation context: <json>{"clientRequestId":null,"correlationId":"2fdc7720-d31a-4a1b-be41-90916651df5a:4e43bc2bfb22:c9774bf45fb9","requestId":null,"userSubscriptionId":null,"startTime":"2021-05-08T11.36.06.5590738Z","userAgent":"LPK/2.1.20210411.1-5dda536c VisualStudio/16.9.31205.134","requestHttpMethod":null,"requestUri":null,"version":"1.0.20210408.1","requestHeaders":{},"loggingProperties":{"applicationName":"Library","deviceOperatingSystem":"Microsoft Windows 10.0.19041","framework":".NET Core 3.1.14","macAddressHash":"a97709168e78ad9727eb24fc00bdf3b0aa2007c2bd477de8c31220fd647b7cb9","processId":10484,"targetEnvironment":"Production","isRoutingEnabled":false}}</json>
2021-05-08T11:36:07.1965499Z | Library | TRACE | Detected headless service with selectors. Using selectors to look for endpoints...
2021-05-08T11:36:07.1967920Z | Library | TRACE | Detected headless service with selectors. Using selectors to look for endpoints...
2021-05-08T11:36:07.2060751Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListEndpointsInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-08T11:36:07.2060870Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListEndpointsInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-08T11:36:07.2060751Z | Library | TRACE | Dependency: Kubernetes <json>{"target":"ListEndpointsInNamespaceAsync","success":true,"duration":null,"properties":{}}</json>
2021-05-08T11:36:07.2070663Z | Library | TRACE | Found 2 endpoint(s) matching headless service 'myownapp-configuratordatasql-postgresql-headless'
2021-05-08T11:36:07.2070777Z | Library | TRACE | Found 2 endpoint(s) matching headless service 'myownapp-jobmanagerdatasql-postgresql-headless'
2021-05-08T11:36:07.2071220Z | Library | TRACE | Found 2 endpoint(s) matching headless service 'myownapp-klustermanagerdatasql-postgresql-headless'
2021-05-08T11:36:07.2166176Z | Library | TRACE | Event: KubernetesRemoteEnvironmentManager-GetReachableServices <json>{"properties":{"result":"Failed"},"metrics":{"durationInMs":411.0}}</json>
2021-05-08T11:36:07.2198045Z | Library | TRACE | Event: ConnectManagementClient-GetElevationRequests <json>{"properties":{"result":"Failed"},"metrics":{"durationInMs":432.0}}</json>
2021-05-08T11:36:07.2206064Z | Library | ERROR | Failed to get elevation requests.
2021-05-08T11:36:07.2399186Z | Library | ERROR | Logging handled exception: System.InvalidOperationException: {"ClassName":"System.InvalidOperationException","Message":"Collection was modified; enumeration operation may not execute.","Data":null,"InnerException":null,"HelpURL":null,"StackTraceString":"   at System.Collections.Generic.List`1.Enumerator.MoveNextRare()\r\n   at System.Collections.Generic.List`1.Enumerator.MoveNext()\r\n   at System.Linq.Enumerable.Any[TSource](IEnumerable`1 source, Func`2 predicate)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_1.<_CollectServicesToRouteAsync>b__1(V1Endpoints e)\r\n   at System.Collections.Generic.IEnumerableExtensions.ExecuteForEach[T](IEnumerable`1 items, Action`1 action, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_0.<<_CollectServicesToRouteAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.GetReachableServicesAsync(String namespaceName, ILocalProcessConfig localProcessConfig, IProgress`1 progress, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ConnectManagementClient.<>c__DisplayClass13_0.<<GetElevationRequestsAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ManagementClientExceptionStrategy.RunWithHandlingAsync[T](Func`1 func, FailureConfig failureConfig)","RemoteStackTraceString":null,"RemoteStackIndex":0,"ExceptionMethod":null,"HResult":-2146233079,"Source":"System.Private.CoreLib","WatsonBuckets":null}
2021-05-08T11:36:06.5093861Z | MindaroCli | TRACE | Event: Command.Start <json>{"properties":{"arguments":"prep-connect --namespace default --output json","isRoutingEnabled":"false"},"metrics":null}</json>\nOperation context: <json>{"clientRequestId":null,"correlationId":"2fdc7720-d31a-4a1b-be41-90916651df5a:4e43bc2bfb22","requestId":null,"userSubscriptionId":null,"startTime":"2021-05-08T11.36.06.3180578Z","userAgent":"LPK/2.1.20210411.1-5dda536c VisualStudio/16.9.31205.134","requestHttpMethod":null,"requestUri":null,"version":"1.0.20210408.1","requestHeaders":{},"loggingProperties":{"applicationName":"MindaroCli","deviceOperatingSystem":"Microsoft Windows 10.0.19041","framework":".NET Core 3.1.14","macAddressHash":"a97709168e78ad9727eb24fc00bdf3b0aa2007c2bd477de8c31220fd647b7cb9","processId":10484,"targetEnvironment":"Production","commandId":"4e43bc2bfb22"}}</json>
2021-05-08T11:36:06.5746103Z | MindaroCli | TRACE | Running Microsoft.BridgeToKubernetes.Exe.Commands.Connect.PrepConnectCommand...
2021-05-08T11:36:06.5774331Z | MindaroCli | TRACE | Initializing progress reporter...
2021-05-08T11:36:07.2487631Z | MindaroCli | ERROR | Dependency: Prep Connect <json>{"target":null,"success":false,"duration":null,"properties":{"requestId":"null","clientRequestId":"null","correlationRequestId":"null"}}</json>
2021-05-08T11:36:07.9841555Z | MindaroCli | ERROR | An unexpected error occurred: 'Collection was modified; enumeration operation may not execute.'\n
2021-05-08T11:36:07.9845315Z | MindaroCli | ERROR | To see our active issues or file a bug report, please visit https://aka.ms/bridge-to-k8s-report.\n
2021-05-08T11:36:07.9847990Z | MindaroCli | ERROR | For diagnostic information, see logs at 'C:\Users\mgj\AppData\Local\Temp\Bridge To Kubernetes'.\n
2021-05-08T11:36:07.9881234Z | MindaroCli | ERROR | Logging handled exception: System.InvalidOperationException: {"ClassName":"System.InvalidOperationException","Message":"Collection was modified; enumeration operation may not execute.","Data":null,"InnerException":null,"HelpURL":null,"StackTraceString":"   at System.Collections.Generic.List`1.Enumerator.MoveNextRare()\r\n   at System.Collections.Generic.List`1.Enumerator.MoveNext()\r\n   at System.Linq.Enumerable.Any[TSource](IEnumerable`1 source, Func`2 predicate)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_1.<_CollectServicesToRouteAsync>b__1(V1Endpoints e)\r\n   at System.Collections.Generic.IEnumerableExtensions.ExecuteForEach[T](IEnumerable`1 items, Action`1 action, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.<>c__DisplayClass31_0.<<_CollectServicesToRouteAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.Connect.KubernetesRemoteEnvironmentManager.GetReachableServicesAsync(String namespaceName, ILocalProcessConfig localProcessConfig, IProgress`1 progress, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ConnectManagementClient.<>c__DisplayClass13_0.<<GetElevationRequestsAsync>b__0>d.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ManagementClientExceptionStrategy.RunWithHandlingAsync[T](Func`1 func, FailureConfig failureConfig)\r\n   at Microsoft.BridgeToKubernetes.Library.ManagementClients.ConnectManagementClient.GetElevationRequestsAsync(IProgress`1 progress, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Exe.Commands.Connect.PrepConnectCommand.ExecuteAsync()\r\n   at Microsoft.BridgeToKubernetes.Exe.CliApp.RunCommandAsync(String[] args, CancellationToken cancellationToken)\r\n   at Microsoft.BridgeToKubernetes.Exe.CliApp.ExecuteAsync(String[] args, CancellationToken cancellationToken)","RemoteStackTraceString":null,"RemoteStackIndex":0,"ExceptionMethod":null,"HResult":-2146233079,"Source":"System.Private.CoreLib","WatsonBuckets":null}
2021-05-08T11:36:07.9894470Z | MindaroCli | TRACE | Event: Command.End <json>{"properties":{"arguments":"prep-connect --namespace default --output json","result":"Failed","failureReason":"Collection was modified; enumeration operation may not execute."},"metrics":{"duration":1534.0}}</json>