mirror of
https://github.com/fluencelabs/registry.git
synced 2025-06-28 07:11:36 +00:00
routing API: set relay_id as HOST_PEER_ID (#90)
This commit is contained in:
committed by
GitHub
parent
ef0ee12ca3
commit
164b353be8
@ -22,7 +22,6 @@ let local: Node[] = [
|
||||
|
||||
async function main() {
|
||||
// connect to the Fluence network
|
||||
|
||||
await Fluence.start({ connectTo: krasnodar[0] });
|
||||
console.log("%s", await timestamp_sec());
|
||||
console.log(
|
||||
@ -32,11 +31,10 @@ async function main() {
|
||||
);
|
||||
let label = "myLabel";
|
||||
let value = "myValue";
|
||||
console.log("Will create route with label: ", label);
|
||||
console.log("Will create route with label:", label);
|
||||
// create route (if not exists) and register on it
|
||||
let relay = Fluence.getStatus().relayPeerId;
|
||||
let route_id = await createRouteAndRegisterBlocking(
|
||||
label, value, relay, null,
|
||||
label, value, null,
|
||||
(s) => console.log(`node ${s} saved the record`),
|
||||
5
|
||||
);
|
||||
|
Reference in New Issue
Block a user