GRPC Core 0.10.0.0

- Main Page
- Data Structures
- Files

- File List
- Globals

All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Data Structures | Enumerations | Functions
channel_connectivity.c File Reference
`#include "src/core/surface/channel.h"`
`#include <grpc/support/alloc.h>`
`#include <grpc/support/log.h>`
`#include "src/core/channel/client_channel.h"`
`#include "src/core/iomgr/alarm.h"`
`#include "src/core/surface/completion_queue.h"`

## Data Structures
struct | state_watcher

## Enumerations
enum | callback_phase { WAITING, CALLING_BACK, CALLING_BACK_AND_FINISHED, CALLED_BACK }

## Functions
grpc_connectivity_state | grpc_channel_check_connectivity_state (grpc_channel *channel, int try_to_connect)
| Check the connectivity state of a channel. More...
void | grpc_channel_watch_connectivity_state (grpc_channel *channel, grpc_connectivity_state last_observed_state, gpr_timespec deadline, grpc_completion_queue *cq, void *tag)
| Watch for a change in connectivity state. More...

## Enumeration Type Documentation

enum callback_phase

Enumerator
WAITING |
CALLING_BACK |
CALLING_BACK_AND_FINISHED |
CALLED_BACK |

## Function Documentation

grpc_connectivity_state grpc_channel_check_connectivity_state | ( | grpc_channel * | channel,
|  | int | try_to_connect
| ) |  |

Check the connectivity state of a channel.

void grpc_channel_watch_connectivity_state | ( | grpc_channel * | channel,
|  | grpc_connectivity_state | last_observed_state,
|  | gpr_timespec | deadline,
|  | grpc_completion_queue * | cq,
|  | void * | tag
| ) |  |

Watch for a change in connectivity state.

Once the channel connectivity state is different from last_observed_state, tag will be enqueued on cq with success=1. If deadline expires BEFORE the state is changed, tag will be enqueued on cq with success=0.