blob: 94dbb89b5ea77d287374ebf329a7639006966118 [file] [log] [blame]
// Copyright 2018 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
library fuchsia.overnet;
using fuchsia.overnet.protocol;
[Discoverable]
protocol Overnet {
ListPeers(uint64 last_seen_version) -> (uint64 version, vector<Peer> peers);
// TODO(ctiller): remove this, and move to something that looks way more like an explicit registry.
RegisterService(string service_name, ServiceProvider provider);
ConnectToService(fuchsia.overnet.protocol.NodeId node,
string service_name, handle<channel> chan);
};
protocol ServiceProvider {
ConnectToService(handle<channel> chan);
};
struct Peer {
fuchsia.overnet.protocol.NodeId id;
bool is_self;
fuchsia.overnet.protocol.PeerDescription description;
};