Пн. 13 янв. 2014 16:12:29 пользователь Pavel Astakhov (pastakhov@yandex.ru) написал:
From: Dmitriy Sintsov <questpc <at> rambler.ru> Subject: Re: Is Foxway a right way? http://news.gmane.org/find-root.php?message_id=1389610306.562859.4565.53906%40mail.rambler.ru Newsgroups: gmane.science.linguistics.wikipedia.technical http://news.gmane.org/gmane.science.linguistics.wikipedia.technical Date: 2014-01-13 10:51:46 GMT (29 minutes ago) I implemented something similar before Scribunto was stable enough and deployed
My idea is different
I know. But the interpreting probably is too slow for huge-load wikis.
... many people say that Lua ... better language in general ...
This is a very controversial statement. I use the PHP interpreter because mediawiki written in PHP and PHP is more powerful.
Lua VM is not stack-based, it's RAM usage can be easily controlled. The people behind Scribunto (Tim Starling and Victor Vasiliev) are better programmers than me, if they choosed Lua then it's really worth something. Also Lua is used as scripting language in huge number of various applications (games, scientific) while PHP is not. Lua VM also was a bit faster than both PHP and Python some year ago.
From: Tyler Romeo <tylerromeo <at> gmail.com> Subject: Re: Is Foxway a right way? http://news.gmane.org/find-root.php?message_id=CAE0Q5ovAtE%5f5WDgXr6rYUwkCqt%5fVNawuiMjWP9i%5fLbrXU5CAKA%40mail.gmail.com Newsgroups: gmane.science.linguistics.wikipedia.technical http://news.gmane.org/gmane.science.linguistics.wikipedia.technical Date: 2014-01-13 09:37:46 GMT (43 minutes ago) How does this compare to the PECL runkit extension? Also have you benchmarked it against Scribunto? Because Scribunto does kind of the same exact thing except just with a different programming language (and Scribunto uses a native interpreter rather than one written in PHP).
I do not propose to improve what is already there. I'm sure there is nothing faster LUA and one is the best choice. Why is there a need for LUA? Because building html page from wiki markup without LUA takes a long time. Why? Because wiki page use a lot of function calls that are working together very slowly. So let it be. Can not we just all be cached? No, pages change frequently and cache is not dimensionless.
I guess they have enough of logged-in non-anonymous users so not everything and not always may be cached. Also I remember bad things could happen when source of template changes and lots of pages has to be regenerated, Scribunto probably reduced CPU load a lot in such case. Do not forget they are not small / medium size wiki but a really huge wiki.
I propose to discuss the new principle of building html pages from the wiki markup.
- Need to separate Wiki markup from the functions, just as html
separated from PHP code. In this case, need to cache only the result of these functions. 2. Let functions to work quickly. I checked, it is possible. I'm not trying to build a page quickly, I'm trying to do this very effectively. That is my idea. Efficient use of resources gives bigger win in speed.
Maybe you could apply your extension to Goole Summer of Code, or to another similar experimental project. They are announcing such projects regularly. Dmitriy