需要基本信息 [英] need basic information

查看:62
本文介绍了需要基本信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

让我们假设我们需要创建一个像asp.net这样的Web开发框架。您将在该框架中实现哪些基本功能以支持客户端和服务器之间的通信?

解决方案

也许您会感到惊讶,但实际上您需要创建HTTP服务器,或使用某些可用HTTP服务器的插件架构创建插件模块。此插件应该能够接受一些具有您设计格式的服务器端文件,然后按照HTTP协议或插件体系结构所需的格式处理成HTTP响应格式。此处理可能使用您可能决定托管的某种脚本语言,或者使用一些预编译的模块(或者在.NET或其他CLR实现的情况下使用组件,如Mono,见下文)。



如果你想设计自己的HTTP服务器,建议也建立一个插件架构。



请参阅:

http://en.wikipedia.org/wiki/HTTP [ ^ ],

http://en.wikipedia.org/wiki/List_of_HTTP_header_fields [ ^ ],

http ://www.w3.org/Protocols/HTTP/AsImplemented.html [ ^ ]。



现有插件架构的示例是Apache HTTP服务器之一。它实际上用于ASP.NET的替代实现(见下文)。请参阅:

http://en.wikipedia.org/wiki/Apache_HTTP_Server [< a href =http://en.wikipedia.org/wiki/Apache_HTTP_Servertarget =_ blanktitle =New Window> ^ ],

https://httpd.apache.org/ [ ^ ]。



这是代码示例,如果你想这样做并实现Apache模块,你可以使用它: a href =http://httpd.apache.org/docs/2.2/mod/mod_example.html> http://httpd.apache.org/docs/2.2/mod/mod_example.html [< a href =http://httpd.apache.org/docs/2.2/mod/mod_example.html\"target =_ blanktitle =New Window> ^ ]。



另请参阅:

http:// en。 wikipedia.org/wiki/Mono_%28software%29 [ ^ ]

http://www.mono-project.com/Main_Page [ ^ ]。



For已经存在的替代ASP.NET实现的示例,请了解 mod_mono mod_aspnet

http://en.wikipedia.org/wiki/Mod_mono [ ^ ],

http://www.mono-project.com/Mod_mono [ ^ ],

http://dev.anmar。 eu.org/mono/mod_mono [ ^ ],

http:// mod-a spdotnet.sourceforge.net/ [ ^ ],

http://www.bitrock.com/download_mono_download.html [ ^ ]。



我希望这一切都可以让您对如何创建此类技术有所了解。感谢您提出的有趣问题。



-SA


客户端与服务器之间的基本通信是http over tcp / ip。但是你可以实现完整的,或只是互联网协议套件的一部分



祝你好运!

Let us suppose we need to create a web development framework like asp .net . What are the basic feature will you implement in that framework to support communication between client and server?

解决方案

Maybe you would be surprised, but actually you need to create either the HTTP server, or create a plug-in module using the plug-in architecture of some available HTTP server. This plug-in should be able to accept some server-side files with the format you devise, and process then into HTTP response format, following either the HTTP protocol or the format required by plug-in architecture. This processing may use some scripting language you may decide to host, or use some pre-compiled modules (or assemblies, in case of .NET or other CLR implementation like Mono, see below).

If you want to design your own HTTP server, it would be advisable to create a plug-in architecture, too.

Please see:
http://en.wikipedia.org/wiki/HTTP[^],
http://en.wikipedia.org/wiki/List_of_HTTP_header_fields[^],
http://www.w3.org/Protocols/HTTP/AsImplemented.html[^].

The example of existing plug-in architecture is the one of Apache HTTP server. It is actually used for alternative implementation of ASP.NET (see below). Please see:
http://en.wikipedia.org/wiki/Apache_HTTP_Server[^],
https://httpd.apache.org/[^].

This is the code example which you can use if you want to go this way and implement Apache modules: http://httpd.apache.org/docs/2.2/mod/mod_example.html[^].

See also:
http://en.wikipedia.org/wiki/Mono_%28software%29[^],
http://www.mono-project.com/Main_Page[^].

For example of alternative ASP.NET implementation which already exists, please learn about mod_mono or mod_aspnet:
http://en.wikipedia.org/wiki/Mod_mono[^],
http://www.mono-project.com/Mod_mono[^],
http://dev.anmar.eu.org/mono/mod_mono[^],
http://mod-aspdotnet.sourceforge.net/[^],
http://www.bitrock.com/download_mono_download.html[^].

I hope it all can give you a good idea on how to approach the creation of such technology. Thank you for your interesting question.

—SA


The basic communication between client and server is http over tcp/ip. But you could implement the complete, or just a subset of the internet protocol suite.

Good luck!


这篇关于需要基本信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆