# Google Cloud Debugger v2 API - Class Controller2.Controller2Base (3.2.0)

<button class="button button-with-icon cloud-select-dropdown__button " aria-haspopup="true">Version latest</button>

- [3.2.0 (latest)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2.Controller2.Controller2Base)
- [3.1.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/3.1.0/Google.Cloud.Debugger.V2.Controller2.Controller2Base)
- [3.0.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/3.0.0/Google.Cloud.Debugger.V2.Controller2.Controller2Base)
- [2.4.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/2.4.0/Google.Cloud.Debugger.V2.Controller2.Controller2Base)
- [2.3.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/2.3.0/Google.Cloud.Debugger.V2.Controller2.Controller2Base)

    [BindServiceMethod(typeof(Controller2), "BindService")]
    public abstract class Controller2.Controller2Base

Reference documentation and code samples for the Google Cloud Debugger v2 API class Controller2.Controller2Base.

Base class for server-side implementations of Controller2

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> Controller2.Controller2Base

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.MemberwiseClone()](https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.Debugger.V2](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2)

## Assembly

Google.Cloud.Debugger.V2.dll

## Methods

### ListActiveBreakpoints(ListActiveBreakpointsRequest, ServerCallContext)

    public virtual Task<ListActiveBreakpointsResponse> ListActiveBreakpoints(ListActiveBreakpointsRequest request, ServerCallContext context)

Returns the list of all active breakpoints for the debuggee.

The breakpoint specification (`location`, `condition`, and `expressions`
fields) is semantically immutable, although the field values may
change. For example, an agent may update the location line number
to reflect the actual line where the breakpoint was set, but this
doesn't change the breakpoint semantics.

This means that an agent does not need to check if a breakpoint has changed
when it encounters the same breakpoint on a successive call.
Moreover, an agent should remember the breakpoints that are completed
until the controller removes them from the active list to avoid
setting those breakpoints again.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2.ListActiveBreakpointsRequest` The request received from the client. |
| `context` | `https://github.com/grpc/grpc-dotnet/blob/6e6bcb5a10588f4853cf32aab0195346768a2a36/src/Grpc.Core.Api/ServerCallContext.cs` The context of the server-side call handler being invoked. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2.ListActiveBreakpointsResponse` | The response to send back to the client (wrapped by a task). |

### RegisterDebuggee(RegisterDebuggeeRequest, ServerCallContext)

    public virtual Task<RegisterDebuggeeResponse> RegisterDebuggee(RegisterDebuggeeRequest request, ServerCallContext context)

Registers the debuggee with the controller service.

All agents attached to the same application must call this method with
exactly the same request content to get back the same stable `debuggee_id`.
Agents should call this method again whenever `google.rpc.Code.NOT_FOUND`
is returned from any controller method.

This protocol allows the controller service to disable debuggees, recover
from data loss, or change the `debuggee_id` format. Agents must handle
`debuggee_id` value changing upon re-registration.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2.RegisterDebuggeeRequest` The request received from the client. |
| `context` | `https://github.com/grpc/grpc-dotnet/blob/6e6bcb5a10588f4853cf32aab0195346768a2a36/src/Grpc.Core.Api/ServerCallContext.cs` The context of the server-side call handler being invoked. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2.RegisterDebuggeeResponse` | The response to send back to the client (wrapped by a task). |

### UpdateActiveBreakpoint(UpdateActiveBreakpointRequest, ServerCallContext)

    public virtual Task<UpdateActiveBreakpointResponse> UpdateActiveBreakpoint(UpdateActiveBreakpointRequest request, ServerCallContext context)

Updates the breakpoint state or mutable fields.
The entire Breakpoint message must be sent back to the controller service.

Updates to active breakpoint fields are only allowed if the new value
does not change the breakpoint specification. Updates to the `location`,
`condition` and `expressions` fields should not alter the breakpoint
semantics. These may only make changes such as canonicalizing a value
or snapping the location to the correct line of code.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2.UpdateActiveBreakpointRequest` The request received from the client. |
| `context` | `https://github.com/grpc/grpc-dotnet/blob/6e6bcb5a10588f4853cf32aab0195346768a2a36/src/Grpc.Core.Api/ServerCallContext.cs` The context of the server-side call handler being invoked. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Debugger.V2/latest/Google.Cloud.Debugger.V2.UpdateActiveBreakpointResponse` | The response to send back to the client (wrapped by a task). |