Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
Why can not we send an email using HTTP protocols? An email contains text, so why cant it be send using HTTP?. I searched in every where. But can not understand those documents.So please help me to understand this
The protocols to transfer mails (SMTP, POP, IMAP) are all built on top of TCP and HTTP it built on top of TCP too. At least SMTP and POP are older protocols than HTTP.
Of course you could in theory built some mail transfer protocol on top of HTTP. But this effectively means to rebuilt the functionality we already have on top of TCP so that it now is built on top of HTTP which is on top of TCP again. So this is mostly another layer of complexity without actually gaining a lot.
But I'm pretty sure that they were already several attempts to built SOAP, REST,... API's which care about mail transport. But probably none of this showed to be significantly better than the old protocols we already have, which means that we don't switch the existing infrastructure we have to a new protocol in the foreseeable future. It's not that the existing protocols are that good but to take the effort to replace all of this a new protocol must be significantly better.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 months ago.
Improve this question
I am working on a MacOS cocoa application using swift from which i have to send information using an object to another application on different machine which then use the information in it's code.
I am new to swift and sorry for my english if you don't to get it.
I have no idea how to do this. Please help me with this if anyone knows.
Well just so you know network communication can be pretty hard. I believe the easiest way is to use WebSocket, which establish a pipe of communication between two devices. You can then send any data you want over this socket.
One difficulty is for the devices to find one another : do they know each other's IP address ? Are they on the same local network ?
The second step is to decide what data you want to send. The simplest is to send JSON content which can be serialized / deserialized on each end easily.
Checkout :
tutorial for websocket
JSON Serialization
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I work on system security and i want to know why we need the RPC programming and what is the differences between RPC and simple socket programming? Both of them have a client and server application,tcp/ip based,IP address,port number ,...
Thanks
RPC is one definition of how to send structured data as a call to the server and get structured data as a response back. You could use any of a wide variety of protocols with the same basic goal, like SOAP or WCF.
Any of those protocols builds on top of TCP/IP, and lets the server and the client communicate using predefined strucures. You could do the same without any of those protocols, but then you would have to set up a new set of custom rules for how the server and client should communicate.
You don't need any of those protocols for communication, and sometimes (in realtime online gaming for example) a custom streamlined protocol is used instead, but for most client-server communication a well known protocol is preferable.
Well, there are a lot of different RPC technologies, so it is hard to say what you are refering to. But generally speaking it is a layer on top of network transports (like UDP and TCP) to marshall parameters and call results. You need it to communicate in a structured way with services. Some commonly used applications and system services use well known RPC mechanisms (like Windows DCOM, NFS mount protocol, Kerberos, SAP RFC).
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I need to have 3 major things from perl and don't know how to go about it.
Non Blocking websocket implementation like mojo.
The server needs to accept broadcast calls after it has started
The server needs to be able to access data that is on a different thread.
I have tried mojo but didn't find a way to control the port (I can live with that) and didn't figure out how to call events after the server has started. I wasn't able to test if it could handle events after the fact.
I have tried Net::WebSocket::Server but it is blocking. I am tempted to wrap my own code around it so that it can handle non blocking and shared data as it is by far the simplest implementation and easy to modify.
I have also tried pocket.io but it didn't have a very easy way to implement OO design and still remain thread safe. (Mostly because of the Plack framework).
Does anyone have a good example of how to do this with Mojolicious or pocket.io? If not I will just have to implement my own implementation.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I'm looking at WebRTC and I'm wondering how to implement a solution where the client connects to the PTSN via SIP. It seems like a pretty new technology so I assume that this would not work on IE browsers; is this correct?
Basically, I have a dialpad UI on the page and users who have an SIP account. Can WebRTC enable the end-user to make calls to the PTSN and what does it take to implement such solution?
I'm looking into this as an alternative to Java or Flash based webphones.
Thanks for your suggestions.
WebRTC is indeed new and isn't available on IE or Safari. It is available in beta/alpha on other browsers. IE will probably support it in the future and Safari probably won't for some time.
WebRTC does only the media parts of the negotiation, and as such it means that it does no signaling of its own. SIP can work well with WebRTC, but you will need a JS implementation of SIP (over WebSockets) and then you'll need to unwrap the SIP signaling on the server side and "migrate" it to UDP or TCP.
Asterisk are working on such a server side platform: http://blogs.digium.com/2012/05/23/asterisk-11-webrtc/
More about doing SIP in conjunction with WebRTC can be found here: http://bloggeek.me/html-sip/
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
I am looking to write a simple client/server utilizing TCP sockets. Any ideas how to do network programming in Go?
Go has fine support for networking.
For a server, the easiest thing to do is have your main() start a tcp accept loop and spawn a goroutine to handle each request.
The first go software I wrote was a memcached server. You may want to check out gomemcached for an idea of how to get started on servers.
Clients shouldn't be particularly harder. In many cases, it may make the most sense to have a shared client with goroutines for inbound communication much like I use in gomemcached for communicating with the actual storage layer.
Of course, this isn't the only way. Perhaps you'll find something better as you experiment.