
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
tessellate-server
Advanced tools
Web service runtime for tessellate services.
import { TessellateServer } from 'tessellate-server'
name: string
Optional application name (see koa.app.name)Add koa Middleware that runs before any routes are handled. If defer
is set to true
, the middleware will run after all routes. Also see koa.app.use.
Start the koa application server and prometheus metrics server on the specified ports. The default value for metricsPort
is port + 1
.
koa-rx-router instance. Use it to add routes.
Stop all koa servers.
import { nconf } from 'tessellate-server'
Wrapper around nconf with default values and convenience methods.
set(key: string, value: any)
- see nconfget(key: string)
- see nconfgetObject(key: string): Object
- see get
getString(key: string): string
- see get
argv(args: Object)
- see nconfdefaults(defaults: Object)
- see nconfimport { Problem } from 'tessellate-server'
A throwable Error class modeled after Zalando Problem.
Run npm start
or check out the code below:
import { TessellateServer, Problem } from '../src'
import { Observable } from 'rxjs'
const server = new TessellateServer()
server.use((ctx, next) => {
console.log('Hi, this is middleware.')
return next()
})
server.router.get('/', o => o.mapTo('Hello!'))
server.router.get('/error', o => o.switchMapTo(Observable.throw(
new Problem({
title: 'Teapot',
detail: 'I am a teapot.',
status: 418
}))
))
server.start(3001)
FAQs
Tessellate server runtime.
We found that tessellate-server demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.