Git Product home page Git Product logo

hydar-web-server's Introduction

Hydar Web Server

The hydar web server is a custom web server and Java EE implementation developed for embedding in hydar.xyz, another open source project. Please visit the site or view its repository for more information.

Hydar consists of many independent components, as shown in figure 1. The first layer is a custom implementation of an HTTP file server, including support for various HTTP extensions such as caching, partial downloads, compression, and a custom implementation of HTTP/2.0, supporting server-sided events. It also fully supports encrypted sessions using the builtin Java implementation of TLSv1.3. Under default configurations, files will be reloaded periodically through a low overhead watch service, and static files under 1MB will be cached in memory.

The next layer is the custom JSP compiler and Java EE implementation for servlet code, built upon the Hydar HTTP server, allowing for dynamic webapps which are generally compatible with other servlet containers. The servlet code may be compiled completely in memory and no reflection is needed for responding to the requests after compilation. This additionally allows for authenticated WebSocket sessions that can dynamically dispatch servlet requests, and support for sessions in environments without cookies. For a full list of the implemented Java EE APIs and how to set up your own HydarEE app, see the javadoc(soon)

This package also includes custom JDBC connection and statement pooling, which ensures prepared statements are closed properly and connections are reused, and is loaded through JNDI similarly to in other servlet containers(xyz.hydar.ee.HydarDataSource). Finally, Hydar can optionally rate limit expensive servlet code through the HydarLimiter API.

Building

Clone the repository and run compile_hydar.bat or compile_hydar.sh(JDK 17+ required). This will launch the example server on port 8080, and you can view its source in /src/webapp/, or configure it in hydar.properties.
The command line arguments supplied are paths to "hydar.properties" files, each of which will launch a servlet. Servlets are separated by the Hydar.HOST and Hydar.SERVLET_PATH properties in the file, and the files hosted are determined by the Hydar.WEB_ROOT property. The web root path is relative to the hydar.properties file for that servlet.
More documentation might be available eventually.
There are no dependencies.

hydar-web-server's People

Contributors

glennnm avatar ryanm537 avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.