Does anyone has first-hand experience with G-WAN web Server?

。_饼干妹妹 提交于 2019-12-02 16:46:10

Well, now G-WAN is available under Linux, I am using it for more than 6 months.

The C scripts are fully-ANSI C compatible so there is no difference for any seasonned C programmer.

To update them on the server, you can edit them directly in the /csp folder (remotely via SSH) or locally on a test machine (and copy them later): G-WAN reloads scripts on-the-fly when they have been changed on disk (no server stop required).

G-WAN C scripts can use any existing library (starting with all those under /usr/lib) without any configuration or interface: you just have to write a '#pragma link' followed by the name of the library at the top of your script.

What I found really useful is the ability to edit C scripts and refresh the view in the Internet browser to see how my code works.

If there is a compilation error, then G-WAN outputs the line in the source code (just like any C compiler).

But where it enters the extraordinary area, is when you have a C script crash: here also it gives you THE LINE NUMBER IN THE SOURCE CODE (with the faulty call and the backtrace).

Kind of black-magic when you are used to Apache modules.

Pindatjuh

My experience with G-WAN and its C scripts are:

  • The G-WAN community is very small. Questions you have are mostly answered by its single developer.
  • I consider the API not mature: it's not as "clean" as Java APIs.
  • The limitation, but at the same time the power, of C: it's a systems programming language. So writing application logic in it must be done carefully.
  • You generally need to be a good developer to get good results: if you do something wrong, the server crashes fast and hard (Unix-style).

I've written some scripts now, to try out G-WAN. Overall, it's been very "productive": not much bugs and it works if you follow the guidelines and don't want to do too much funky stuff you expect it to have, like mature web servers. However, I have got the feeling I'm reinventing the wheel a lot of times.

G-WAN also support scripts written in other programming languages (C++, Objective-C, Java, etc.) so you will benefit from whatever native libraries each language implements.

For C scripts, well, the /usr/lib directory lists more than 1,500 libraries that G-WAN can re-use with a simple #pragma link "library".

I found it neat to be able to write a Web application with a part in C, another in C++ and a third one in Java!

Benchmark shown how G-wan fare poorly at handling these tests.

http://joshitech.blogspot.sg/2012/04/performance-nginx-netty-cppcms.html

I have been using G-Wan for about two years. I consider it highly stable and production ready for static files. I have a number of static sites running for over a year with no issues.

I have built some small scale dynamic sites in C with it as demos/test projects. A bittorrent tracker and a real time analytics platform both using the KV Store for data backing.

In my view building large scale dynamic sites in G-Wan is possible but only with a significant investment in development and support. G-Wan is better suited to building robust highly scalable "enterprise grade" applications than tossing something together over a weekend.

I use G-Wan for a CMS http://solicms.com but for now, I use Ruby as primary language.

I have used G-wan for some preliminary testing and it does benchmark well. I have found a few points of concern that make it so that I will not likely use it for any of my projects. I have found that it seems to cache responses for about 0.5secs to speedup the responses/second and I can't have only some of the responses hitting the application code. Also the key/value store is great for cache and temporary data storage but I'm not sure how well it will work as a real back-end storage method.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!