Jetty 9 Dima Ionut Daniel. Contents What is Jetty? History Jetty 9 new features Jetty Configuration Deployment Arhitecture JMX SPDY Handlers WebSocket.

Slides:



Advertisements
Similar presentations
SIP Servlets. SIP Summit SIP Servlets Problem Statement Want to enable construction of a wide variety of IP telephony.
Advertisements

Oct, 26 th, 2010 OGF 30, NSI-WG: Network Service Interface working group Web Services Overview Web Services for NSI protocol implementation
OpusCollege and Spring-DM. OSGi based web applications – three strategies OSGi container embedded in another container: OSGi Bridge Server (OBS)  e.g.
Raptor Technical Details. Outline Workshop structured by Raptor workflow – Raptor Event model. – ICA log file parsing – ICA/MUA event storage – ICA event.
Provisioning distributed OSGi applications in a cloud Guillaume Nodet, FuseSource November 2011.
Reza hooshangi ( ). short history  One of the last major challenges for the web is to enable human communication via voice and video: Real Time.
Socket Layer Security. In this Presentation: need for web security SSL/TLS transport layer security protocols HTTPS secure shell (SSH)
This product includes material developed by the Globus Project ( Introduction to Grid Services and GT3.
Developing Application Extensions with Axis2 Chathura Herath Eran Chinthaka.
Object-Oriented Enterprise Application Development Tomcat 3.2 Configuration Last Updated: 03/30/2001.
Struts Basics SSE USTC Qing Ding. Agenda What is and Why Struts? Struts architecture – Controller: Focus of this presentation – Model – View Struts tag.
Web architecture Dr Jim Briggs Web architecture.
Microsoft ASP.NET AJAX - AJAX as it has to be Presented by : Rana Vijayasimha Nalla CSCE Grad Student.
The World Wide Web and the Internet Dr Jim Briggs 1WUCM1.
Tomcat Configuration A Very, Very, Very Brief Overview.
Web programming for project students Dr Jim Briggs.
Spring Dynamic Modules. Startlocation: Documentation: /1.2.1/reference/html/
Web Applications Basics. Introduction to Web Web features Clent/Server HTTP HyperText Markup Language URL addresses Web server - a computer program that.
Apache Jakarta Tomcat Suh, Junho. Road Map Tomcat Overview Tomcat Overview History History What is Tomcat? What is Tomcat? Servlet Container.
Quick Tour of the Web Technologies: The BIG picture LECTURE A bird’s eye view of the different web technologies that we shall explore and study.
Understanding and Managing WebSphere V5
Intro to Spring CJUG - January What is Spring? “The Spring framework provides central transaction control of various objects.” This means that any.
Lecture 2 - Struts ENTERPRISE JAVA. 2 Contents  Servlet Deployment  Servlet Filters  Model View Controllers  Struts  Dependency Injection.
M. Taimoor Khan * Java Server Pages (JSP) is a server-side programming technology that enables the creation of dynamic,
OSGi.
ASP.NET + Ajax Jesper Tørresø ITNET2 F08. Ajax Ajax (Asynchronous JavaScript and XML) A group of interrelated web development techniques used for creating.
Introducing Axis2 Eran Chinthaka. Agenda  Introduction and Motivation  The “big picture”  Key Features of Axis2 High Performance XML Processing Model.
Institute of Computer and Communication Network Engineering OFC/NFOEC, 6-10 March 2011, Los Angeles, CA Lessons Learned From Implementing a Path Computation.
Implementing ISA Server Publishing. Introduction What Are Web Publishing Rules? ISA Server uses Web publishing rules to make Web sites on protected networks.
Enabling Embedded Systems to access Internet Resources.
Chapter 17 - Deploying Java Applications on the Web1 Chapter 17 Deploying Java Applications on the Web.
Apache Mina Dima Ionut Daniel. Contents What is Apache Mina? Why Apache Mina? Mina Architecture Mina Core Mina Advanced JMX Support Spring Integration.
© 2006 IBM Corporation IBM WebSphere Portlet Factory Architecture.
COMP 321 Week 7. Overview HTML and HTTP Basics Dynamic Web Content ServletsMVC Tomcat in Eclipse Demonstration Lab 7-1 Introduction.
Web Applications - Basics. Introduction to Web Web features Clent/Server HyperText Transfer Protocol HyperText Markup Language URL addresses Web server.
第十四章 J2EE 入门 Introduction What is J2EE ?
SUSE Linux Enterprise Desktop Administration Chapter 12 Administer Printing.
1 Apache. 2 Module - Apache ♦ Overview This module focuses on configuring and customizing Apache web server. Apache is a commonly used Hypertext Transfer.
Introduction to MINA A M ultipurpose I nfrastructure for N etwork A pplications April 2005, Trustin Lee, ASF.
Webservice versioning using osgi Allard Buijze, Jettro Coenradie.
T ECHNICAL INTRODUCTION TO O SKARI FOSS4G 2015 Hanna Visuri National Land Survey of Finland
Presentation: SOAP/WS in a distributed object framework, Application Servers & AXIS SOAP.
Client Call Back Client Call Back is useful for multiple clients to keep up to date about changes on the server Example: One auction server and several.
Chapter 2 Web app architecture. High-level web app architecture  When a client request coming in and needs servlet to serve dynamic web content, what.
World Wide Web “WWW”, "Web" or "W3". World Wide Web “WWW”, "Web" or "W3"
Server-side Programming The combination of –HTML –JavaScript –DOM is sometimes referred to as Dynamic HTML (DHTML) Web pages that include scripting are.
S imple O bject A ccess P rotocol Karthikeyan Chandrasekaran & Nandakumar Padmanabhan.
Copyright 2007 SpringSource. Copying, publishing or distributing without express written permission is prohibited. Spring MVC Essentials Getting started.
JS (Java Servlets). Internet evolution [1] The internet Internet started of as a static content dispersal and delivery mechanism, where files residing.
Dyalog’08. Conga, SSL and WebServices Morten Kromberg Dyalog’08 - Elsinore.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 JSP Application Models.
CSI 3125, Preliminaries, page 1 SERVLET. CSI 3125, Preliminaries, page 2 SERVLET A servlet is a server-side software program, written in Java code, that.
E81 CSE 532S: Advanced Multi-Paradigm Software Development Venkita Subramonian, Christopher Gill, Ying Huang, Marc Sentany Department of Computer Science.
Apache Web Server Architecture Chaitanya Kulkarni MSCS rd April /23/20081Apache Web Server Architecture.
Java Programming: Advanced Topics 1 Building Web Applications Chapter 13.
WEB1P webarch1 Web architecture Dr Jim Briggs. WEB1P webarch2 What is the web? Distributed system Client-server system Characteristics of clients and.
Google Code Libraries Dima Ionut Daniel. Contents What is Google Code? LDAPBeans Object-ldap-mapping Ldap-ODM Bug4j jOOR Rapa jongo Conclusion Bibliography.
Apache Solr Dima Ionut Daniel. Contents What is Apache Solr? Architecture Features Core Solr Concepts Configuration Conclusions Bibliography.
Unlocking the Secrets of Alfresco Authentication Mehdi BELMEKKI, Consultancy Team Alfresco.
Apache Geronimo Open Source J2EE Application Server Getting up to speed with Apache Geronimo - Copyright 2005 Tom McQueeney 1 Getting up to speed with.
DEPLOYING SPDY: 5 “GOTCHAS” TO WATCH OUT FOR BY FASIHULLAH ASKIRI.
Open Source distributed document DB for an enterprise
Trustin Lee Introduction to MINA Trustin Lee
WEB API.
ESIS Consulting LLC (C) ESIS Consulting LLC. All rights reserved
Google App Engine Ying Zou 01/24/2016.
What’s new in ASP.NET Core and Entity Framework 2.2 (Preview 3)
Message Passing Systems
Presentation transcript:

Jetty 9 Dima Ionut Daniel

Contents What is Jetty? History Jetty 9 new features Jetty Configuration Deployment Arhitecture JMX SPDY Handlers WebSocket API Jetty Connectors Jetty Runner Jetty Logging Conclusions Bibliography

What is Jetty? Jetty is a pure Java HTTP server and Java Servlet container. Jetty is developed as a free and open source project as part of Eclipse Foundation. The web server is used in products like: Apache ActiveMQ, Alfresco, Apache Geronimo, Apache maven, Google App Engine, FUSE, Twitter, Zimbra.

History Jetty was originally a HTTP server component of Mort Bay Server. Jetty was originally called IssueTracker (its original application) and then MBServler (Mort Bay SERVLet servER).

Jetty 9 new features native support for modern protocols like: WebSocket, SPDY improves performance supports Servlet 3.1 and JSR-356 specifications. centralized documentation

Jetty Configuration Jetty can be started using the standalon distribution or embedded. Jetty embedded can be started using Jetty XML configuration or using POJO clases. Jetty is also an Inversion of Control(IoC) framework. Jetty can be integrated with Spring. Because the main Jetty configuration is done by IoC, the Jetty API documentation is the ultimate configuration reference.

Jetty Configuration (cont.) The Server instance is the central object of Jetty server and contains following configuration – ThreadPool: configuration for threading. – Handlers: used for incoming HTTP requests. – Server attributes: generic attribute map of attributes used by Server. – Connectors: collection of connectors that receive connections for HTTP and other protocols that Jetty supports. – Services: additional service objects.

Jetty Configuration (cont.) A Jetty Server connector is a network endpoint that accepts connections and produces requessts for the Jetty Handlers. Prior to Jetty 9, the type of the connector reflected both the protocol supported (HTTP, HTTPS, AJP, SPDY), and the nature of the implementation (NIO or BIO). From Jetty 9 onwards there is only one prime Connector type (ServerConnector), which is NIO based and uses Connection Factories to handle one or more protocols.

Deployment Arhitecture Jetty is built around an extensible Deployment Manager architecture complete with formal LifeCycle for Web Applications. For Jetty to serve content (static or dynamic), we need to create a ContextHandler and add it to Jetty in the appropriate place A pluggable DeploymentManager exists in Jetty 7 and later to make this process easier. The DeploymentManager is the heart of the typical webapp deployment mechanism. An AppProvider identifies the App and then provides it to the DeploymentManager;the main AppProvider with the Jetty distribution is the WebAppProvider.

Deployment Arhitecture (cont.) A set of default AppLifeCycle.Bindings defines standard behavior, and handles deploying, starting, stopping, and undeploying applications. There are four default bindings: – StandardDeployer: Deploys the ContextHandler into Jetty in the appropriate place. – StandardStarter: Sets the ContextHandler to started and start accepting incoming requests. – StandardStopper: Stops the ContextHandler and stops accepting incoming requests. – StandardUndeployer: Removes the ContextHandler from Jetty.

JMX The JMX API provides remote access. The MBeanContainer implementation of the Container.Listener interface coordinates creation of the MBeans. JMX is enabled by default in the jettz 9 distribution. Configuring Jetty JMX integration differs from standalone and embedded Jetty.

SPDY SPDY is an open networking protocol developed primarily at Google for transporting web content. SPDY goals: – reducing web page load latency and improving web security – achieves reduced latency through compression, multiplexing, and prioritization Implementations of SPDY exist in Chromium, Mozilla Firefox, Opera, Amazon Silk, and Internet Explorer. SPDY requires the use of SSL/TLS (with TLS extension NPN), and does not support operation over plain HTTP SPDY does not replace HTTP; it modifies the way HTTP requests and responses are sent over the wire. SPDY is a versioned protocol.

SPDY (cont.) Jetty supports both a client and a server implementation for the SPDY protocol. To provide the best support possible for SPDY, the Jetty project also provides an implementation for NPN. Both the SPDY and the NPN implementations require OpenJDK 1.7 or greater. A server deployed over TLS normally advertises the SPDY protocol via the TLS Extension Next Protocol Negotiation (NPN). Jetty's SPDY modules: – spdy-core: contains the SPDY API and a partial implementation. – spdy-jetty: binds the spdy-core module to Jetty's NIO framework to provide asynchronous socket I/O. – spdy-jetty-http: http module that provides a server-side layering of HTTP over SPDY. – spdy-jetty-http-webapp: webapp module–provides a demo application for the a spdy-jetty-http module.

Handlers Jetty contains a bundle of predefined handlers: – ResourceHandler – handles static content. – ShutdownHandler - shuts the server down on a valid request. – ErrorHandler - used to report errors from servlet contexts and webapp context. – DebugHandler - useful to debug incoming traffic. – IPAccessHandler - control is provided by white/black lists that include both internet addresses and URIs – StatisticsHandler - used to collect request statistics. – MovedContextHandler - used to relocate or redirect a context that has changed context path.

WebSocket API Jetty provides it’s own WebSocket API(event driven) for client and server. WebSocket Events: – On connect: indication that the WebSocket is now open. – On close: indication that the WebSocket is closed. – On error: In case of error occurred the WebSocket will be notified via event handler. – On message: indication that a complete message has been received. @OnWebSocketFrame.

Jetty Connectors Jetty accepts network connections using connectors, for various protocols. The configuration of an connectors involves the following: – Network parameters. – Services that connector uses. – Connection factories that instantiate and configure the protocol for the accepted connection. The standard Jetty distribution contains sample XML files for creating and configuring the connectors. Sample protocols: http, https, ssl, http2, spdy, alpn, npn. Jetty primarily uses a single connector type called ServerConnector.

Jetty Runner Jetty-runner is used to run webapp directly from the command line using a single jar and as much default configuration as possible. Jetty-runner can deploy single or multiple contexts. Example  java –jar jetty-runner.jar –port 9090 simple.war

Jetty Logging Jetty provides logging via org.eclipse.jetty.util.log.Logger layer. Jetty logging has a slightly different set of levels that uses internally: – WARN  events to inform and log but not fatal. – INFO  informational events – DEBUG  debugging events – IGNORE  exception events that can be safely ignore Jetty first tries to find jetty-logging.properties file and then tries to get system properties. Jetty tries to determine log implementation. If no logger implementation is specifies, default log will be directed to org.eclipse.jetty.util.log.StdErrLog.

Conclusions Jetty can be use as standalone or can be embedded. Jetty is documented and it’s easy to use. Jetty is stable and can be configured programatically or using external XML descriptor files. Jetty can serve 10K requests over 1 TCP/IP connection and it’s designed also for WebSocket connections. Jetty is very extensible and supports lots of protocols.

Bibliography