Go Back   FlashFXP Forums > > > >

ioFTPD General New releases, comments, questions regarding the latest version of ioFTPD.

Reply
 
Thread Tools Rate Thread Display Modes
Old 05-30-2005, 11:47 AM   #1
darkone
Disabled
FlashFXP Registered User
ioFTPD Administrator
 
darkone's Avatar
 
Join Date: Dec 2001
Posts: 2,230
Default Lua

I have just finished evaluating lua , and it seems to be perfect replacement for both cookies and hardcoded protocol specific commands.

Lua compiles code to platform independent bytecode like java/php & tcl , but is much less bloated and far more optimized, and therefore it's able to provide outstanding performance. Following script executes in 0.0000046seconds (10000 executions in 46msecs):

Code:
a = 1
b = 2
c = a+b
a = b
c = a
darkone is offline   Reply With Quote
Old 05-31-2005, 03:28 AM   #2
FTPServerTools
Senior Member
FlashFXP Beta Tester
ioFTPD Scripter
 
Join Date: Sep 2002
Posts: 543
Default

YES YES YES!! Lua is often used in game development due to it's speed and the easy extendability. A good choice, even tho you could use a delphi alike language too. I hope you'll use it as dll tho, that would make adding a new lua version even easier. I've played with it as well for other projects.
FTPServerTools is offline   Reply With Quote
Old 05-31-2005, 05:48 AM   #3
esmandil
Senior Member
FlashFXP Registered User
ioFTPD Foundation User
 
Join Date: Oct 2004
Posts: 107
Default

Yes, Lua seems like a nice language.

I am not sure if it isn't *too* small, though -- there are a couple of nice features it doesn't have in order to remain that small (while I am not an expert on Lua by any means, ObjectOrientation and Unicode come to mind).

Ever thought about Python? Embedding Python is a bit trickier than embedding Lua, but it is almost as fast and has a number of cool features of its own (like a support for running multiple interpreters).
esmandil is offline   Reply With Quote
Old 05-31-2005, 08:35 AM   #4
FTPServerTools
Senior Member
FlashFXP Beta Tester
ioFTPD Scripter
 
Join Date: Sep 2002
Posts: 543
Default

Hmm I didnt know python could be bytecode compiled. Anyway lua can be easily extended and then there is also java (snooorrrreee) or .NET (zoooom) or there is a bleaming fast delphi alike language called innerfuse pascal/remobjects pascal with source code. But lua is made to run on just about anything so I guess this would be easier.
FTPServerTools is offline   Reply With Quote
Old 05-31-2005, 08:46 AM   #5
darkone
Disabled
FlashFXP Registered User
ioFTPD Administrator
 
darkone's Avatar
 
Join Date: Dec 2001
Posts: 2,230
Default

Lua does actually support modules that provide objecet oriented classes. Afaik you can't however create new classes directly from lua code.

Lua supports running multiple interpreters simultanously - and it's actually designed to do this. Also there's no use of TLS values. which makes it possible to cache interpreters in a global pool. Pooling interpreters is impossible on many scripting languages such as php and tcl (not sure about python).

Lua is only meant to be used in situatins where performance is critical - such as command replies. In non-performance critical areas you will be able to call tcl or php directly, and through lua.
darkone is offline   Reply With Quote
Old 05-31-2005, 09:27 AM   #6
esmandil
Senior Member
FlashFXP Registered User
ioFTPD Foundation User
 
Join Date: Oct 2004
Posts: 107
Default

Quote:
Pooling interpreters is impossible on many scripting languages such as php and tcl (not sure about python).
I *think* it is possible in Python as well, AFAIK mod_python for Apache uses it. But I may be wrong.

Sounds like you have already made your mind, though
esmandil is offline   Reply With Quote
Reply

Tags
a+b, bloated, lua, optimized, provide

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 11:34 AM.

Parts of this site powered by vBulletin Mods & Addons from DragonByte Technologies Ltd. (Details)