Seven Comsat Integration Modules
Comsat is the library that integrates Quasar’s lightweight threads/fibers with various Java web-related APIs. For those who want to test out fibers - it’s a great place to start. It allows you to plug-in Quasar fibers to your existing application, through different modules that are detailed below. In a previous blog post we showed that the OS is usually the main bottleneck for web-app scalability. By using fibers, Comsat helps you to efficiently utilize your hardware, while keeping a familiar and simple programming model and the same standard Java APIs you already use. You can expect the same performance and scalability benefits as that of asynchronous code but without any of the complexity.
These are the current Java APIs that Comsat provides fiber-blocking implementations of:
- Servlets - each HTTP request runs in its own fiber (by turning each servlet request into an asynchronous request, and then services each on a separate fiber), rather than a thread. This means you can have many tens-of-thousands of concurrent requests without latency suffering. Check out this tutorial to get started.
- REST Services - Jersey server integration.
- HTTP Clients - ApacheHttpClient, JAX-RS and Retrofit integration.
- DB Access - JDBC, JDBI, jOOQ, and a MongoDB integration for using the allanbank API.
- Dropwizard - Dropwizard integration including Jersey, ApacheHttpClient and JDBI. In our upcoming release, we’ll have support for v0.8.0.
- Spring Framework - Spring MVC and Spring Boot integrations.
- Clojure’s Ring - A fiber-blocking Clojure Ring adapter based on Jetty 9.2
In our upcoming releases we’ll integrate additional popular frameworks. Where would you like to see fibers integrated? Let us know. For those who want to write their own modules - this will show you how.
Join our mailing list
Sign up to receive news and updates.