Python Forum
Tutorials on sockets, threading and multi-threading?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Tutorials on sockets, threading and multi-threading?
#1
Greetings,

Does anyone know of any books or online tutorials that talks in depth about the networking aspects of Python: sockets, threading, multi-threading, etc? I am assuming multi-threading tasks is the same as asynchronous/parallel tasks? I have been studying Python for about 4 months and have a solid base foundation of the language but these topics are quite new to me.

Also, based on the following terms, can someone tell me if the words are used interchangeably? Just line them up next to one another.

Sockets
Threading
Multi-Threading
Multi-Processing
Parallel
Asynchronous

Thanks,
Matt
Reply
#2
Multi-Threading and Multi-Processing are different. For most operating systems each process executes in their own address space and are unable to do anything to each other unless each one does something special to allow Inter-Process Communication (IPC). There can be many threads (also called tasks) for each process and they can share resources directly within their process but only their process, except there needs to be synchronization among threads/tasks.

The term asynchronous depends on context. It implies Multi-Threading but something called asynchronous might create a separate thread but might not and be asynchronous only when something else creates the thread.

The question is asking so many things that it might be better to ask about networking separate form Multi-Threading.
Reply
#3
I get what you're saying. Asynchronous can be achieved by both if that is your intention.

I am reading up on this topic.

Thank you.


(Oct-01-2021, 08:17 PM)SamHobbs Wrote: Multi-Threading and Multi-Processing are different. For most operating systems each process executes in their own address space and are unable to do anything to each other unless each one does something special to allow Inter-Process Communication (IPC). There can be many threads (also called tasks) for each process and they can share resources directly within their process but only their process, except there needs to be synchronization among threads/tasks.

The term asynchronous depends on context. It implies Multi-Threading but something called asynchronous might create a separate thread but might not and be asynchronous only when something else creates the thread.

The question is asking so many things that it might be better to ask about networking separate form Multi-Threading.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  threading native_id returning same value for all threads billykid999 2 991 May-04-2023, 06:40 AM
Last Post: billykid999
  Concurrent futures threading running at same speed as non-threading billykid999 13 1,813 May-03-2023, 08:22 AM
Last Post: billykid999
  Trouble with threading and reading variable from a different script Lembas 14 3,021 Apr-26-2023, 11:21 PM
Last Post: Lembas
  using threading.Timer for function korenron 1 1,193 Dec-20-2022, 01:09 PM
Last Post: ndc85430
  [Solved]Help with Threading Extra 7 1,833 Sep-05-2022, 05:29 PM
Last Post: Extra
Question Opencv and threading ethernel 4 138,968 Feb-25-2022, 06:06 PM
Last Post: ethernel
  Inconsistent counting / timing with threading rantwhy 1 1,759 Nov-24-2021, 04:04 AM
Last Post: deanhystad
  Mult-threading and locking file mr_byte31 4 2,583 Oct-16-2021, 01:54 AM
Last Post: Larz60+
  Matplotlib Animation with Threading peterjv26 4 7,170 Oct-08-2021, 05:51 PM
Last Post: peterjv26
  Can I open\use threading in Python? korenron 2 1,792 Jun-30-2021, 10:42 AM
Last Post: korenron

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020