School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!

Welcome to Dream.In.Code
Become an Expert!

Join 300,441 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 1,505 people online right now. Registration is fast and FREE... Join Now!




More questions about choosing a server language

 

More questions about choosing a server language, last time i promise :P

xCraftyx

11 Jun, 2009 - 06:21 PM
Post #1

D.I.C Head
**

Joined: 13 Sep, 2008
Posts: 206



Thanked: 3 times
My Contributions
Right now I am planning on writing a server emulation in Java that would presumably be able to do the items listed below. Just out of curiosity and before i make a final decision and start on the server, would i be able to use Python with C for bottlenecks in place of Java? I'm guessing that I'll have to use Java but I've heard so many good things about Python that i figured it was worth asking.

Since Python is capable of creating standalone applications, would it be able to handle running the majority of a server emulation with some C for the really heavy lifting? Just to clear things up:
  • Is Python fast enough to handle a load on a server without causing it to lag
  • Would it be able to support UDP connections and support asynchronous socket IO
  • Does Python have a powerful networking library
  • Would the project break down on me once it gets past 10k lines of code

Thanks

User is offlineProfile CardPM
+Quote Post


Oler1s

RE: More Questions About Choosing A Server Language

11 Jun, 2009 - 08:14 PM
Post #2

D.I.C Addict
****

Joined: 4 Jun, 2009
Posts: 639



Thanked: 66 times
My Contributions
QUOTE
would i be able to use Python with C for bottlenecks in place of Java?
Sure, that's an option as well.

QUOTE
I'm guessing that I'll have to use Java
Why? What pushes you towards Java?

QUOTE
would it be able to handle running the majority of a server emulation with some C for the really heavy lifting?
Depending on the scenario. Well, you have to consider how it's being used. EVE Online: MMORPG. Google uses it. Then there's the Python frameworks like Twisted and CherryPy which implement very fast servers. So it's been in use for serious work under heavy loads.

I know what you're trying to get at with your questions. When it comes to really high performance work, you're dependent on C extensions and seriously well developed third party libraries (i.e. tested to scale). Thankfully, Python does have them.

If you're writing a server emulator, I assume you have the technical background to do your investigation. If your question comes down to "Is Python a viable alternative" the answer is a definite yes, but you'll have to look at your own knowledge and comfort with Python. Same goes with Java. I'm far more comfortable working with Python, and have a bias, so take my advocacy with that caution.
User is offlineProfile CardPM
+Quote Post

xCraftyx

RE: More Questions About Choosing A Server Language

11 Jun, 2009 - 10:38 PM
Post #3

D.I.C Head
**

Joined: 13 Sep, 2008
Posts: 206



Thanked: 3 times
My Contributions
Thanks! The reason I'm biased towards Java because I'm the most comfortable with it but I figured that Python would be quicker to develop and i would be able to track down bugs more easily. The language itself isn't difficult (I've played with it) and I've done enough research to say that I have or at least have the ability to achieve the technical skills for my project. Again thanks for the reply Oler1s you answered my questions completely smile.gif
User is offlineProfile CardPM
+Quote Post

masteryee

RE: More Questions About Choosing A Server Language

11 Jun, 2009 - 10:44 PM
Post #4

D.I.C Regular
***

Joined: 16 May, 2009
Posts: 266



Thanked: 36 times
My Contributions
I thought EVE Online's server code was rewritten in Erlang at one point? I was kind of gung ho about Erlang a while back because of its modularity, concurrency and distributed features, but I never really got too far in the learning process. Might be something worth looking into.
User is offlineProfile CardPM
+Quote Post

Oler1s

RE: More Questions About Choosing A Server Language

12 Jun, 2009 - 07:53 PM
Post #5

D.I.C Addict
****

Joined: 4 Jun, 2009
Posts: 639



Thanked: 66 times
My Contributions
QUOTE
The reason I'm biased towards Java because I'm the most comfortable with it but I figured that Python would be quicker to develop and i would be able to track down bugs more easily. The language itself isn't difficult (I've played with it) and I've done enough research to say that I have or at least have the ability to achieve the technical skills for my project.
I thought as much. You'll recognize then, that you'll face two kinds of challenges. One is the comfort with the tools and libraries. You probably have experience with the various frameworks in Java. You'll have to get up to speed with those in Python. It's not painful, but it takes time of course.

And the second is that you need to dig into the platform. Especially when writing a high performance application, programming approaches suitable in smaller applications may not be so. You know I'm no longer talking about design issues, bubt just platform specific things. What is expensive in Python, and what isn't? The information isn't obscure, but you still have to read through and learn it.

It's a tough choice. Maybe interesting for you is Jython (see the advocacy page), the Java implementation pf Python.

This post has been edited by Oler1s: 12 Jun, 2009 - 07:53 PM
User is offlineProfile CardPM
+Quote Post

xCraftyx

RE: More Questions About Choosing A Server Language

15 Jun, 2009 - 03:47 PM
Post #6

D.I.C Head
**

Joined: 13 Sep, 2008
Posts: 206



Thanked: 3 times
My Contributions
I've heard of Jython, I'll look into it a bit more. Might stick with Java though since I won't have to worry too much about system expenses with the JVM
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic

Time is now: 11/8/09 01:19AM

Live Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month