<commit_before>http
====
Framework to build HTTP service on top of Netty. Supports capabilities to route end-points based on annotations.
Implements Guava's Service interface to manage the runtime-state of the HTTP service.

Need for this framework
-----------------------
Netty is a powerful framework to write asynchronous event-driven high-performance applications. While it is
relatively easy to write a RESTFUL HTTP service using netty, the mapping between HTTP routes to handlers is
not a straight-forward task.

Mapping the routes to method handlers requires writing custom `ChannelHandler`s and a lot of boilerplate code
as well as knowledge of Netty's internals in order to correctly chain different handlers.The mapping could be
error prone and tedious when a service handles a lot of end-points.

This can be simplified by using annotations on HTTP routes handling particular
end-points and having a framework that can resolve the path routing based on these annotations.

This framework aims to solve these problems by using JAX-RS annotations from the jersey-library for HTTP path
routing to handle mapping and by building a path routing layer on top of the Netty HTTP.

Setting up an HTTP Service using the framework
----------------------------------------------
Setting up an HTTP service is very simple using this framework:
* Write Handler methods for different HTTP requests
* Annotate the routes for each handler
* Use a builder to setup the HTTP service

Example: A simple HTTP service that responds to the `/v1/ping` endpoint can be setup as:

```java
    // Set up Handlers for Ping
    public class PingHandler extends AbstractHttpHandler {
      @Path("/v1/ping")
      @GET
      public void testGet(HttpRequest request, HttpResponder responder){
        responder.sendString(HttpResponseStatus.OK, "OK");
      }
    }

    // Setup HTTP service and add Handlers
    NettyHttpService service = NettyHttpService.builder()
                               .setPort(7777)
                               .addHttpHandlers(ImmutableList.of(new PingHandler()))
                               .build();

    // Start the HTTP service
    server.startAndWait();
```<commit_msg>Minor updates to README.md<commit_after>http
====
A library to develop HTTP services with Netty Supports capabilities to route end-points based JAX-RS style annotations.
Implements Guava's Service interface to manage the runtime-state of the HTTP service.

Need for this framework
-----------------------
Netty is a powerful framework to write asynchronous event-driven high-performance applications. While it is
relatively easy to write a RESTFUL HTTP service using netty, the mapping between HTTP routes to handlers is
not a straight-forward task.

Mapping the routes to method handlers requires writing custom channel handlers and a lot of boilerplate code
as well as knowledge of Netty's internals in order to correctly chain different handlers.The mapping could be
error prone and tedious when a service handles a lot of end-points.

This can be simplified by using annotations on HTTP routes handling particular
end-points and having a framework that can resolve the path routing based on these annotations.

This framework aims to solve these problems by using JAX-RS annotations from the jersey-library for HTTP path
routing to handle mapping and by building a path routing layer on top of the Netty HTTP.

Setting up an HTTP Service using the framework
----------------------------------------------
Setting up an HTTP service is very simple using this framework:
* Write Handler methods for different HTTP requests
* Annotate the routes for each handler
* Use a builder to setup the HTTP service

Example: A simple HTTP service that responds to the `/v1/ping` endpoint can be setup as:

```java
    // Set up Handlers for Ping
    public class PingHandler extends AbstractHttpHandler {
      @Path("/v1/ping")
      @GET
      public void testGet(HttpRequest request, HttpResponder responder){
        responder.sendString(HttpResponseStatus.OK, "OK");
      }
    }

    // Setup HTTP service and add Handlers
    NettyHttpService service = NettyHttpService.builder()
                               .setPort(7777)
                               .addHttpHandlers(ImmutableList.of(new PingHandler()))
                               .build();

    // Start the HTTP service
    server.startAndWait();
```
{'fraction_non_alphanumeric': 0.07559591373439274, 'fraction_numerical': 0.002724177071509648, 'mean_word_length': 2.9837251356238697, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3416686', 'n_tokens_mistral': 1052, 'n_tokens_neox': 990, 'n_words': 544}