什么是机架端点?
What is Rack endpoint?
当你这样做时:
run SomeClass.new
在Rack中,SomeClass.new
被称为Rack"endpoint"。我知道端点通常是:端点是 URL 客户端应用程序可以在其中访问您的服务。这如何应用于 Rack,为什么 run
的参数称为 "endpoint"?
Rack is a modular web server abstraction
layer that unifies the API for the interaction of Ruby web application
frameworks and application servers. It
specifies a simple
interface for Rack-compliant applications, and defines standard
request and response objects and application server adapters to
abstract dealing with the low level details of serving web requests. A
Rack endpoint is just an application that adheres to the Rack spec.
当你这样做时:
run SomeClass.new
在Rack中,SomeClass.new
被称为Rack"endpoint"。我知道端点通常是:端点是 URL 客户端应用程序可以在其中访问您的服务。这如何应用于 Rack,为什么 run
的参数称为 "endpoint"?
Rack is a modular web server abstraction layer that unifies the API for the interaction of Ruby web application frameworks and application servers. It specifies a simple interface for Rack-compliant applications, and defines standard request and response objects and application server adapters to abstract dealing with the low level details of serving web requests. A Rack endpoint is just an application that adheres to the Rack spec.