Download as pdf or txt
Download as pdf or txt
You are on page 1of 47

Beginning Cloud Native Development

with MicroProfile, Jakarta EE, and


Kubernetes 1st Edition Tarun Telang
Visit to download the full and correct content document:
https://ebookmass.com/product/beginning-cloud-native-development-with-microprofile
-jakarta-ee-and-kubernetes-1st-edition-tarun-telang/
Tarun Telang

Beginning Cloud Native Development


with MicroProfile, Jakarta EE, and
Kubernetes
Java DevOps for Building and Deploying
Microservices-based Applications
Tarun Telang
Hyderabad, India

ISBN 978-1-4842-8831-3 e-ISBN 978-1-4842-8832-0


https://doi.org/10.1007/978-1-4842-8832-0

© Tarun Telang 2023

This work is subject to copyright. All rights are solely and exclusively
licensed by the Publisher, whether the whole or part of the material is
concerned, specifically the rights of translation, reprinting, reuse of
illustrations, recitation, broadcasting, reproduction on microfilms or in
any other physical way, and transmission or information storage and
retrieval, electronic adaptation, computer software, or by similar or
dissimilar methodology now known or hereafter developed.

The use of general descriptive names, registered names, trademarks,


service marks, etc. in this publication does not imply, even in the
absence of a specific statement, that such names are exempt from the
relevant protective laws and regulations and therefore free for general
use.

The publisher, the authors, and the editors are safe to assume that the
advice and information in this book are believed to be true and accurate
at the date of publication. Neither the publisher nor the authors or the
editors give a warranty, expressed or implied, with respect to the
material contained herein or for any errors or omissions that may have
been made. The publisher remains neutral with regard to jurisdictional
claims in published maps and institutional affiliations.

This Apress imprint is published by the registered company APress


Media, LLC, part of Springer Nature.
The registered company address is: 1 New York Plaza, New York, NY
10004, U.S.A.
This book is dedicated to my grandparents, parents, wife Nikita, and son
Vihan. They have always been a source of inspiration and encouragement
to me. It’s also for all of the software and technology creators who work
hard to make our planet a better place to live.
—Tarun Telang
Introduction
Cloud-native applications are becoming increasingly popular due to
their many benefits, such as scalability, flexibility, and efficiency. Cloud-
native applications are designed to take advantage of the cloud
paradigm. It means that they are distributed, scalable, resilient, and
elastic. You can run them on public, private, or hybrid clouds. To build
cloud-native applications, developers must use the right tools and
technologies.
Enterprise Java (or Jakarta Enterprise Edition) is a popular platform
for cloud-native applications. It provides a set of standards and APIs
that help developers build enterprise-grade applications. Many
platform vendors, including Red Hat, IBM, and Oracle, support this
standard. It offers a number features that make it an ideal choice for
developing cloud-native applications.
The MicroProfile initiative was started in 2016 by Red Hat, IBM,
Tomitribe, and Payara. The group aims to improve the application
developer experience in a microservices environment by providing a
baseline platform definition that multiple runtimes can implement. The
group released the first version of the MicroProfile specification in June,
2016. The specification includes a set of APIs for application
developers, including RESTful web services , context and dependency
injection, and JSON processing.
MicroProfile is a set of specifications that define how developers
can use Jakarta EE to build microservices. It also provides a platform
that helps developers create cloud-native applications. MicroProfile is
aligning its specifications with the Jakarta EE platform. The goal of the
MicroProfile group is to create a set of standards that developers can
use to develop microservices on top of the Jakarta EE platform. The
Eclipse Foundation, the home of the Jakarta EE project, also manages
the creation of MicroProfile standards.
MicroProfile is a Jakarta EE Working Group. It was created in
response to the popularity of microservices. It also addresses the need
for a standard platform for developing microservices. It initially
consisted of a few Jakarta EE vendors (IBM, Red Hat, Payara, and
Tomitribe) and has grown to include more than 25 members, including
Oracle, Microsoft, Hazelcast, and more. The Eclipse Foundation governs
the MicroProfile initiative, and the MicroProfile specification is
developed through the Eclipse MicroProfile project. The project is open
to all individuals and organizations that want to contribute. The
MicroProfile specification is developed openly and transparently, and
all contributions are welcomed. The Eclipse MicroProfile project uses a
collaborative development process, and all interested parties are
encouraged to participate.
Docker is a software container platform that allows developers to
package an application with all its dependencies into a standardized
unit for software development. You can run Docker containers on any
platform, including public, private, and hybrid clouds. It makes it easy
to deploy applications on any platform, including cloud platforms.
Docker is a popular open-source container platform that you can use to
package and run microservices. It provides several advantages over
traditional virtualization technologies, including portability, ease of use,
and more.
Kubernetes is a tool for managing containerized applications. It
provides an open-source platform for deploying, managing, and scaling
applications. Kubernetes is based on the Linux kernel and can use
Docker containers to manage applications. It provides features such as
scaling, load balancing, and self-healing.
Kubernetes automates the deployment, scaling, and management of
containerized apps. It supports easy management and discovery of
your applications by grouping containers into logical units. Kubernetes
is built on decades of experience at Google running production
workloads at scale, as well as adopting the best-of-breed ideas and
practices from the community.
Kubernetes is portable and extensible, allowing it to run anywhere,
from your laptop to public clouds to data centers. The simplicity and
flexibility of Kubernetes make it an excellent choice for cloud-native
applications. In addition, it’s open-source software, allowing you to take
advantage of community innovations.
Kubernetes is production-ready, with robust features and
capabilities to orchestrate your containerized applications. Kubernetes
has been battle-tested at scale, running some of the largest sites in the
world.
In this book, you learn how to use MicroProfile and Jakarta EE
technologies to develop microservices, deploy them on
Kubernetes/Docker, and create cloud-native applications. The book also
covers best practices for developing cloud-native applications with
MicroProfile and Jakarta EE. It starts by looking at the different aspects
of cloud-native applications. You will then move on to setting up your
development environment and learning about the basics of Jakarta EE.
Next, the book explores the features of MicroProfile and you’ll learn
how to use them to build microservices. You will then learn about
Docker and Kubernetes and how to use them to deploy your
applications. Finally, you will put everything together and learn how to
build a complete cloud-native application.
Who This Book Is For
Welcome to Beginning Cloud Native Development with MicroProfile,
Jakarta EE, and Kubernetes.
This book is for Java developers who want to learn how to develop
cloud-native applications using MicroProfile and Jakarta EE. No prior
knowledge of Kubernetes or container orchestration is required.
In this book, you learn how to develop cloud-native applications
using MicroProfile and Jakarta EE and deploy them to Kubernetes. The
book covers topics such as writing RESTful web services, creating
microservices, configuring health checks, and more.
By the end of this book, you will be able to develop cloud-native
applications using MicroProfile and Jakarta EE and deploy them to
Kubernetes.
How This Book Is Structured
This book covers four main topics.
Cloud-native development introduces the concept of cloud-native
development and the twelve-factor app methodology. You learn
about the benefits of developing cloud-native applications and the
challenges you must consider when migrating existing applications
to the cloud.
MicroProfile specifications provides an overview of the
MicroProfile specifications and how they can be used to develop
microservices. You learn about the different types of annotations
available and how to use them to create RESTful web services .
Jakarta EE specifications introduces the Jakarta EE platform and its
various specifications. You learn about the differences between Java
EE and Jakarta EE and the new features available on the platform.
Kubernetes covers the basics of container orchestration with
Kubernetes. You learn about the different types of objects created in
a Kubernetes cluster, how to deploy applications to Kubernetes, and
how to scale applications using Kubernetes.

Conventions
Throughout the book, I use a consistent style for presenting Java code,
SQL, command-line text, and results. When pieces of code, SQL,
reserved words, or code fragments are presented in the text, they are
presented in fixed-width Courier font, such as this (working) example:

public class MyExample {


public static void main(String[] args){
System.out.println("Jakarta EE is
excellent!");
}
}

Downloading the Code


The code examples in this book are available at
github.com/apress/beginning-cloud-native-dev-
microprofile-jakarta-kubernetes.

Note The sources for this book may change over time, in order to
incorporate the most up-to-date features in Jakarta EE, MicroProfile,
and the Kubernetes platform. If you find any issues in the sources,
please submit them via the book’s GitHub repo and the code will be
adjusted accordingly.
Any source code or other supplementary material referenced by the
author in this book is available to readers on GitHub
(https://github.com/Apress). For more detailed information, please
visit http://www.apress.com/source-code.
Acknowledgments
I would like to thank my wife, Nikita, and son, Vihan, for their patience
and love throughout the process of writing this book. I am indebted to
all my mentors and friends who encouraged me to keep on growing
during every phase of my professional career.
I’d like to thank my parents for pushing me in the right direction
with technology and always supporting me every step of the way, even
when I decided to do something completely different than they
expected. It’s also important to note that without them, I probably
wouldn’t have become a developer and had such a great career. Lastly,
thanks again go out to my wife (and soulmate), Nikita. It’s an incredible
feeling to be with someone who keeps you motivated and challenges
you, not only professionally but personally.
Thank you for always being there for me!
I’d like to send a special thanks to Pramit Das and Massimo Nardone
(technical reviewers), for their impeccable work on this book. I also
greatly appreciate Steve Anglin, Mark Powers, and everyone at Apress
Media (apress.com) for their support in getting this book published.
Last, but not least, I would like to thank you, the reader, for taking
the time to read this book. I hope that it will help you in your journey of
becoming a better Jakarta EE developer.
Table of Contents
Chapter 1:​Introduction to Cloud Computing
Introduction to Cloud Computing
Examples of Cloud Computing
Benefits of Cloud Computing
Essential Characteristics of Cloud Computing
Types of Cloud Computing Based on Deployment Models
Public Cloud
Community Cloud
Private Cloud
Hybrid Cloud
Service Models of Cloud Computing
Software as a Service (SaaS)
Platform as a Service (PaaS)
Infrastructure as a Service (IaaS)
The Role of Java in Cloud Computing
The Evolution of Cloud Computing
Summary
Chapter 2:​Cloud-Native Application Development
What Is Cloud-Native?​
Characteristics of Cloud-Native Applications
Examples of Cloud-Native Applications
Benefits of Cloud-Native Applications
Drawbacks of Using Cloud-Native Applications
Cloud-Native Applications vs.​Traditional Applications
Cloud-Native Application Development
Managed Services for Java-Based Applications
Examples of Cloud-Native Application Development
Cloud-Native Application Development Is the Future
Phases of Cloud-Native Application Development
Summary
Chapter 3:​Setting Up Your Development Environment
Prerequisites
Hardware Requirements
Installing Java Development Kit (JDK)
Using Maven
Installing Maven
Git
Installing Git
Creating a GitHub Account
Creating a GitHub Repository
Pushing Code to a GitHub Repository
Using Docker
Benefits of Using Docker
Installing Docker
Docker Hub
Using Kubernetes
Installing Kubernetes
Configuring Docker for Kubernetes
Creating a Kubernetes Cluster
Using Zipkin
Installing Zipkin
Integrated Development Environments (IDE)
Summary
Chapter 4:​Building RESTful Web Services
REST:​An Architectural Style for Building Web Services
Introduction to Open Liberty Runtime
Key Features of the Open Liberty Application Server
Downloading and Installing Open Liberty
Starting the Open Liberty Server
Printing a List of Features on the Open Liberty Server
Creating a Server Instance
Stopping the Open Liberty Server
Configuring the Server
Creating a RESTful Web Service in Open Liberty
Creating a RESTful API
Summary
Chapter 5:​Microservices Architecture
Vertical Scaling
Horizontal Scaling
Vertical vs.​Horizontal Scaling
History of Service-Based Architecture
Types of Service-Based Architectures
Service-Oriented Architecture (SOA)
What Is a Web Service?​
What Is SOAP?​
What Is REST?​
REST vs.​SOAP
The Monolithic Architecture
Evolution of the Microservices Architecture
Benefits of Microservices Architectures
Drawbacks of Microservices Architectures
Design Considerations
Using Microservices in Cloud-Native Applications
Cloud-Native Twelve-Factor Applications
What Is a Virtual Machine?​
What Are Containers?​
What Are Container-Based Applications?​
What Are Serverless Applications?​
Where Is Serverless Computing Used?​
Benefits of Serverless Computing
Drawbacks of Serverless Computing
Popular Serverless Platforms
Main Components of a Serverless Computing Platform
Serverless Applications vs.​Containers
Microservice Deployment Patterns
Key Considerations
Microservices Deployment Strategies and Patterns
Microservices Management
Summary
Chapter 6:​The Eclipse MicroProfile Framework
What Is the Eclipse MicroProfile Framework?​
Layers of Functionality in MicroProfile
Popular Implementations of the Eclipse MicroProfile
Framework
MicroProfile Config
The MicroProfile Health Check Specification
The MicroProfile Fault Tolerance Component
Key Features of the Fault Tolerance Component
Fault Tolerance API
Summary
Chapter 7:​MicroProfile Framework – Part 2
The MicroProfile Metrics Specification
Types of Metrics
Metrics Components
Metrics Annotations
Maven Dependency
Tracking Response Time Using @Timed
Tracking the Number of Invocations
Tracking Memory Usage
MetricRegistry
Creating Custom Metrics
Using Open Tracing
Distributed Tracing
How Does It Work?​
Using the Jakarta RESTful Web Service
Using the MicroProfile OpenAPI Specification
OpenAPI
Capabilities of the MicroProfile OpenAPI Specification
Generating OpenAPI Documents
Using the MicroProfile OpenAPI in Your Project
MicroProfile OpenAPI Annotations
Summary
Chapter 8:​MicroProfile JSON Web Tokens and Jakarta Security
Security Best Practices for Microservices
What Is a JSON Web Token (JWT)?​
Use Cases for JSON Web Tokens
Authentication
Authorization
Session Information
Claims-Based Identity
Information Exchange
Federation
Creating and Signing a JWT
Testing the Application
Verifying and Validating a JWT
Using JWT in a Microservice Environment
Securing a RESTful Application
Securing a REST Resource
The @RolesAllowed Annotation
The @Claim Annotation
The @HeaderParam Annotation
Configuring a JWK Set or PEM-Encoded Public Key
Public Key Cryptography Standards #8 in PEM Format
JSON Web Key (JWK)
JSON Web Key Set (JWKS)
The Jakarta EE Security Specification
Securing a Servlet Using Jakarta Security
The MicroProfile REST Client
The @RegisterClient Annotation
Configuring Your REST Client
REST Client Interface
Documenting RESTful APIs Using MicroProfile OpenAPI
What Is the OpenAPI Specification?​
What Is MicroProfile OpenAPI?​
Summary
Chapter 9:​Containerizing Microservices Using Kubernetes
What Are Containers?​
Why Use Containers?​
What Is Container Orchestration?​
The Benefits of Using Container Orchestration
Understanding Kubernetes Terminology
The Key Features of Kubernetes
Using Kubernetes
Using Docker Containers
Running a MicroProfile Application in Docker
Pushing the Docker Image to Docker Hub
Scaling Your Deployment
Summary
Appendix A:​Introduction to Maven
Appendix B:​Creating an Open Liberty Project Using Maven
Appendix C:​Installing Open Liberty Tools
Index
About the Author
Tarun Telang
is a hands-on technologist with extensive
experience in the design and
implementation of multitiered, highly
scalable software applications. He has
been part of several well-known
companies, including Microsoft, Oracle,
Polycom, and SAP. He has over 17 years
of experience in architecting and
developing business applications.
He began his career as an enterprise
Java developer at SAP, where he
developed distributed application
software for big firms. He got his start
with enterprise session beans and
message-driven beans, as well as instrumenting enterprise
applications’ configuration and management using the Java
Management Extensions (JMX) technology.
He quickly mastered various enterprise technologies, including the
Enterprise Beans, Java Management Extensions, Servlets, and Server
Pages technologies, and in his first year as a developer, he became a Sun
Certified Programmer for the Java Platform, Standard Edition 6, and an
SAP Certified Development Consultant for the SAP NetWeaver Java Web
Application Server (which was a Java EE 5-compliant application
server).
He also gained expertise in XML technologies like XSLT and XSD. He
developed several solutions using session beans and message-driven
beans to handle message-oriented communications across numerous
systems. In 2007, Tarun was named an SAP Mentor and Community
Influencer for his articles and blog posts on emerging technologies and
for promoting innovative solutions in the SAP Developer Community.
He frequently writes articles on Java and related technologies. Tarun
has also authored multiple online courses, including a best-selling
course on the YAML data serialization language.
He has presented technical lectures at several developer
conferences, including SAP TechEd and the Great Indian Developer
Summit. He has been presenting at conferences for more than 15 years
and actively publishes technical papers and blogs to assist everyone in
grasping the fundamentals of software technology. Tarun developed
cloud-based video conferencing applications using a microservices
architecture with the Spring framework and has experience working
with Persistence APIs and the Hazelcast framework for building REST-
based services.
He also developed many end-to-end cloud-based solutions using
various architectural patterns, including microservices and service-
oriented architectures. Tarun has gained expertise in web, mobile, and
cloud technologies. He is also knowledgeable in applied agile
methodologies, including user-centric and mobile-first design for
managing projects with cross-functional teams located in multiple
geographies. Tarun is the co-author of Java EE to Jakarta EE 10 Recipes:
A Problem-Solution Approach for Enterprise Java (Apress, 2022).
Having previously worked in Canada and Germany, Tarun currently
resides in Hyderabad, India with his wife and son. You can follow him
on LinkedIn ( www.linkedin.com/in/taruntelang/ ), Facebook
( www.facebook.com/tarun.telang ), and Twitter
(@taruntelang). His blog at https://blogs.taruntelang.me
is an excellent resource for all things related to software technology!
About the Technical Reviewers
Massimo Nardone
has more than 25 years of experience in
security, web/mobile development,
cloud, and IT architecture. His true IT
passions are security and Android. He
has been programming and teaching
others how to program with Android,
Perl, PHP, Java, VB, Python, C/C++, and
MySQL for more than 20 years. He holds
a Master of Science degree in computing
science from the University of Salerno,
Italy.
He has worked as a CISO, CSO,
security executive, IoT executive, project
manager, software engineer, research
engineer, chief security architect,
PCI/SCADA auditor, and senior lead IT security/cloud/SCADA architect
for many years. His technical skills include security, Android, cloud,
Java, MySQL, Drupal, Cobol, Perl, web and mobile development,
MongoDB, D3, Joomla, Couchbase, C/C++, WebGL, Python, Pro Rails,
Django CMS, Jekyll, Scratch, and more.
He was a visiting lecturer and supervisor for exercises at the
Networking Laboratory of the Helsinki University of Technology (Aalto
University). He also holds four international patents (in the PKI, SIP,
SAML, and Proxy areas). He is currently working for Cognizant as head
of cybersecurity and CISO to help clients in areas of information and
cybersecurity, including strategy, planning, processes, policies,
procedures, governance, awareness, and so forth. In June, 2017, he
became a permanent member of the ISACA Finland Board.
Massimo has reviewed more than 45 IT books for different
publishing companies and is the co-author of Pro Spring Security:
Securing Spring Framework 5 and Boot 2-based Java Applications
(Apress, 2019), Beginning EJB in Java EE 8 (Apress, 2018), Pro JPA 2 in
Java EE 8 (Apress, 2018), and Pro Android Games (Apress, 2015)
Pramit Das
has more than 12 years of experience in
software design and development across
multiple platforms using various
technology stacks. He is extremely
passionate about programming and
exploring new and upcoming
technologies. He has extensive hands-on
experience with programming languages
like C/C++, Java, Scala, JavaScript, and
Python, along with their respective tools,
libraries, and frameworks, including
Spring, Django, NodeJs, and Spark. He
also has excellent knowledge of backend
storage solutions from Oracle, MySQL,
MongoDB, and Cassandra, as well as
other cloud-based managed services.
Academically, Pramit received his Bachelor’s of Technology from
NIT, Rourkela in Computer Science & Engineering, graduating in 2009.
He has experience in product- and service-based industries and is
currently working for the cloud giant Salesforce as a full-time engineer.
© The Author(s), under exclusive license to APress Media, LLC, part of Springer
Nature 2023
T. Telang, Beginning Cloud Native Development with MicroProfile, Jakarta EE, and
Kubernetes
https://doi.org/10.1007/978-1-4842-8832-0_1

1. Introduction to Cloud Computing


Tarun Telang1

(1) Hyderabad, India

Cloud computing is the latest buzzword in the technology industry, and


for good reason. It has the potential to revolutionize the way people use
computers. This chapter introduces cloud computing and explains what
it is. You will also look at some examples of cloud computing and learn
about the benefits of using this new technology. Finally, you will explore
the different types of cloud computing and see how they have evolved
over time.

Introduction to Cloud Computing


Cloud computing is a type of computing where resources, such as
applications and data, are stored on remote servers and accessed over
the Internet. Instead of having a program installed on your computer,
you can access or keep programs on a remote server. As a result, you
can access your data from any device with an Internet connection,
whether it’s a desktop computer, laptop, tablet, or smartphone.
Cloud computing has the following key benefits . It enables
ubiquitous, convenient, on-demand network access to a shared pool of
configurable computing resources (e.g., networks, servers, storage,
applications, and services) that can be rapidly provisioned and released
with minimal management effort or service provider interaction. Figure
1-1 illustrates how end-users access cloud computing .
Figure 1-1 Cloud computing
Cloud computing also has environmental benefits because it
reduces the need for energy-intensive hardware.

Examples of Cloud Computing


There are many different examples of cloud computing, but some of the
most common ones include :
Email: Gmail, Yahoo Mail, and Outlook.com are all examples of email
services that are based in the cloud. This means that you can check
your email on your smartphone, tablet, or desktop computer,
regardless of where you are in the world. The ability to access your
email from any device with an Internet connection is an example of
cloud computing. This is an excellent feature if you need to check
your email while you’re on vacation or traveling for work. Further, if
you accidentally delete an email, it can be quickly recovered from the
cloud.
Cloud storage: Dropbox, Google Drive, and iCloud are all examples of
cloud storage services . This means that instead of storing files on
your computer, you can store them online. This gives you the ability
to access those files from any device with an Internet connection.
Web-based productivity software: Google Docs, Sheets, and Slides
are all examples of productivity software that is based in the cloud.
This means that instead of having a program installed on your
computer, you can create and edit documents, spreadsheets, and
presentations from any device with an Internet connection. Cloud
storage is better than having documents on your computer because
you can access them from any device that has an Internet connection.
This is helpful if you need to work on a document from different
places or if you accidentally delete one. Additionally, cloud storage
makes it easier for people to collaborate on projects because they can
all work on the document simultaneously without having to worry
about emailing each other versions of the document.
Multimedia streaming: Netflix, Vimeo, and YouTube are all
examples of video streaming services, whereas Spotify, Apple Music,
and Pandora are all examples of music streaming services that are
based in the cloud. This means that instead of downloading media
(video or song) to your computer, you can watch it from any device
with an Internet connection . Media streaming is popular because it
doesn’t take up any space on your device, and you can watch videos
without waiting for them to download. Figure 1-2 shows different
types of cloud computing applications. These are just a few examples
of cloud computing. As you can see, cloud computing can be very
helpful in various ways.
Figure 1-2 Cloud computing application types

Benefits of Cloud Computing


In recent years, the use of cloud computing has grown exponentially.
This is because cloud computing can provide several benefits, such as
the following:
Cost savings: Cloud computing can save you money on hardware and
software costs. For example, you can use a cloud-based storage
service instead of buying a physical hard drive. Cloud-based storage
can be more cost-effective than buying a physical hard drive. This is
because you don’t have to buy expensive hardware, like a computer.
You also save money on software costs by using a cloud-based
application instead of buying a software program for your local
machine. This is a significant benefit of cloud-based solutions—you
don’t have to worry about capital expenditure for hardware and
software, regular patching, or data center upkeep. The provider takes
Another random document with
no related content on Scribd:
Plate XXXVII.
“Mdlle. Parisot.”
Stipple-Engraving by C. Turner, A.R.A.,
after J. J. Masquerier.
(Published 1799. Size 6⅝″ × 8⅜″.)
From the collection of Mrs. Julia Frankau,
to whom it was presented by the late Sir Henry Irving.
Plate XXXVIII.
“Maria.”
Stipple-Engraving by P. W. Tomkins, after J. Russell, R.A.
(Published 1791. Size 4¾″ × 6¼″.)
From the collection of Frederick Behrens, Esq.
Plate XXXIX.
“Commerce.”
Stipple-Engraving by M. Bovi, after J. B. Cipriani, R.A.
and F. Bartolozzi, R.A.
(Published 1795. Size 18⅜″ × 7⅝″.)
From the collection of Basil Dighton, Esq.
Plate XL.
“The Love-Letter.”
A very rare Stipple-Engraving, probably by Thos. Cheesman.
and F. Bartolozzi, R.A.
(Size 8¾″ × 6¾″.)
From the collection of Major E. F. Coates, M.P.
*** END OF THE PROJECT GUTENBERG EBOOK OLD ENGLISH
COLOUR PRINTS ***

Updated editions will replace the previous one—the old editions


will be renamed.

Creating the works from print editions not protected by U.S.


copyright law means that no one owns a United States copyright
in these works, so the Foundation (and you!) can copy and
distribute it in the United States without permission and without
paying copyright royalties. Special rules, set forth in the General
Terms of Use part of this license, apply to copying and
distributing Project Gutenberg™ electronic works to protect the
PROJECT GUTENBERG™ concept and trademark. Project
Gutenberg is a registered trademark, and may not be used if
you charge for an eBook, except by following the terms of the
trademark license, including paying royalties for use of the
Project Gutenberg trademark. If you do not charge anything for
copies of this eBook, complying with the trademark license is
very easy. You may use this eBook for nearly any purpose such
as creation of derivative works, reports, performances and
research. Project Gutenberg eBooks may be modified and
printed and given away—you may do practically ANYTHING in
the United States with eBooks not protected by U.S. copyright
law. Redistribution is subject to the trademark license, especially
commercial redistribution.

START: FULL LICENSE


THE FULL PROJECT GUTENBERG LICENSE
PLEASE READ THIS BEFORE YOU DISTRIBUTE OR USE THIS WORK

To protect the Project Gutenberg™ mission of promoting the


free distribution of electronic works, by using or distributing this
work (or any other work associated in any way with the phrase
“Project Gutenberg”), you agree to comply with all the terms of
the Full Project Gutenberg™ License available with this file or
online at www.gutenberg.org/license.

Section 1. General Terms of Use and


Redistributing Project Gutenberg™
electronic works
1.A. By reading or using any part of this Project Gutenberg™
electronic work, you indicate that you have read, understand,
agree to and accept all the terms of this license and intellectual
property (trademark/copyright) agreement. If you do not agree to
abide by all the terms of this agreement, you must cease using
and return or destroy all copies of Project Gutenberg™
electronic works in your possession. If you paid a fee for
obtaining a copy of or access to a Project Gutenberg™
electronic work and you do not agree to be bound by the terms
of this agreement, you may obtain a refund from the person or
entity to whom you paid the fee as set forth in paragraph 1.E.8.

1.B. “Project Gutenberg” is a registered trademark. It may only


be used on or associated in any way with an electronic work by
people who agree to be bound by the terms of this agreement.
There are a few things that you can do with most Project
Gutenberg™ electronic works even without complying with the
full terms of this agreement. See paragraph 1.C below. There
are a lot of things you can do with Project Gutenberg™
electronic works if you follow the terms of this agreement and
help preserve free future access to Project Gutenberg™
electronic works. See paragraph 1.E below.
1.C. The Project Gutenberg Literary Archive Foundation (“the
Foundation” or PGLAF), owns a compilation copyright in the
collection of Project Gutenberg™ electronic works. Nearly all the
individual works in the collection are in the public domain in the
United States. If an individual work is unprotected by copyright
law in the United States and you are located in the United
States, we do not claim a right to prevent you from copying,
distributing, performing, displaying or creating derivative works
based on the work as long as all references to Project
Gutenberg are removed. Of course, we hope that you will
support the Project Gutenberg™ mission of promoting free
access to electronic works by freely sharing Project
Gutenberg™ works in compliance with the terms of this
agreement for keeping the Project Gutenberg™ name
associated with the work. You can easily comply with the terms
of this agreement by keeping this work in the same format with
its attached full Project Gutenberg™ License when you share it
without charge with others.

1.D. The copyright laws of the place where you are located also
govern what you can do with this work. Copyright laws in most
countries are in a constant state of change. If you are outside
the United States, check the laws of your country in addition to
the terms of this agreement before downloading, copying,
displaying, performing, distributing or creating derivative works
based on this work or any other Project Gutenberg™ work. The
Foundation makes no representations concerning the copyright
status of any work in any country other than the United States.

1.E. Unless you have removed all references to Project


Gutenberg:

1.E.1. The following sentence, with active links to, or other


immediate access to, the full Project Gutenberg™ License must
appear prominently whenever any copy of a Project
Gutenberg™ work (any work on which the phrase “Project
Gutenberg” appears, or with which the phrase “Project
Gutenberg” is associated) is accessed, displayed, performed,
viewed, copied or distributed:

This eBook is for the use of anyone anywhere in the United


States and most other parts of the world at no cost and with
almost no restrictions whatsoever. You may copy it, give it
away or re-use it under the terms of the Project Gutenberg
License included with this eBook or online at
www.gutenberg.org. If you are not located in the United
States, you will have to check the laws of the country where
you are located before using this eBook.

1.E.2. If an individual Project Gutenberg™ electronic work is


derived from texts not protected by U.S. copyright law (does not
contain a notice indicating that it is posted with permission of the
copyright holder), the work can be copied and distributed to
anyone in the United States without paying any fees or charges.
If you are redistributing or providing access to a work with the
phrase “Project Gutenberg” associated with or appearing on the
work, you must comply either with the requirements of
paragraphs 1.E.1 through 1.E.7 or obtain permission for the use
of the work and the Project Gutenberg™ trademark as set forth
in paragraphs 1.E.8 or 1.E.9.

1.E.3. If an individual Project Gutenberg™ electronic work is


posted with the permission of the copyright holder, your use and
distribution must comply with both paragraphs 1.E.1 through
1.E.7 and any additional terms imposed by the copyright holder.
Additional terms will be linked to the Project Gutenberg™
License for all works posted with the permission of the copyright
holder found at the beginning of this work.

1.E.4. Do not unlink or detach or remove the full Project


Gutenberg™ License terms from this work, or any files
containing a part of this work or any other work associated with
Project Gutenberg™.
1.E.5. Do not copy, display, perform, distribute or redistribute
this electronic work, or any part of this electronic work, without
prominently displaying the sentence set forth in paragraph 1.E.1
with active links or immediate access to the full terms of the
Project Gutenberg™ License.

1.E.6. You may convert to and distribute this work in any binary,
compressed, marked up, nonproprietary or proprietary form,
including any word processing or hypertext form. However, if
you provide access to or distribute copies of a Project
Gutenberg™ work in a format other than “Plain Vanilla ASCII” or
other format used in the official version posted on the official
Project Gutenberg™ website (www.gutenberg.org), you must, at
no additional cost, fee or expense to the user, provide a copy, a
means of exporting a copy, or a means of obtaining a copy upon
request, of the work in its original “Plain Vanilla ASCII” or other
form. Any alternate format must include the full Project
Gutenberg™ License as specified in paragraph 1.E.1.

1.E.7. Do not charge a fee for access to, viewing, displaying,


performing, copying or distributing any Project Gutenberg™
works unless you comply with paragraph 1.E.8 or 1.E.9.

1.E.8. You may charge a reasonable fee for copies of or


providing access to or distributing Project Gutenberg™
electronic works provided that:

• You pay a royalty fee of 20% of the gross profits you derive from
the use of Project Gutenberg™ works calculated using the
method you already use to calculate your applicable taxes. The
fee is owed to the owner of the Project Gutenberg™ trademark,
but he has agreed to donate royalties under this paragraph to
the Project Gutenberg Literary Archive Foundation. Royalty
payments must be paid within 60 days following each date on
which you prepare (or are legally required to prepare) your
periodic tax returns. Royalty payments should be clearly marked
as such and sent to the Project Gutenberg Literary Archive
Foundation at the address specified in Section 4, “Information
about donations to the Project Gutenberg Literary Archive
Foundation.”

• You provide a full refund of any money paid by a user who


notifies you in writing (or by e-mail) within 30 days of receipt that
s/he does not agree to the terms of the full Project Gutenberg™
License. You must require such a user to return or destroy all
copies of the works possessed in a physical medium and
discontinue all use of and all access to other copies of Project
Gutenberg™ works.

• You provide, in accordance with paragraph 1.F.3, a full refund of


any money paid for a work or a replacement copy, if a defect in
the electronic work is discovered and reported to you within 90
days of receipt of the work.

• You comply with all other terms of this agreement for free
distribution of Project Gutenberg™ works.

1.E.9. If you wish to charge a fee or distribute a Project


Gutenberg™ electronic work or group of works on different
terms than are set forth in this agreement, you must obtain
permission in writing from the Project Gutenberg Literary
Archive Foundation, the manager of the Project Gutenberg™
trademark. Contact the Foundation as set forth in Section 3
below.

1.F.

1.F.1. Project Gutenberg volunteers and employees expend


considerable effort to identify, do copyright research on,
transcribe and proofread works not protected by U.S. copyright
law in creating the Project Gutenberg™ collection. Despite
these efforts, Project Gutenberg™ electronic works, and the
medium on which they may be stored, may contain “Defects,”
such as, but not limited to, incomplete, inaccurate or corrupt
data, transcription errors, a copyright or other intellectual
property infringement, a defective or damaged disk or other
medium, a computer virus, or computer codes that damage or
cannot be read by your equipment.

1.F.2. LIMITED WARRANTY, DISCLAIMER OF DAMAGES -


Except for the “Right of Replacement or Refund” described in
paragraph 1.F.3, the Project Gutenberg Literary Archive
Foundation, the owner of the Project Gutenberg™ trademark,
and any other party distributing a Project Gutenberg™ electronic
work under this agreement, disclaim all liability to you for
damages, costs and expenses, including legal fees. YOU
AGREE THAT YOU HAVE NO REMEDIES FOR NEGLIGENCE,
STRICT LIABILITY, BREACH OF WARRANTY OR BREACH
OF CONTRACT EXCEPT THOSE PROVIDED IN PARAGRAPH
1.F.3. YOU AGREE THAT THE FOUNDATION, THE
TRADEMARK OWNER, AND ANY DISTRIBUTOR UNDER
THIS AGREEMENT WILL NOT BE LIABLE TO YOU FOR
ACTUAL, DIRECT, INDIRECT, CONSEQUENTIAL, PUNITIVE
OR INCIDENTAL DAMAGES EVEN IF YOU GIVE NOTICE OF
THE POSSIBILITY OF SUCH DAMAGE.

1.F.3. LIMITED RIGHT OF REPLACEMENT OR REFUND - If


you discover a defect in this electronic work within 90 days of
receiving it, you can receive a refund of the money (if any) you
paid for it by sending a written explanation to the person you
received the work from. If you received the work on a physical
medium, you must return the medium with your written
explanation. The person or entity that provided you with the
defective work may elect to provide a replacement copy in lieu
of a refund. If you received the work electronically, the person or
entity providing it to you may choose to give you a second
opportunity to receive the work electronically in lieu of a refund.
If the second copy is also defective, you may demand a refund
in writing without further opportunities to fix the problem.

1.F.4. Except for the limited right of replacement or refund set


forth in paragraph 1.F.3, this work is provided to you ‘AS-IS’,
WITH NO OTHER WARRANTIES OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO
WARRANTIES OF MERCHANTABILITY OR FITNESS FOR
ANY PURPOSE.

1.F.5. Some states do not allow disclaimers of certain implied


warranties or the exclusion or limitation of certain types of
damages. If any disclaimer or limitation set forth in this
agreement violates the law of the state applicable to this
agreement, the agreement shall be interpreted to make the
maximum disclaimer or limitation permitted by the applicable
state law. The invalidity or unenforceability of any provision of
this agreement shall not void the remaining provisions.

1.F.6. INDEMNITY - You agree to indemnify and hold the


Foundation, the trademark owner, any agent or employee of the
Foundation, anyone providing copies of Project Gutenberg™
electronic works in accordance with this agreement, and any
volunteers associated with the production, promotion and
distribution of Project Gutenberg™ electronic works, harmless
from all liability, costs and expenses, including legal fees, that
arise directly or indirectly from any of the following which you do
or cause to occur: (a) distribution of this or any Project
Gutenberg™ work, (b) alteration, modification, or additions or
deletions to any Project Gutenberg™ work, and (c) any Defect
you cause.

Section 2. Information about the Mission of


Project Gutenberg™
Project Gutenberg™ is synonymous with the free distribution of
electronic works in formats readable by the widest variety of
computers including obsolete, old, middle-aged and new
computers. It exists because of the efforts of hundreds of
volunteers and donations from people in all walks of life.

Volunteers and financial support to provide volunteers with the


assistance they need are critical to reaching Project
Gutenberg™’s goals and ensuring that the Project Gutenberg™
collection will remain freely available for generations to come. In
2001, the Project Gutenberg Literary Archive Foundation was
created to provide a secure and permanent future for Project
Gutenberg™ and future generations. To learn more about the
Project Gutenberg Literary Archive Foundation and how your
efforts and donations can help, see Sections 3 and 4 and the
Foundation information page at www.gutenberg.org.

Section 3. Information about the Project


Gutenberg Literary Archive Foundation
The Project Gutenberg Literary Archive Foundation is a non-
profit 501(c)(3) educational corporation organized under the
laws of the state of Mississippi and granted tax exempt status by
the Internal Revenue Service. The Foundation’s EIN or federal
tax identification number is 64-6221541. Contributions to the
Project Gutenberg Literary Archive Foundation are tax
deductible to the full extent permitted by U.S. federal laws and
your state’s laws.

The Foundation’s business office is located at 809 North 1500


West, Salt Lake City, UT 84116, (801) 596-1887. Email contact
links and up to date contact information can be found at the
Foundation’s website and official page at
www.gutenberg.org/contact

Section 4. Information about Donations to


the Project Gutenberg Literary Archive
Foundation
Project Gutenberg™ depends upon and cannot survive without
widespread public support and donations to carry out its mission
of increasing the number of public domain and licensed works
that can be freely distributed in machine-readable form
accessible by the widest array of equipment including outdated
equipment. Many small donations ($1 to $5,000) are particularly
important to maintaining tax exempt status with the IRS.

The Foundation is committed to complying with the laws


regulating charities and charitable donations in all 50 states of
the United States. Compliance requirements are not uniform
and it takes a considerable effort, much paperwork and many
fees to meet and keep up with these requirements. We do not
solicit donations in locations where we have not received written
confirmation of compliance. To SEND DONATIONS or
determine the status of compliance for any particular state visit
www.gutenberg.org/donate.

While we cannot and do not solicit contributions from states


where we have not met the solicitation requirements, we know
of no prohibition against accepting unsolicited donations from
donors in such states who approach us with offers to donate.

International donations are gratefully accepted, but we cannot


make any statements concerning tax treatment of donations
received from outside the United States. U.S. laws alone swamp
our small staff.

Please check the Project Gutenberg web pages for current


donation methods and addresses. Donations are accepted in a
number of other ways including checks, online payments and
credit card donations. To donate, please visit:
www.gutenberg.org/donate.

Section 5. General Information About Project


Gutenberg™ electronic works
Professor Michael S. Hart was the originator of the Project
Gutenberg™ concept of a library of electronic works that could
be freely shared with anyone. For forty years, he produced and
distributed Project Gutenberg™ eBooks with only a loose
network of volunteer support.

Project Gutenberg™ eBooks are often created from several


printed editions, all of which are confirmed as not protected by
copyright in the U.S. unless a copyright notice is included. Thus,
we do not necessarily keep eBooks in compliance with any
particular paper edition.

Most people start at our website which has the main PG search
facility: www.gutenberg.org.

This website includes information about Project Gutenberg™,


including how to make donations to the Project Gutenberg
Literary Archive Foundation, how to help produce our new
eBooks, and how to subscribe to our email newsletter to hear
about new eBooks.

You might also like