0

I want to create a ping service, that would make a http/https/ping/tcp connection to a website to see if the service is up or not.

Would python be suitable for this, seeing as I want to build it to be able to ping 1K endpoints per minute.

Blankman
  • 259,732
  • 324
  • 769
  • 1,199

3 Answers3

2

Would python be suitable for this, seeing as I want to build it to be able to ping 1K endpoints per minute.

Python has all you need, but there are two bottlenecks, first is OS and the other is network. While planning for such a program, I would do some research on the limit of the IP stack of your target OS and the relevant limits for the source network.

onur güngör
  • 715
  • 5
  • 18
0

Yes, Python would be suitable for this.

(Next time, just try it--it's trivial.)

John Zwinck
  • 239,568
  • 38
  • 324
  • 436
  • [this question says that it is not trivial at least on some systems](http://stackoverflow.com/q/1212716/4279). Try it if you have access to one of FreeBSD, OpenBSD, NetBSD, OSX, and VMS. – jfs Jan 15 '12 at 23:38
  • Eh, just cache the DNS info within the app if you have to. – John Zwinck Jan 16 '12 at 01:17
0

Practically all, if not all, modern programming languages are capable of that speed of execution easily. The network itself would be the bottleneck, and depending on how many actual pings you want to do of each service, they could get backed up.
If I was doing this, I would use Python with a Java frontend if necessary.

So, in short, yes, Python is both capable and (in my opinion) a good choice for such a program.

cortices
  • 373
  • 2
  • 15
  • thanks for the advise. What do you mean java as a front-end? the web interface? – Blankman Jan 16 '12 at 01:09
  • @blankman no, I mean a java application (as opposed to [applet](http://en.wikipedia.org/wiki/Java_applet)) that would run the python script(s) when necessary based on the user's interaction with the [GUI](http://en.wikipedia.org/wiki/Graphical_user_interface). – cortices Jan 17 '12 at 06:56