Преглед изворни кода

테스트 클라이언트 업로드

master
kidjung пре 4 година
комит
1a3ced12f0

+ 8
- 0
.idea/.gitignore Прегледај датотеку

@@ -0,0 +1,8 @@
1
+# Default ignored files
2
+/shelf/
3
+/workspace.xml
4
+# Datasource local storage ignored files
5
+/dataSources/
6
+/dataSources.local.xml
7
+# Editor-based HTTP Client requests
8
+/httpRequests/

+ 9
- 0
.idea/TestClient.iml Прегледај датотеку

@@ -0,0 +1,9 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<module type="WEB_MODULE" version="4">
3
+  <component name="Go" enabled="true" />
4
+  <component name="NewModuleRootManager">
5
+    <content url="file://$MODULE_DIR$" />
6
+    <orderEntry type="inheritedJdk" />
7
+    <orderEntry type="sourceFolder" forTests="false" />
8
+  </component>
9
+</module>

+ 8
- 0
.idea/modules.xml Прегледај датотеку

@@ -0,0 +1,8 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="ProjectModuleManager">
4
+    <modules>
5
+      <module fileurl="file://$PROJECT_DIR$/.idea/TestClient.iml" filepath="$PROJECT_DIR$/.idea/TestClient.iml" />
6
+    </modules>
7
+  </component>
8
+</project>

+ 10
- 0
.idea/vcs.xml Прегледај датотеку

@@ -0,0 +1,10 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="VcsDirectoryMappings">
4
+    <mapping directory="$PROJECT_DIR$/../.." vcs="Git" />
5
+    <mapping directory="$PROJECT_DIR$/src/github.com/fatih/color" vcs="Git" />
6
+    <mapping directory="$PROJECT_DIR$/src/github.com/mattn/go-colorable" vcs="Git" />
7
+    <mapping directory="$PROJECT_DIR$/src/github.com/mattn/go-isatty" vcs="Git" />
8
+    <mapping directory="$PROJECT_DIR$/src/golang.org/x/sys" vcs="Git" />
9
+  </component>
10
+</project>

+ 29
- 0
getIpaddr.go Прегледај датотеку

@@ -0,0 +1,29 @@
1
+package main
2
+
3
+import (
4
+	"fmt"
5
+	"net"
6
+)
7
+
8
+func getCurrentIPAddr() string {
9
+	addrs, err := net.InterfaceAddrs()
10
+
11
+	if err != nil {
12
+		fmt.Println(err)
13
+	}
14
+
15
+	var currentIP string
16
+
17
+	for _, address := range addrs {
18
+
19
+		// check the address type and if it is not a loopback the display it
20
+		// = GET LOCAL IP ADDRESS
21
+		if ipnet, ok := address.(*net.IPNet); ok && !ipnet.IP.IsLoopback() {
22
+			if ipnet.IP.To4() != nil {
23
+				//fmt.Println("Current IP address : ", ipnet.IP.String())
24
+				currentIP = ipnet.IP.String()
25
+			}
26
+		}
27
+	}
28
+	return currentIP
29
+}

+ 590
- 0
main.go Прегледај датотеку

@@ -0,0 +1,590 @@
1
+package main
2
+// TODO: 등록확인 되기 전에는 PM,SM 전송 불가하게 만들 것, 실행파일로 만든 후, AWS 이용해서 여러개 마이크로서비스 상태에서 테스트 해볼것
3
+
4
+import (
5
+	"bufio"
6
+	"encoding/json"
7
+	"errors"
8
+	"fmt"
9
+	"github.com/fatih/color"
10
+	"log"
11
+	"math/rand"
12
+	"net"
13
+	"net/rpc"
14
+	"os"
15
+	"os/signal"
16
+	"strconv"
17
+	"strings"
18
+	"syscall"
19
+	"unicode"
20
+)
21
+
22
+const (
23
+	KGM = 1 + iota
24
+	KSM
25
+	PM
26
+	SM
27
+	RM
28
+	WM
29
+)
30
+
31
+type Message struct {
32
+	From    string //ip 주소
33
+	Version string
34
+	Time    string
35
+	Kind    int //종류
36
+}
37
+
38
+type MsgUnit interface {
39
+	// ConvertToJson - send 전 json 형식으로 바꾸는 함수
40
+	ConvertToJson() ([]byte, error)
41
+	// CheckType - Message 의 타입을 알려줌
42
+	CheckType() int
43
+}
44
+
45
+type RegisterMsg struct {
46
+	Message
47
+	PrivateKey int64
48
+}
49
+
50
+type SubscriptionMsg struct {
51
+	Message
52
+	Topic    []int64  //대주제
53
+	Value    []int64  //피연산자
54
+	Operator []string //연산자
55
+	IsAlpha  bool     //value가 숫자인지 문자열인지
56
+}
57
+
58
+type PublishMsg struct {
59
+	Message
60
+	Topic []int64 //대주제
61
+	Value []int64 //Topic 의 세부적인 내용
62
+	Content []int64 // 내용
63
+}
64
+
65
+type WithdrawMsg struct {
66
+	Message
67
+}
68
+
69
+
70
+
71
+type Receiver struct {
72
+	thisNodeAddr string
73
+	microService MicroService
74
+}
75
+
76
+type MicroService struct {
77
+
78
+	ClientAddr string
79
+	PrivateKey int64
80
+	ShareKey int64
81
+	// 메세지 미들웨어에 연결되어 있는가
82
+	IsConnected chan bool
83
+	MMAddress string
84
+}
85
+
86
+func (receiver Receiver) Receive(args Args, reply *Reply) error{
87
+	switch args.Kind {
88
+
89
+	case KSM:
90
+		//var msg KeyShareMsg
91
+		//err := json.Unmarshal(args.JsonMsg, &msg)
92
+		//if err != nil {
93
+		//	return err
94
+		//}
95
+		//go func() {
96
+		//	_, err := receiver.moscato.Receive(msg)
97
+		//	if err != nil {
98
+		//
99
+		//	}
100
+		//}()
101
+		//reply.CompleteLog = "received completely"
102
+	case PM:
103
+		var msg PublishMsg
104
+		err := json.Unmarshal(args.JsonMsg, &msg)
105
+		if err != nil {
106
+			return err
107
+		}
108
+		go func() {
109
+			receiver.microService.Receive(msg)
110
+		}()
111
+		reply.CompleteLog = "[" + receiver.thisNodeAddr + "] : pubMsg received"
112
+		//var msg PublishMsg
113
+		//err := json.Unmarshal(args.JsonMsg, &msg)
114
+		//if err != nil {
115
+		//	return err
116
+		//}
117
+		//
118
+		//go func() {
119
+		//	_, err := receiver.moscato.Receive(msg)
120
+		//	if err != nil {
121
+		//
122
+		//	}
123
+		//}()
124
+		//reply.CompleteLog = "PM received completely"
125
+	case SM:
126
+		//var msg SubscriptionMsg
127
+		//err := json.Unmarshal(args.JsonMsg, &msg)
128
+		//if err != nil {
129
+		//	return err
130
+		//}
131
+		//go func() {
132
+		//	_, err := receiver.moscato.Receive(msg)
133
+		//	if err != nil {
134
+		//
135
+		//	}
136
+		//}()
137
+		//reply.CompleteLog = "received completely"
138
+	case RM:
139
+		var msg RegisterMsg
140
+		err := json.Unmarshal(args.JsonMsg, &msg)
141
+		if err != nil {
142
+			return err
143
+		}
144
+		go func() {
145
+			receiver.microService.Receive(msg)
146
+		}()
147
+		reply.CompleteLog = "[" + receiver.thisNodeAddr + "] : ackRM received"
148
+	case WM:
149
+		//var msg WithdrawMsg
150
+		//err := json.Unmarshal(args.JsonMsg, &msg)
151
+		//if err != nil {
152
+		//	return err
153
+		//}
154
+		//go func() {
155
+		//	_, err := receiver.moscato.Receive(msg)
156
+		//	if err != nil {
157
+		//
158
+		//	}
159
+		//}()
160
+		//reply.CompleteLog = "received completely"
161
+	default:
162
+		return errors.New("message type Error: Not registered message type")
163
+	}
164
+	//reply.CompleteLog = "received completely"
165
+	return nil
166
+}
167
+
168
+func (microService MicroService) Receive(msg MsgUnit){
169
+	var msg_type = msg.CheckType()
170
+	//메세지 타입에 따라 다르게 처리
171
+	switch msg_type {
172
+
173
+	case KSM: //Key share msg
174
+
175
+	case PM: //Publish msg
176
+		fmt.Println("----- received PM ------")
177
+		DecryptionMsg(msg.(PublishMsg),microService.ShareKey, microService.PrivateKey)
178
+		fmt.Println("------------------------")
179
+
180
+	case SM: //Subscription msg
181
+
182
+	case RM: //Register msg
183
+
184
+		microService.IsConnected <- true
185
+		log.Println("you received RM: Registered Complete!")
186
+
187
+	case WM: //Withdraw msg
188
+		//moscato.MicroServiceManager.RemoveMicroservice(msg.(*WithdrawMsg).From)
189
+
190
+	default:
191
+		errors.New("message type Error: Not registered message type")
192
+	}
193
+
194
+	return
195
+}
196
+
197
+
198
+func (msg SubscriptionMsg) ConvertToJson() ([]byte, error) {
199
+	js := msg
200
+	jsonBytes, err := json.Marshal(js)
201
+	return jsonBytes, err
202
+}
203
+
204
+func (msg PublishMsg) ConvertToJson() ([]byte, error) {
205
+	js := msg
206
+	jsonBytes, err := json.Marshal(js)
207
+	return jsonBytes, err
208
+}
209
+
210
+func (msg RegisterMsg) ConvertToJson() ([]byte, error) {
211
+	js := msg
212
+	jsonBytes, err := json.Marshal(js)
213
+	return jsonBytes, err
214
+}
215
+
216
+func (msg WithdrawMsg) ConvertToJson() ([]byte, error) {
217
+	js := msg
218
+	jsonBytes, err := json.Marshal(js)
219
+	return jsonBytes, err
220
+}
221
+
222
+func (msg Message) CheckType() int {
223
+	return msg.Kind
224
+}
225
+
226
+func CreatePubMsg(msg Message, topic string, value string, content string) PublishMsg {
227
+	//toPubMsg := new(PublishMsg)
228
+	//toPubMsg.Message = msg
229
+
230
+	intArr := []rune(topic)
231
+	//fmt.Print("Topic length ")
232
+	//fmt.Println(len(intArr))
233
+	//fmt.Println(len(toPubMsg.Topic))
234
+	var topicInt [] int64
235
+	for index := 0; index < len(intArr); index++ {
236
+		//toPubMsg.Topic = append(toPubMsg.Topic, int64(intArr[index]))
237
+		topicInt = append(topicInt, int64(intArr[index]))
238
+	}
239
+	//fmt.Println(len(toPubMsg.Topic))
240
+
241
+	intArr = []rune(value)
242
+	var valueInt [] int64
243
+	strInt64, _ :=  strconv.ParseInt(value, 10, 64)
244
+	if unicode.IsDigit(intArr[0]){
245
+		valueInt = append(valueInt, strInt64)
246
+	} else {
247
+		for index := 0; index < len(intArr); index++ {
248
+			//toPubMsg.Value = append(toPubMsg.Value, int64(intArr[index]))
249
+			valueInt = append(valueInt, int64(intArr[index]))
250
+		}
251
+	}
252
+
253
+	intArr = []rune(content)
254
+	var contentInt [] int64
255
+	for index := 0; index < len(intArr); index++ {
256
+		//toPubMsg.content = append(toPubMsg.content, int64(intArr[index]))
257
+		contentInt = append(contentInt, int64(intArr[index]))
258
+	}
259
+
260
+
261
+	return PublishMsg{msg,topicInt,valueInt,contentInt}
262
+}
263
+
264
+func CreateSubMsg(msg Message, topic string, value string, operator string, isAlpha bool) SubscriptionMsg {
265
+	//toPubMsg := new(PublishMsg)
266
+	//toPubMsg.Message = msg
267
+
268
+	intArr := []rune(topic)
269
+	//fmt.Print("Topic length ")
270
+	//fmt.Println(len(intArr))
271
+	//fmt.Println(len(toPubMsg.Topic))
272
+	var topicInt [] int64
273
+	for index := 0; index < len(intArr); index++ {
274
+		//toPubMsg.Topic = append(toPubMsg.Topic, int64(intArr[index]))
275
+		topicInt = append(topicInt, int64(intArr[index]))
276
+	}
277
+	//fmt.Println(len(toPubMsg.Topic))
278
+	var valueInt [] int64
279
+	if isAlpha {
280
+		intArr = []rune(value)
281
+
282
+		for index := 0; index < len(intArr); index++ {
283
+			//toPubMsg.Value = append(toPubMsg.Value, int64(intArr[index]))
284
+			valueInt = append(valueInt, int64(intArr[index]))
285
+		}
286
+	} else {
287
+		stringSlice := strings.Split(value, " ")
288
+		for index:=0; index < len(stringSlice); index++ {
289
+			strInt64, _ := strconv.ParseInt(stringSlice[index], 10, 64)
290
+			valueInt = append(valueInt, strInt64)
291
+		}
292
+	}
293
+	var operatorSlice []string
294
+	operatorSlice = strings.Split(operator, " ")
295
+
296
+
297
+	//intArr = []rune(content)
298
+	//var contentInt [] int64
299
+	//for index := 0; index < len(intArr); index++ {
300
+	//	//toPubMsg.content = append(toPubMsg.content, int64(intArr[index]))
301
+	//	contentInt = append(contentInt, int64(intArr[index]))
302
+	//}
303
+
304
+
305
+	return SubscriptionMsg{msg,topicInt,valueInt,operatorSlice, isAlpha}
306
+}
307
+
308
+
309
+type Args struct { // 매개변수
310
+	JsonMsg [] byte
311
+	Kind int
312
+}
313
+
314
+type Reply struct { // 리턴값
315
+	CompleteLog string
316
+}
317
+
318
+func generateRanUint64() uint64 {
319
+	return uint64(rand.Uint32())<<32 + uint64(rand.Uint32())
320
+}
321
+
322
+func main(){
323
+
324
+	var argu string
325
+	for _, v := range os.Args {
326
+		if strings.Index(v, "-mma") == 0 {
327
+			argu = strings.Replace(v, "-mma=", "",-1)
328
+			break
329
+		}
330
+	}
331
+	MMAddress := argu
332
+	if argu == "" {
333
+		println("there is no Message Middleware address")
334
+		return
335
+	}
336
+
337
+
338
+	args := new(Args)
339
+	reply := new(Reply)
340
+
341
+	currentIP := getCurrentIPAddr()
342
+	const debugPK = 12345
343
+	privateKey := int64(generateRanUint64())
344
+	shareKey := int64(9999)
345
+
346
+	microService := MicroService{currentIP,privateKey, shareKey, make(chan bool), MMAddress}
347
+	receiver := Receiver{thisNodeAddr: currentIP,microService: microService}
348
+
349
+	color.Blue("<current machine address : " + currentIP +  "> <MM address : " + MMAddress + ">")
350
+	color.Blue("<private key : " + strconv.FormatUint(uint64(privateKey), 10)+">")
351
+
352
+	errReg := rpc.Register(receiver)
353
+	if errReg != nil {
354
+		log.Println(errReg)
355
+		return
356
+	}
357
+
358
+	client, err := rpc.Dial("tcp", microService.MMAddress + ":8160") // RPC 서버에 연결
359
+	if err != nil {
360
+		fmt.Println(err)
361
+		return
362
+	}
363
+	defer client.Close() // main 함수가 끝나기 직전에 RPC 연결을 닫음
364
+
365
+	go Listen()
366
+
367
+
368
+	// Register 메세지 생성
369
+	message := Message{From: microService.ClientAddr, Version: "1", Time: "1", Kind: RM}
370
+	regMsg := RegisterMsg{message, microService.PrivateKey}
371
+	RJsonMsg,_ := regMsg.ConvertToJson()
372
+	args.JsonMsg = RJsonMsg
373
+	args.Kind = RM
374
+	err = client.Call("Receiver.MmReceive", args, reply)
375
+	log.Println("RM sent!")
376
+	if err != nil {
377
+		fmt.Println(err)
378
+		return
379
+	}
380
+	color.Yellow("MM: " + reply.CompleteLog)
381
+
382
+
383
+	// 연결 되면 채널로 연결 확인이 되어야 다음 단계로 넘어감
384
+	checkConnect := <- microService.IsConnected
385
+	_ = checkConnect
386
+	fmt.Scanln()
387
+	fmt.Println("***** sending Subscription messages *****")
388
+
389
+	/*
390
+	파일에서 subscription 읽어서 subscription 보내기
391
+	 **/
392
+	subFile, err := os.Open("subscription.txt")
393
+	if err != nil {
394
+		log.Fatalf("Error when opening file: %s", err)
395
+	}
396
+	defer subFile.Close()
397
+	fileScanner := bufio.NewScanner(subFile)
398
+	var subscriptionText string
399
+	numSub := 0
400
+	for fileScanner.Scan(){
401
+		subscriptionText = fileScanner.Text()
402
+		subscriptionTextSlice := strings.Split(subscriptionText, "/")
403
+		subTopic := subscriptionTextSlice[0]
404
+		subValue := subscriptionTextSlice[1]
405
+		subOperator := subscriptionTextSlice[2]
406
+		var subIsAlpha bool
407
+		if subscriptionTextSlice[3] == "true"{
408
+			subIsAlpha = true
409
+		} else if subscriptionTextSlice[3] == "false" {
410
+			subIsAlpha = false
411
+		} else {
412
+			println(numSub, "subscription isAlpha type error")
413
+		}
414
+
415
+		message = Message{From: microService.ClientAddr, Version: "1", Time: "1", Kind: SM}
416
+		subMsg := CreateSubMsg(message, subTopic, subValue, subOperator, subIsAlpha)
417
+		//subMsg := CreateSubMsg(message, "soccer", "player", "==", true)
418
+		//fmt.Println(pubMsg)
419
+		subMsg = EncryptionSubMsg(subMsg,microService.ShareKey,microService.PrivateKey)
420
+		jsonMsg,_ := subMsg.ConvertToJson()
421
+		args.JsonMsg = jsonMsg
422
+		args.Kind = subMsg.Kind
423
+		//fmt.Println(subMsg)
424
+
425
+		//fmt.Println(string(args.JsonMsg))
426
+		err = client.Call("Receiver.MmReceive", args, reply)
427
+		log.Println("SM sent! #:",numSub)
428
+		if err != nil {
429
+			fmt.Println(err)
430
+			return
431
+		}
432
+		//log.Println(reply.CompleteLog)
433
+		color.Yellow("MM: " + reply.CompleteLog)
434
+
435
+	}
436
+
437
+	fmt.Scanln()
438
+	fmt.Println("***** sending Publish messages *****")
439
+
440
+	pubFile, err := os.Open("publish.txt")
441
+	if err != nil {
442
+		log.Fatalf("Error when opening file: %s", err)
443
+	}
444
+	defer pubFile.Close()
445
+	fileScanner2 := bufio.NewScanner(pubFile)
446
+	var publishText string
447
+	numPub := 0
448
+	for fileScanner2.Scan(){
449
+		publishText = fileScanner2.Text()
450
+		publishTextSlice := strings.Split(publishText, "/")
451
+		//fmt.Println(publishTextSlice)
452
+		pubTopic := publishTextSlice[0]
453
+		pubValue := publishTextSlice[1]
454
+		pubContent := publishTextSlice[2]
455
+
456
+
457
+		message = Message{From: microService.ClientAddr, Version: "1", Time: "1", Kind: PM}
458
+		pubMsg := CreatePubMsg(message, pubTopic, pubValue, pubContent)
459
+		//subMsg := CreateSubMsg(message, "soccer", "player", "==", true)
460
+		//fmt.Println("Pub.txt",pubMsg)
461
+		pubMsg = EncryptionPubMsg(pubMsg,microService.ShareKey,microService.PrivateKey)
462
+		jsonMsg,_ := pubMsg.ConvertToJson()
463
+		args.JsonMsg = jsonMsg
464
+		args.Kind = pubMsg.Kind
465
+		//fmt.Println(subMsg)
466
+
467
+		//fmt.Println(string(args.JsonMsg))
468
+		err = client.Call("Receiver.MmReceive", args, reply)
469
+		log.Println("PM sent! #:",numPub)
470
+		if err != nil {
471
+			fmt.Println(err)
472
+			return
473
+		}
474
+		//log.Println(reply.CompleteLog)
475
+		color.Yellow("MM: " + reply.CompleteLog)
476
+
477
+	}
478
+
479
+	sigs := make(chan os.Signal, 1)
480
+	done := make(chan bool, 1)
481
+
482
+	signal.Notify(sigs, syscall.SIGINT, syscall.SIGTERM)
483
+
484
+	go func() {
485
+		sig := <-sigs
486
+		withDraw(message, client)
487
+		//fmt.Println(sig)
488
+		_ = sig
489
+		done <- true
490
+		fmt.Println("\nquit Moscato Successful and terminate microservice")
491
+	}()
492
+
493
+	<-done
494
+	return
495
+}
496
+
497
+func withDraw(msg Message, client *rpc.Client){
498
+	msg.Kind = WM
499
+	wdMsg := WithdrawMsg{msg}
500
+	var args Args
501
+	args.JsonMsg, _ = wdMsg.ConvertToJson()
502
+	args.Kind = WM
503
+	var reply Reply
504
+	client.Call("Receiver.MmReceive", args, reply)
505
+}
506
+
507
+func EncryptionPubMsg(msg PublishMsg, gyKey int64, privateKey int64) PublishMsg {
508
+	for index := range msg.Topic {
509
+		msg.Topic[index] = msg.Topic[index] + gyKey + privateKey
510
+	}
511
+	for index := range msg.Value {
512
+		msg.Value[index] = msg.Value[index] + gyKey + privateKey
513
+	}
514
+	for index := range msg.Content {
515
+		msg.Content[index] = msg.Content[index] + gyKey + privateKey
516
+	}
517
+
518
+
519
+	return msg
520
+}
521
+
522
+func EncryptionSubMsg(msg SubscriptionMsg, gyKey int64, privateKey int64) SubscriptionMsg {
523
+	for index := range msg.Topic {
524
+		msg.Topic[index] = msg.Topic[index] + gyKey + privateKey
525
+	}
526
+	for index := range msg.Value {
527
+		msg.Value[index] = msg.Value[index] + gyKey + privateKey
528
+	}
529
+	return msg
530
+}
531
+
532
+func DecryptionMsg(msg PublishMsg, gyKey int64, privateKey int64) {
533
+	for index := range msg.Topic {
534
+		msg.Topic[index] = msg.Topic[index] - gyKey - privateKey
535
+	}
536
+	for index := range msg.Value {
537
+		msg.Value[index] = msg.Value[index] - gyKey - privateKey
538
+	}
539
+	for index := range msg.Content {
540
+		msg.Content[index] = msg.Content[index] - gyKey - privateKey
541
+	}
542
+
543
+	var runeArr []rune
544
+	for index := range msg.Topic {
545
+		runeArr = append(runeArr, rune(int(msg.Topic[index])))
546
+	}
547
+	fmt.Println("Topic is: " + string(runeArr))
548
+	runeArr = nil
549
+
550
+	for index := range msg.Value {
551
+		runeArr = append(runeArr, rune(int(msg.Value[index])))
552
+	}
553
+
554
+	if len(runeArr) == 1{
555
+		fmt.Println("Value is: ", runeArr)
556
+	} else {
557
+		fmt.Println("Value is:", string(runeArr))
558
+	}
559
+	//if unicode.IsDigit(runeArr[0]){
560
+	//	fmt.Println("Value is: " + string(runeArr))
561
+	//} else {
562
+	//	//for index := 0; index < len(intArr); index++ {
563
+	//	//	//toPubMsg.Value = append(toPubMsg.Value, int64(intArr[index]))
564
+	//	//	valueInt = append(valueInt, int64(intArr[index]))
565
+	//	//}
566
+	//}
567
+
568
+	runeArr = nil
569
+
570
+	for index := range msg.Content {
571
+		runeArr = append(runeArr, rune(int(msg.Content[index])))
572
+	}
573
+	fmt.Println("Content is: " + string(runeArr))
574
+	runeArr = nil
575
+
576
+}
577
+
578
+func Listen() {
579
+	l, err1 := net.Listen("tcp", ":8150") //MM로 부터 받는거
580
+	if err1 != nil {
581
+		log.Fatal(fmt.Sprintf("Unable to listen on given port: %s", err1))
582
+	}
583
+	defer l.Close()
584
+
585
+
586
+	for {
587
+		conn, _ := l.Accept()
588
+		go rpc.ServeConn(conn)
589
+	}
590
+}

BIN
pkg/darwin_amd64/github.com/fatih/color.a Прегледај датотеку


+ 1
- 0
publish.txt Прегледај датотеку

@@ -0,0 +1 @@
1
+goal/7/Son's Goal!!

+ 1
- 0
src/github.com/fatih/color

@@ -0,0 +1 @@
1
+Subproject commit 30388e0cee19cb5904d644c24b83e69f54433314

+ 1
- 0
src/github.com/mattn/go-colorable

@@ -0,0 +1 @@
1
+Subproject commit 2e1b0c1546e0173c0907cf05c67b8ba29ed8b4d1

+ 1
- 0
src/github.com/mattn/go-isatty

@@ -0,0 +1 @@
1
+Subproject commit 68134e7c148cfd3c3697cec49e597a4089ea3281

+ 1
- 0
src/golang.org/x/sys

@@ -0,0 +1 @@
1
+Subproject commit d867a43fc93e4a7a41e33674e954dc459b27dddb

+ 1
- 0
subscription.txt Прегледај датотеку

@@ -0,0 +1 @@
1
+goal/3/>/false

Loading…
Откажи
Сачувај