title: Is TCP socket connection good for continuous socket opening/closing
body: <p>I'm working on a project where I need to send data (not much, ~300B(+-100) at once) every 5 minutes. On one side is a raspberry pi with apache2 server and an additional PHP script which serves as a TCP socket server.</p>
  
  <p>On the other side, there are multiple clients, which connect to TCP socket server. Connection is established by the server, they exchange the data and then the socket is closed. This happens every 5 minutes per client (so if I have 100 clients, the socket Will be opened and closed 20 times a minute). </p>
  
  <p>Is this a good way to handle such connections, or should I do it somehow differently? Are PHP scripts fine?</p>