Using JavaScript to extend the server's capabilities

Extending

These documents describe how to use JavaScript to write plugin modules to handle the work order during the request/response cycle, and how to selectively route incoming requests to the plugin.

Developing Plugins

Handling requests with application-specific code

This note describes how the server can be customized to handle application-specific needs using plugin modules written in JavaScript.
router, plugins, dynamic handler, custom handler, workOrder, requestHeaders, incomingPayload, remoteAddress, _queryString, _parameterMap, _cookieMap, outgoingPayload, outgoingFilename, doNotFulfill, responseHeaders

Processing Sequence

Plugin developer responsibilities

This note describes the request/response processing sequence from the plugin developer's perspective. The responsibilities incumbent upon the developer are outlined for plugins following typical patterns.
processing sequence, plugins, chainable processing, response-body processing, empty-body processing, static file processing, terminal processing

Work Orders

Accessing request/response data from a plugin

This note provides guidance on how to make use of the data structures provided to plugins during the request/response cycle.
workOrder, requestHeaders, incomingPayload, remoteAddress, _queryString, _parameterMap, _cookieMap, _formDataMap, _multipartFormData, outgoingPayload, outgoingFilename, doNotFulfill, responseHeaders

Router

Shunting the request/response cycle through custom handlers

This note describes how the server is configured to route dynamic resource requests.
router, dynamic routing, static routing, custom handler, path-pattern, rw-router-missing-module, rw-router-syntax-error, rw-router-unknown-error, rw-router-not-forwarded

Plugin Catalog

Enhance your app with ready-to-go plugins

This is a catalog of the plugins developed by Read Write Tools for the HTTP/2 Server. All of these are available on NPM and Github.
RWSERVE, plugin catalog, rwserve, plugin sdk, custom header, visitor count, lowercase, brute force, lorem ipsum, nodemailer, MySQL REST
Read Write Tools icon

Smart tech

READ WRITE TOOLS

Read Write Hub icon

Templates & Content

READ WRITE HUB

BLUEPHRASE icon

Rediscover HTML

BLUE PHRASE

0

Using JavaScript to extend the server's capabilities

🔗 🔎