Sholud I learn Java sockets first?

Sholud I learn java sockets first before learn go networking?

You don’t need to know java sockets to understand “go networking”.

What are you trying to accomplish?

2 Likes

Do you mean websockets? I don’t know what are “Java sockets”. In networking you use TCP or UDP.

1 Like

I want to make program to connect two pc and send file between them.
I dont know java sockets, could anyone tell me any tutorial on golang networking?

You can do it in many ways. Do you want to write both server and client yourself or you want some simpler way?

1 Like

Start with the high level API described at the beginning of https://godoc.org/net (that is: net.Dial and net.Listen). The first two code blocks are hopefully enough to get started.

When you run into problems, I’m happy to answer questions. Make sure and include the code you are using (both client and server) and describe your setup. I’m not sure how much Go or networking you already know, so its hard to direct you. When I started playing with these APIs, I ran the client and server on the same machine to avoid problems like firewalls and routing.

2 Likes

Thank you all,
I am new to go and network+.
Is there is a go network tutorial for beginners?

https://appliedgo.net/networking/ might be helpful. The author, @christophberger, also participates on this site.

2 Likes

:scream:

2 Likes

:pray:

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.