Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
X
xxdk Examples
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
elixxir
xxdk Examples
Commits
bcf310a7
Commit
bcf310a7
authored
2 years ago
by
Jonah Husson
Browse files
Options
Downloads
Patches
Plain Diff
Update e2eClient readme
parent
3ddb17b2
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
e2eClient/README.md
+32
-0
32 additions, 0 deletions
e2eClient/README.md
e2eClient/main.go
+3
-3
3 additions, 3 deletions
e2eClient/main.go
with
35 additions
and
3 deletions
e2eClient/README.md
+
32
−
0
View file @
bcf310a7
...
...
@@ -25,3 +25,35 @@ example. In order to build a client which successfully sends a message through
the connection, we must first go over how to build and run a connection server.
### Building a Client
E2E clients communicate with each other directly via the xx network.
To run and listen for messages, without attempting to contact another client,
set the
`recipientContactPath`
variable to an empty string.
To build and run a client, exectue the following bash commands:
```
bash
cd
connectClient/
go build
-o
client
.
./client
```
This will start an e2e client which can be monitored via log activity in
`client.log`
. This will output its own contact file to
`myE2eContact.xxc`
.
It will also read the contact at
`recipientE2eContact.xxc`
, attempting to
establish a connection and send a test payload. This functionality can be
skipped by setting the relevant variable in the code to empty string.
By default, the client sends a single message to the recipient, with the recipient
registering a
`receive.Listener`
which listens to messages of type
`catalog.NoType`
from
`id.ZeroUser`
.
Verification that the client is able to send messages may
also be done. This can be done by checking the client's log for the string
`Message received`
.
```
bash
grep
"Message received"
server.log
INFO 2022/07/07 12:59:12.088046 Message received:
{
XxMessage WjdMwCH+...
[
73 102 32 116 104 105 115 32 109 101 115 115 97 103 101 32 105 115 32 115 101 110 116 32 115 117 99 99 101 115 115 102 117 108 108 121 44 32 119 101 39 108 108 32 104 97 118 101 32 101 115 116 97 98 108 105 115 104 101 100 32 99 111 110 116 97 99 116 32 119 105 116 104 32 116 104 101 32 115 101 114 118 101 114 46] kuycotVTjefJ4nZWJ+Ksg9/jviANn6suteW6HPmXroID l74No/qjr/8Q74mA9VadudforXet8OykqSvPIEFAeUQD
[
0 0 0 0 0 2 245 150] 2022-07-07 12:59:07.078570118
-0700
PDT
true
{
58339144 QUEUED 0xc001e12780 map[PENDING:1969-12-31 16:00:01.65722394
-0800
PST PRECOMPUTING:2022-07-07 12:59:00.644730058
-0700
PDT STANDBY:2022-07-07 12:59:07.062879269
-0700
PDT QUEUED:2022-07-07 12:59:10.062881354
-0700
PDT]
[]
1000 18 187058678 ID:58339144 UpdateID:187058678 State:3 BatchSize:1000 Topology:
"3
\x
dd
\x
c9;
\x
ce
\x
c5
\x
f0
\x
ff&
\x
8c
\x
f1
\x
7f
\n
f
\x
a8K
\x
17
\x
b6
\x
d1
\x
0b|a
\t
[
\x
14
\x
8e
\x
de
\x
d1qϊB
\x
02"
Topology:
"
\x
f5
\\\x
94MB
\x
19ڣq݃
\x
bee
\x
99
\x
bfF
\x
b5
\x
a9
\x
f3k
\x
0e8 gl
\x
f5:d
\x
11
\x
ab
\x
89
\x
17
\x
02"
Topology:
"
\x
01
\x
c1
\x
f6Gi
\x
972p
\x
a9
\x
96
\x
b4
\x
12
\x
0f1
\x
1c
\x
ebw
\x
ef
\x
ca
\x
ed
\"
F
\x
a7w
\x
e2
\n\x
bb8
\x
cbd
\x
05=
\x
02"
Topology:
"
\x
d5
\x
c3
\x
d00
\x
a3a;RqDs
\x
f0
\x
da<
\x
a3)
$y
\x
ef
\x
c1
\x
a0
\x
12_k?
\x
00
\r
IebL
\x
fe
\x
02"
Topology:
"vQ
\x
cd
\t\x
af
\x
91ڤ
\x
86
\x
8ecl
\x
84
\x
b1
\x
95
\x
1e
\x
8f+ږQ
\\
ﷀ]7
\x
89
\x
08
\x
02"
Timestamps:1657223940 Timestamps:1657223940644730058 Timestamps:1657223947062879269 Timestamps:1657223950062881354 Timestamps:0 Timestamps:0 Timestamps:0 ResourceQueueTimeoutMillis:3906340864 AddressSpaceSize:18 EccSignature:
{
Nonce:
"
\x
b2y
\x
ccf
\x
86E
\x
e0NR
\x
d2J3|
\x
b8d
\x
fe
\x
b3
\x
a8
\x
ad
\x
a2
\x
92
\x
e0
\x
e4
\x
0bZ
\x
07
\x
beٓ
\x
b4z
\x
f2"
Signature:
"
\x
e1
\x
c9
\x
92_
\x
fe
\x
9d
\x
7f
\x
18
\x
b920C
\x
a6
\x
d1
\x
e9U
\x
bb
\x
93o
\x
9b
\x
1bp<Y
\x
b1
\x
9f
\x
b7O
\x
012^^
\x
9doa
\x
06P
\x
83
\x
fes
\x
bf
\x
e1
\x
aeL
\x
b0+
\\\x
dc
\x
12r4)
\x
das49
\x
f6=
\x
d2
\x
13
\x
a0
\x
07"
}}}
```
This diff is collapsed.
Click to expand it.
e2eClient/main.go
+
3
−
3
View file @
bcf310a7
...
...
@@ -20,13 +20,13 @@ import (
func
main
()
{
// Logging
initLog
(
1
,
"client
2
.log"
)
initLog
(
1
,
"client.log"
)
// Create a new client object-------------------------------------------------------
// Path to the recipient contact file
recipientContactPath
:=
"
c
ontact.xxc"
myContactPath
:=
"recipient.xxc"
recipientContactPath
:=
"
myE2eC
ontact.xxc"
myContactPath
:=
"recipient
E2eContact
.xxc"
// You would ideally use a configuration tool to acquire these parameters
statePath
:=
"statePathRecipient"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment