100% found this document useful (1 vote)
733 views

Practical Spring Cloud Function: Developing Cloud-Native Functions for Multi-Cloud and Hybrid-Cloud Environments 1st Edition Banu Parasuraman download

The document promotes the book 'Practical Spring Cloud Function' by Banu Parasuraman, which focuses on developing cloud-native functions for multi-cloud and hybrid-cloud environments. It covers practical examples, deployment strategies, and automation of CI/CD pipelines using Spring Cloud Function across various cloud platforms. The book also delves into real-world applications in sectors like IoT, AI/ML, and data pipelines, providing code examples available on GitHub.

Uploaded by

jedzkesley
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
733 views

Practical Spring Cloud Function: Developing Cloud-Native Functions for Multi-Cloud and Hybrid-Cloud Environments 1st Edition Banu Parasuraman download

The document promotes the book 'Practical Spring Cloud Function' by Banu Parasuraman, which focuses on developing cloud-native functions for multi-cloud and hybrid-cloud environments. It covers practical examples, deployment strategies, and automation of CI/CD pipelines using Spring Cloud Function across various cloud platforms. The book also delves into real-world applications in sectors like IoT, AI/ML, and data pipelines, providing code examples available on GitHub.

Uploaded by

jedzkesley
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 79

Download the full version and explore a variety of ebooks

or textbooks at https://ebookmass.com

Practical Spring Cloud Function: Developing Cloud-


Native Functions for Multi-Cloud and Hybrid-Cloud
Environments 1st Edition Banu Parasuraman

_____ Follow the link below to get your download now _____

https://ebookmass.com/product/practical-spring-cloud-
function-developing-cloud-native-functions-for-multi-cloud-
and-hybrid-cloud-environments-1st-edition-banu-
parasuraman-2/

Access ebookmass.com now to download high-quality


ebooks or textbooks
We have selected some products that you may be interested in
Click the link to download now or visit ebookmass.com
for more options!.

Practical Spring Cloud Function: Developing Cloud-Native


Functions for Multi-Cloud and Hybrid-Cloud Environments
1st Edition Banu Parasuraman
https://ebookmass.com/product/practical-spring-cloud-function-
developing-cloud-native-functions-for-multi-cloud-and-hybrid-cloud-
environments-1st-edition-banu-parasuraman/

Cloud-native Computing Pethuru Raj

https://ebookmass.com/product/cloud-native-computing-pethuru-raj/

CompTIA Cloud+ Guide to Cloud Computing West

https://ebookmass.com/product/comptia-cloud-guide-to-cloud-computing-
west/

Multi-Cloud Handbook for Developers Subash Natarajan |


Jeveen Jacob

https://ebookmass.com/product/multi-cloud-handbook-for-developers-
subash-natarajan-jeveen-jacob/
Practical Debugging at Scale: Cloud Native Debugging in
Kubernetes and Production 1st Edition Shai Almog

https://ebookmass.com/product/practical-debugging-at-scale-cloud-
native-debugging-in-kubernetes-and-production-1st-edition-shai-almog/

Hybrid Cloud Backup For Dummies®, Veeam Special Edition


Brett Mclaughlin

https://ebookmass.com/product/hybrid-cloud-backup-for-dummies-veeam-
special-edition-brett-mclaughlin/

Beginning Helidon: Building Cloud-Native Microservices and


Applications 1st Edition Dmitry Kornilov

https://ebookmass.com/product/beginning-helidon-building-cloud-native-
microservices-and-applications-1st-edition-dmitry-kornilov-2/

Beginning Helidon: Building Cloud-Native Microservices and


Applications 1st Edition Dmitry Kornilov

https://ebookmass.com/product/beginning-helidon-building-cloud-native-
microservices-and-applications-1st-edition-dmitry-kornilov/

Oracle Cloud Infrastructure: A Guide to Building Cloud


Native Applications Jeevan Gheevarghese Joseph & Adao
Oliveira Junior & Mickey Boxell
https://ebookmass.com/product/oracle-cloud-infrastructure-a-guide-to-
building-cloud-native-applications-jeevan-gheevarghese-joseph-adao-
oliveira-junior-mickey-boxell/
Banu Parasuraman

Practical Spring Cloud Function


Developing Cloud-Native Functions for Multi-Cloud
and Hybrid-Cloud Environments
Banu Parasuraman
Frisco, TX, USA

ISBN 978-1-4842-8912-9 e-ISBN 978-1-4842-8913-6


https://doi.org/10.1007/978-1-4842-8913-6

© Banu Parasuraman 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.
I would like to dedicate this book to my wife Vijaya and my wonderful
children Pooja and Deepika, who stuck with me through the trials and
tribulations during the writing of this book. I also dedicate this to my
mom, Kalpana Parasuraman.
Introduction
I entered the field of Information Technology (IT) 25 years ago, after
spending time in sales and marketing. I was an average programmer
and was never into hardcore programming. During my early life in IT, I
worked as part of a team that built a baseball simulator for the Detroit
Tigers. I helped build a video capture driver for that simulator using
C++. Even though this was a great project with a lot of visibility, it was
never my real passion to be a hard-core programmer.
I soon gravitated toward solution architecture. This seemed to
perfectly tie my marketing skills to my technology skills. I began
looking at solutions from a marketing lens. This approach formed the
basis for writing this book. Because, what good is a technology if we do
not know how to apply it in real life?
Functional programming was an emerging technology. Cloud
providers such as AWS, Google, and Azure created serverless
environments, with innovations such as Firecracker virtualization
techniques, that allowed infrastructure to scale down to zero. This
allowed customers to derive huge cost savings by not paying for
resources that were not in use and subscribing to a pay-per-use model.
Initially, development of these functions that run on serverless
environments were built on either NodeJS or Python. These functions
were also vendor-specific. Spring.io developed the Spring Cloud
Function framework, which allowed the functions to run in a cloud-
agnostic environment. The focus was on the “write once, deploy
anywhere” concept. This was a game changer in the cloud functions
world.
Prior to writing this book, I was a staunch evangelist of Pivotal
Cloud Foundry and Kubernetes. I promoted writing code that was
portable. When Knative came into being in 2018 as a joint effort
between IBM and Google, I was excited. Knative was designed as a
serverless infrastructure on top of Kubernetes and made the serverless
infrastructure portable. Combining the power and portability of Spring
Cloud Function and Knative, you have a true portable system with zero
scale-down capabilities.
This was something that I wanted to write and evangelize about.
But I felt that writing about the technology and how it worked would
not be that exciting. I wanted to write about how people could use this
technology in the real world.
In this book, you will see how to program and deploy real-life
examples using Spring Cloud Function. It starts with examples of
writing code and deploying to AWS Lambda, Google Cloud Function,
and Azure Function serverless environments. It then introduces you to
the Knative on Kubernetes environment. Writing code and deploying is
not enough. Automating the deployment is key in large-scale,
distributed environments. You also see how to automate the CI/CD
pipeline through examples.
This books also takes you into the world of data pipelines, AI/ML,
and IoT. This book finishes up with real-world examples in oil and gas
(IoT), manufacturing (IoT), and conversational AI (retail). This book
touches on AWS, the Google Cloud Platform (GCP), Azure, IBM Cloud,
and VMware Tanzu.
The code for these projects is provided on GitHub at https://​github.​
com/​banup-kubeforce. It is also available at
github.com/apress/practical-spring-cloud-function.
This allows you to get up to speed on the technologies. So, after
completing this book, you will have hands-on experience with AI/ML,
IoT, data pipelines, CI/CD, and of course Spring Cloud Function.
I hope you enjoy reading and coding this book.
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
It has been a great privilege to write this book and help you understand
real-world implementations of Spring Cloud Function. Thank you for
reading it.
After my presentation at SpringOne 2020, I received a message on
LinkedIn from Steve Anglin at Apress. Steve asked me if I would be
willing to write a book about Spring Cloud Function. I was a bit hesitant
at first, given that I was occupied with many client engagements, which
were taking up most of my work hours. I was worried that I would not
do the subject justice, due to my preoccupation with my clients. But
after a long contemplation and a heartfelt discussion with my family, I
decided to take it on.
I want to thank Steve Anglin, Associate Editorial Director, for
reaching out to me and providing me this opportunity to write a book
on Spring Cloud Function.
Mark Powers, the Editorial Operations Manager, was instrumental
in helping me bring this book to close. With his incessant prodding and
nudging, he helped me reached the finish line. Thanks, Mark.
Manuel Jordan, the technical reviewer, was immensely helpful. His
comments kept me honest and prevented me from cutting corners. He
helped improve the quality of the solutions that I present in this book.
Thanks, Manuel.
I also want to thank Nirmal Selvaraj and others at Apress, who
worked to bring this book to fruition.
This book would not be possible without the help of my wife Vijaya
and daughters Pooja and Deepika, who provided the much-needed
emotional support through this journey.
Table of Contents
Chapter 1:​Why Use Spring Cloud Function
1.​1.​Functions as a Service (FaaS)
1.​1.​1.​Implementation of an Enterprise Application
1.​1.​2.​Migration ROI for a Portfolio of Application
1.​1.​3.​The Serverless Functions Concept
1.​1.​4.​Applying the Serverless Functions Concept to an
Enterprise Application
1.​2.​Code Portability Issues
1.​2.​1.​Serverless Container Portability Issue
1.​3.​Spring Cloud Function:​Writing Once and Deploying to Any
Cloud
1.​4.​Project Knative and Portable Serverless Containers
1.​4.​1.​Containers, Serverless Platforms, and Knative
1.​4.​2.​What Is Knative?​
1.​5.​Sample Use Case:​Payroll Application
1.​6.​Spring Cloud Function Support
1.​6.​1.​Spring Cloud Function on AWS Lambda on AWS
1.​6.​2.​Spring Cloud Function on Knative and EKS on AWS
1.​6.​3.​Spring Cloud Function on Cloud Functions on GCP
1.​6.​4.​Spring Cloud Function on Knative and GKE on GCP
1.​6.​5.​Spring Cloud Function on Azure Functions on Azure
1.​6.​6.​Spring Cloud Function on Knative and AKS on Azure
1.​6.​7.​Spring Cloud Function on VMware Tanzu (TKG, PKS)
1.​6.​8.​Spring Cloud Function on Red Hat OpenShift (OCP)
1.​7.​Summary
Chapter 2:​Getting Started with Spring Cloud Function
2.​1.​Setting Up the Spring Boot and Spring Cloud Function
Locally
2.​1.​1.​Step 1:​Create the Spring Boot Scaffolding
2.​1.​2.​Step 2:​Create the Employee Model
2.​1.​3.​Step 3:​Write the Consumer
2.​1.​4.​Step 4:​Write the Supplier
2.​1.​5.​Step 5:​Write the Function
2.​1.​6.​Step 6:​Deploy and Run the Code Locally
2.​1.​7.​Step 7:​Test the Function
2.​2.​Setting Up Spring Cloud Function and AWS Lambda
2.​3.​Setting Up Spring Cloud Function and Google Cloud
Functions
2.​4.​Setting Up Spring Cloud Function Azure Functions
2.​5.​Setting Up Locally with Kubernetes and Knative and Spring
Cloud Function
2.​6.​Setting Up AWS with EKS and Knative with Spring Cloud
Function
2.​7.​Setting Up GCP with Cloud Run/​GKE and Knative with
Spring Cloud Function
2.​8.​Setting Up Azure with AKS and Knative with Spring Cloud
Function
2.​9.​Setting Up VMware Tanzu TKG and Knative
2.​10.​Summary
Chapter 3:​CI/​CD with Spring Cloud Function
3.​1.​GitHub Actions
3.​2.​ArgoCD
3.​3.​Building a Simple Example with Spring Cloud Function
3.​4.​Setting Up a CI/​CD Pipeline to Deploy to a Target Platform
3.​5.​Deploying to the Target Platform
3.​5.​1.​Deploying to AWS Lambda
3.​6.​Deploying to GCP Cloud Functions
3.​7.​Deploying to Azure Functions
3.​8.​Deploying to Knative on Kubernetes
3.​9.​Summary
Chapter 4:​Building Event-Driven Data Pipelines with Spring Cloud
Function
4.​1.​Data Event Pipelines
4.​1.​1.​Acquire Data
4.​1.​2.​Store/​Ingest Data
4.​1.​3.​Transform Data
4.​1.​4.​Load Data
4.​1.​5.​Analyze Data
4.​2.​Spring Cloud Function and Spring Cloud Data Flow and
Spring Cloud Streams
4.​2.​1.​Spring Cloud Function and SCDF
4.​3.​Spring Cloud Function and AWS Glue
4.​3.​1.​Step 1:​Set Up Kinesis
4.​3.​2.​Step 2:​Set Up AWS Glue
4.​3.​3.​Step 3:​Create a Function to Load Data into Kinesis
4.​4.​Spring Cloud Function and Google Cloud Dataflow
4.​5.​Summary
Chapter 5:​AI/​ML Trained Serverless Endpoints with Spring Cloud
Function
5.​1.​AI/​ML in a Nutshell
5.​1.​1.​Deciding Between Java and Python or Other
Languages for AI/​ML
5.​2.​Spring Framework and AI/​ML
5.​3.​Model Serving with Spring Cloud Function with DJL
5.​3.​1.​What Is DJL?​
5.​3.​2.​Spring Cloud Function with DJL
5.​4.​Model Serving with Spring Cloud Function with Google
Cloud Functions and TensorFlow
5.​4.​1.​TensorFlow
5.​4.​2.​Example Model Training and Serving
5.​5.​Model Serving with Spring Cloud Function with AWS
Lambda and TensorFlow
5.​6.​Spring Cloud Function with AWS SageMaker or AI/​ML
5.​7.​Summary
Chapter 6:​Spring Cloud Function and IoT
6.​1.​The State of IoT
6.​1.​1.​Example Spring Implementation
6.​1.​2.​An Argument for Serverless Functions On-Premises
6.​2.​Spring Cloud Function on the Cloud with AWS IoT
6.​3.​Spring Cloud Function on the Cloud with Azure IoT
6.​3.​1.​Azure IoT Edge Device
6.​3.​2.​Azure IoT Hub
6.​4.​Spring Cloud Function on Azure IoT Edge
6.​5.​Spring Cloud Function On-Premises with IoT Gateway on a
SaaS Provider (SmartSense)
6.​6.​Summary
Chapter 7:​Industry-Specific Examples with Spring Cloud Function
7.​1.​Oil/​Natural Gas Pipeline Tracking with Spring Cloud
Function and IOT
7.​1.​1.​Sensors
7.​1.​2.​IoT Gateway
7.​1.​3.​IBM Cloud Functions
7.​1.​4.​IBM Watson IoT Platform
7.​1.​5.​IBM Watson IoT Platform:​Message Gateway
7.​1.​6.​IBM Event Streams
7.​1.​7.​IBM Cloudant DB
7.​2.​Enabling Healthcare with Spring Cloud Function and Big
Data Pipelines
7.​3.​Conversational AI in Retail Using Spring Cloud Function
7.​3.​1.​Components of Conversational AI Solutions
7.​3.​2.​Watson Assistant Webhooks and Spring Cloud
Function
7.​3.​3.​Implementing the Watson Assistant with Spring Cloud
Function
7.​4.​Summary
Index
About the Author
Banu Parasuraman
is a cloud native technologist and a
Customer Success Manager (CSM) at
IBM, with over 30 years of experience in
the IT industry. He provides expert
advice to clients who are looking to move
to the cloud or implement cloud-native
platforms such as Kubernetes, Cloud
Foundry, and the like. He has engaged
over 25 select companies spread across
different sectors (including retail,
healthcare, logistics, banking,
manufacturing, automotive, oil and gas,
pharmaceuticals, and media and
entertainment) in the United States, Europe, and Asia. He is
experienced in most of the popular cloud platforms, including VMware
VCF, Pivotal PCF, IBM OCP, Google GCP, Amazon AWS, and Microsoft
Azure. Banu has taken part in external speaking engagements targeted
at CXOs and engineers, including at VMworld, SpringOne, Spring Days,
and Spring Developer Forum Meetups. His internal speaking
engagements include developer workshops on cloud-native
architecture and development, customer workshops on Pivotal Cloud
Foundry, and enabling cloud-native sales plays and strategies for sales
and teams. Lastly, Banu has numerous blogs on platforms such as
Medium and LinkedIn, where he promotes the adoption of cloud-native
architecture.
About the Technical Reviewer
Manuel Jordan Elera
is an autodidactic developer and
researcher who enjoys learning new
technologies for his own experiments
and creating new integrations. Manuel
won the Springy Award 2013
Community Champion and Spring
Champion. In his little free time, he reads
the Bible and composes music on his
guitar. Manuel is known as
dr_pompeii. He has tech-reviewed
numerous books, including Pro Spring
MVC with Webflux (Apress, 2020), Pro
Spring Boot 2 (Apress, 2019), Rapid Java
Persistence and Microservices (Apress,
2019), Java Language Features (Apress,
2018), Spring Boot 2 Recipes (Apress, 2018), and Java APIs, Extensions,
and Libraries (Apress, 2018). You can read his detailed tutorials on
Spring technologies and contact him through his blog at www.​
manueljordaneler​a.​blogspot.​com. You can follow Manuel on his Twitter
account, @dr_pompeii.
© Banu Parasuraman 2023
B. Parasuraman, Practical Spring Cloud Function
https://doi.org/10.1007/978-1-4842-8913-6_1

1. Why Use Spring Cloud Function


Banu Parasuraman1

(1) Frisco, TX, USA

This chapter explores Spring Cloud Function using a sample use case—
an HRM (Human Resources Management) system. The focus is on
systems that reside in an enterprise. The chapter touches on the FaaS
(Functions as a Service) concept and explains how it is gaining
momentum in the enterprise. The chapter also digs deeper into its
implementations in the cloud. You will learn about some of the
portability issues present at the code and container level and read
about concepts such as Knative on Kubernetes, which includes
container portability. You will also learn about some high-level
implementations of Spring Cloud Function on AWS, GCP, Azure, VMware
Tanzu, and Red Hat OpenShift.

1.1 Functions as a Service (FaaS)


FaaS is a revolutionary technology. It is a great boon for developers and
businesses. FaaS allows businesses to adapt to rapidly changing
business needs by enabling their development teams to develop
products and features at a “high” velocity, thereby improving their
Mean Time To Market (MTTM). Developers can develop functions
without worrying about setting up, configuring, or maintaining the
underlying infrastructure. FaaS models are also designed to use just the
right quantity of infrastructure and compute time. They also can be
scaled to fit exact demand, by focusing on billing for the number of
invocations as compared to billing for uptime. FaaS has two parts, as
shown in Figure 1-1.
The function code encapsulates the business logic in any language,
such as Java, C#, Python, Node, and so on.
The underlying container hosts an application server and an
operating system.

Figure 1-1 FaaS component architecture

1.1.1 Implementation of an Enterprise Application


Imagine all the infrastructure needed to run a single payroll application
on the cloud. This application may consume only 16GB of RAM and
eight vCPUs, but you are charged continuously for the entire duration
that the application is active. Using a simple AWS pricing formula, this
works out to around $1,000 per year. This cost is for the whole time the
application is hosted and active, regardless of use. Of course, you can
cost-justify it through a TCO (Total Cost of Ownership) calculation,
which helps you determine how your application can bring in revenue
or value that compensates for the expense. This revenue-generation
model is more suitable to applications that generate revenue for the
company, such as an ecommerce site. It is more difficult to prove the
value that a supporting application, running in the backend of an
enterprise, brings to a company.

1.1.2 Migration ROI for a Portfolio of Application


The value equation gets more complex if you plan to migrate an
extensive portfolio of apps in your enterprise.
Let’s for a moment assume, as a CTO or CIO of a company, you have
a portfolio of about one thousand applications that you plan on
migrating to the cloud. The key factors to consider, among the many,
include:
What is the current infrastructure supporting the apps?
What is the utilization of these apps?
The utilization of apps is an essential factor in determining the
value of the application. Consider this—after analyzing the utilization
of apps, you find that this portfolio includes the following distribution:
10% with 80% utilization
40% with 50% utilization
50% with 20% utilization
If you calculate the billing cost using an AWS cost calculator, you see
that you will spend $1 million per year. This spend is for applications
that are critical and highly utilized, as well as for applications that are
minimally utilized. This cost is due to the fact that the cloud providers
charge for the entire duration the application is active and consuming
the infrastructure. The key here is that the infrastructure is fully
allocated for the application’s life. Imagine how much you could save if
the infrastructure was allocated only for the duration that the
application was active and serving. This would be a great cost and
resource saving approach. Cloud providers have thought through this
because they also faced the pressure of finite infrastructure and
considered the time needed to provision additional infrastructure.

1.1.3 The Serverless Functions Concept


To work around the problem of finite infrastructure utilization, AWS
created Lambda serverless functions. This was a genius invention.
Subscribers to this service pay only for the time the application is
invoked. The infrastructure is unallocated when it is not invoked. This
way, AWS can save on infrastructure by repurposing the infrastructure
for other needy applications while transferring the cost savings to the
customer. This is a win-win. It’s worth considering whether you can
apply this same approach to all the enterprise applications in your
company today. You would be able to save a lot of money. Also, if you
were to bring this technology to the datacenter, you would be able to
reap the benefits that AWS realized. Isn’t this wonderful?

1.1.4 Applying the Serverless Functions Concept to


an Enterprise Application
Let’s dig deeper into the concept of functions and how AWS realizes the
magic of infrastructure savings. Functions are tiny code pieces with a
single input and a single output, and a processing layer (a predicate)
acting as the glue. Compare this to enterprise apps, which are designed
to do many things. Take a simple payroll system, for example. A payroll
system has multiple input interfaces and multiple output interfaces.
Here are some of those interfaces:
Timecard system to get the hours employees worked in a month
Performance evaluation system
Peer feedback system
Inflation adjustment calculator system
The outgoing interface to the IRS
The outgoing interface to the medical insurance provider
An outgoing interface to the internal web portal where employees
can download their paystubs
Running this payroll application is not trivial. I have seen such a
payroll system use the following:
Fourteen dedicated middleware application servers
Two RDBMS database stores
Two integration tools such as message queues and FTP
Four dedicated bare-metal servers, with each server configured with
128GB RAM, 32 CPUs, 4TB of HDD, 10TB of vSAN, and the like
The key factor in determining whether this application can be
hosted on a serverless functions infrastructure like Lambda is the time
it takes for the application to boot up (the startup time or cold start)
and the time it takes for the application to shut down (the shutdown
time). The faster the startup and shutdown times, the larger the cost
savings.
It is also important that these times be quick so that they don’t
cause disruptions. If you were to research the startup times for large
enterprise applications like the payroll application, you would find that
it is not pretty. An average startup time is around 15 minutes for all
components to come up and another 15 minutes for the application to
come down. This would not fly. Imagine if you deployed this application
to an AWS Lambda serverless function. Thirty minutes of downtime for
each invocation? This will not work. Your users would abandon the
application entirely. As you can see, large applications cannot benefit
from resource release and resource reassignment because they take a
long time to start up and shut down, which would impact the general
operation of the application.
Can you make this large payroll application behave in an expected
way for serverless functions? The answer is yes. A lot of refactoring is
required, but it can be done.

Serverless Function in the Cloud


All cloud providers have now incorporated the serverless functions into
their infrastructure offerings. AWS has Lambda Functions, Google has
Cloud Functions, and Azure has Azure Functions. These providers, in
the quest for making their customers captive, made sure to introduce
proprietary elements into their environments. The two components
that are essential to run the functions are:
Serverless function code that serves the functions
Serverless infrastructure (containers) that supports the code

Why Is It Important for Serverless Functions to be


Non-Proprietary?
Enterprises are gravitating toward a multi-cloud, hybrid-cloud
approach to their cloud strategy. As you can see in Figure 1-2, the
survey of 3,000 global respondents indicated that 76 percent already
work in a multi-cloud environment. This means they are not bound to
one single cloud provider. The adoption of a multi-cloud strategy
alleviates the risk of vendor lock-in.

Figure 1-2 Multi-cloud adoption report Source:


https://info.flexera.com/CM-REPORT-State-of-the-Cloud?
lead_source=Website%20Visitor&id=Blog
In a multi-cloud world, it is essential that enterprises subscribe to
services that can be easily ported between clouds. This is especially
important for commodity services.
FaaS, or serverless functions, have of late become a commodity with
all the providers having some services around FaaS. It is therefore
imperative that FaaS containers not have proprietary code.
Serverless functions become portable when they do not use
proprietary code. Portable serverless functions allow for workload
mobility across clouds. If, for instance, AWS Lambda functions are
costly and Azure Functions are cheap, enterprises can avail the cost
savings and move that Lambda workload to Azure Functions with very
little effort.
The subsequent sections discuss in detail these portability issues
and explain how you can solve them.
1.2 Code Portability Issues
Listing 1-1 shows the sample AWS Lambda code written in Java. This
code was generated using the AWS SAM (Serverless Application Model)
template. When observing the code, you can see that the AWS-specific
library references and method calls bind the code to AWS. It is not
much, but it is potent. In an enterprise, you typically have hundreds if
not thousands of pieces of code that you must refactor if you want to
move this type of code to another cloud provider. This is a costly affair.
Listing 1-1.Sample Code Using the AWS SAM Framework
The following section explores the portability of the underlying
serverless container, which impacts how multi-cloud migrations are
conducted.

1.2.1 Serverless Container Portability Issue


What about Lambda’s underlying serverless framework? Is it portable?
If you deep dive into AWS Lambda, the virtualization technology
used is Firecracker. Firecracker uses KVM (a kernel-based virtual
machine) to create and manage microVMs. You can find more
information on Firecracker at https://​aws.​amazon.​com/​blogs/​aws/​
firecracker-lightweight-virtualization-for-serverless-computing/​.
The minimalist design principle that Firecracker is built on allows
for fast startup and shutdown times. Google Cloud Functions, on the
other hand, use gVisor and are not compatible with Firecracker. gVisor
is an application kernel for containers. More information can be found
at https://​github.​com/​google/​gvisor.
Azure Functions take a totally different approach of using the PaaS
offering app service as their base. So, you can see that the major cloud
providers use their own frameworks for the managing functions’
containers. This makes it difficult for functions to move between clouds
in a multi-cloud environment. This portability issue becomes more
pronounced due to the lack of portability at the container level.

Figure 1-3 Serverless architecture comparison

You can see that the code and containers both differ from the provider
and are not easily portable.
In the discussions so far, you have seen the following issues related
to FaaS:
Portability of code
Portability of the serverless container
Cold start of the serverless environment
How do you solve these issues?
Enter Spring Cloud Function and Knative. Spring Cloud Function
addresses function code portability, and Knative addresses container
portability.
Information on Spring Cloud Function is available at https://​spring.​
io/​projects/​spring-cloud-function, and information about Knative is
available at https://​knative.​dev/​docs/​.
The following sections deep dive into each of these topics.

1.3 Spring Cloud Function: Writing Once and


Deploying to Any Cloud
As you learned from the earlier discussion, writing functions for AWS
Lambda, Google Cloud Functions, or Azure Functions is a proprietary
activity. You have to write code specific to a hyperscaler. Hyperscalers
refer to large-scale cloud providers like AWS, Google, or Azure, who
have a complete mix of hardware and facilities that can scale to 1000s
of servers. This is not bad if your strategy is to have a strong single
hyperscaler relationship, but over time, when your strategy changes to
a hybrid cloud or multi-cloud, you may have to rethink your approach.

A hybrid cloud comprises a private cloud and a public cloud and is


managed as one entity. Multi-cloud includes more than one public
cloud and does not have a private cloud component.

This is where the Spring Cloud Function comes in. The Spring.io
team started the Spring Cloud Function project with the following
goals:
Promote the implementation of business logic via functions.
Decouple the development lifecycle of business logic from any
specific runtime target so that the same code can run as a web
endpoint, a stream processor, or a task.
Support a uniform programming model across serverless providers,
as well as the ability to run standalone (locally or in a PaaS).
Enable Spring Boot features (auto-configuration, dependency
injection, metrics) on serverless providers.
Source: https://​spring.​io/​projects/​spring-cloud-function
The key goals are decoupling from a specific runtime and
supporting a uniform programming model across serverless providers.
Here’s how these goals are achieved:
Using Spring Boot
Wrapper beans for Function<T, R> (Predicate), Consumer<T>, and
Supplier<T>
Packaging functions for deployments to target platforms such as AWS
Lambda, Azure Functions, Google Cloud Functions, and Knative using
adapters
Another exciting aspect of Spring Cloud Function is that it enables
functions to be executed locally. This allows developers to unit test
without deploying to the cloud
Figures 1-4 and 1-5 show how you can deploy Spring Cloud
Function. When Spring Cloud Function is bundled with specific
libraries, it can be deployed to AWS Lambda, Google Cloud Functions, or
Azure Functions.

Figure 1-4 Deploying Spring Cloud Function directly to FaaS environments


provided by the cloud providers

Figure 1-5 Deploying Spring Cloud Function on Knative serverless configured on


Kubernetes environments provided by the cloud providers
When Spring Cloud Function is containerized on Knative, it can be
deployed to any Kubernetes offering, whether on the cloud or on-
premises. This is the preferred way to deploy it on hybrid and multi-
cloud environments.

1.4 Project Knative and Portable Serverless


Containers
Having a portable serverless container is also important. This
minimizes the complexity and time required to move between cloud
providers. Moving between cloud providers to take advantage of
discounted pricing goes a long way toward saving costs. One
methodology used is called cloud bursting (Figure 1-6). Cloud bursting
compensates for the lack of infrastructure on-premises by adding
resources to the cloud. This is usually a feature of a hybrid cloud.

Figure 1-6 Cloud bursting

Figure 1-6 shows that, to compensate for the lack of resources in a


private cloud during a traffic spike, resources are allocated to the public
cloud where the traffic is routed. When the traffic spike goes down, the
public cloud resources are removed. This allows for targeted use of
costs and resources—that is, it uses additional resources only during
the traffic spike period. The burst of activity during an eCommerce
event like Cyber Monday is a great example of a traffic spike.
This cannot be easily achieved with just a portable code. You need
containers that are also portable. This way, containers can be moved
across cloud boundaries to accommodate traffic spikes. In Figure 1-6,
you can see that VMs from VMware are used as containers. Since the
VMs hosted in the datacenter and hosted in the cloud are similar in
construct, cloud bursting is possible.
Applying this to Functions as a Service, you need a new way to make
the underlying serverless containers portable.
One such revolutionary approach in the cloud function world is
Knative. The next section dives deep into Knative.

1.4.1 Containers, Serverless Platforms, and


Knative
What was the need for containers /serverless platforms?
Over the course of the evolution of IT, there has been a need for
secure isolation of running processes. In the early 90’s, chroot jail-
based isolation allowed developers to create and host a virtualized
copy of the software system. In 2008 Linux Containers (LXC) was
introduced which gave the developers a virtualized environment. In
2011 Cloud Foundry introduced the concept of a container, and with
Warden in 2019 container orchestration became a reality. Docker,
introduced in 2013, provided containers that can host any operating
system. Kubernetes, introduced in 2014, provided the capability to
orchestrate containers based on Docker. Finally, Knative, introduced in
2018, extended Kubernetes to enable serverless workloads to run on
Kubernetes clusters.
Serverless workloads (Knative) grew out of the need to help
developers rapidly create and deploy applications without worrying
about the underlying infrastructure. The serverless computing model
takes care of provisioning, management, scheduling, and patching and
allows cloud providers to develop the “pay only for resources used”
model.
With Knative, you can create portable serverless containers that run
on any Kubernetes environment. This allows for FaaS to be portable in
a multi-cloud or hybrid-cloud environment.
Besides making developers more productive, the serverless
environment offers faster deploys (see Figure 1-7). Developers can use
the “fail fast and fail often” model and spin up or spin down code and
infrastructure faster, which helps drive rapid innovation.

Figure 1-7 Serverless deploys the quickest

1.4.2 What Is Knative?


Knative is an extension of Kubernetes that enables serverless
workloads to run on Kubernetes clusters. Working with Kubernetes is a
pain. The amount of tooling that is required to help developers move
their code from the IDE to Kubernetes defeats the purpose of the agility
that Kubernetes professes to bring to the environment. Knative
automates the process of build packages and deploying to Kubernetes
by provider operators that are native to Kubernetes. Hence, the names
“K” and “Native”.
Knative has two main components:
Serving: Provides components that enable rapid deployment of
serverless containers, autoscaling, and point-in-time snapshots
Eventing: Helps developers use event-driven architecture by
providing tools to route events from producers to subscribers/sinks
You can read more about Knative at https://​Knative.​dev/​docs.
1.5 Sample Use Case: Payroll Application
Let’s look at how you can apply serverless functions to a real-life
example.
We introduced the payroll application in the beginning of the
chapter, we’ll now build on it. Consider a payroll application with the
configuration shown in Figure 1-8.

Figure 1-8 Payroll application components

Figure 1-9 shows the configuration.


Figure 1-9 Payroll application flow
Translating this flow diagram into an actual implementation that
can be deployed in a corporate datacenter results in Figure 1-10. You
see that the functions are developed as REST APIs that are executed in
batch mode. The REST APIs expose SAP ECC payroll modules. These
REST APIs are run as batch jobs every 15 days. The databases are
hosted on Oracle, and integrations are exposed using IBM API Connect
(APIC). Note that this is not an on-demand process and can consume a
lot of resources when idle. These REST APIs cannot be easily shut down
and started up because a typical time for booting up a SAP NetWeaver
component can be anywhere from 2 to 15 minutes, depending on the
JVM configuration. These application components must be running
constantly to keep the payroll application from breaking down.

Figure 1-10 Current payroll architecture

Using this use case, the following sections explore how you can
leverage Spring Cloud Function to modernize and transform this
application into a highly efficient, scalable, and portable system.

1.6 Spring Cloud Function Support


The Spring Cloud Function is supported in almost all cloud offerings, as
shown in Table 1-1.

Table 1-1 Spring Cloud Function Support Among Cloud Providers

AWS Azure Google IBM Cloud On-Premises


Azure Cloud
Lambda IBM Functions Tanzu with Knative
Functions Functions
EKS with AKS with GKE with Tanzu with OpenShift with
Knative Knative Knative Knative Knative
Fargate Any Kubernetes
ARO with OpenShift OpenShift with
with offering with
Knative with Knative Knative
Knative Knative
ROSA with Tanzu with Tanzu with IBM Kubernetes
Knative Knative Knative with Knative
Tanzu with
Knative

Abbreviations: ROSA: Red Hat OpenShift on AWS; ARO: Azure Red Hat
OpenShift; EKS: Elastic Kubernetes Services; AKS: Azure Kubernetes
Services; GKE: Google Kubernetes Engine

1.6.1 Spring Cloud Function on AWS Lambda on


AWS
Transforming an application deployed on-premises to leverage an AWS
Lambda environment and be portable requires function code that
abstracts away the hard dependencies of AWS Lambda from the
implementation and the serverless container. This example uses Spring
Cloud Function for the function code framework and Lambda for the
container. By writing once using Spring Cloud Function, you can use the
DevOps pipeline, discussed in subsequent chapters, to deploy to other
serverless environments. Figure 1-11 shows how AWS and its
components help realize the payroll application in the cloud.

Figure 1-11 Spring Cloud Function on AWS


Now you need to deploy the payroll system on AWS Lambda. The
deployment sequence is important, as you need to deploy SAP ECC and
Oracle before integrating and then configure API and messaging for the
Spring Cloud Function to integrate with SAP. Spring Cloud Function can
be created and tested with dummy information, but it needs to be
deployed after integration testing with SAP ECC:
1. Deploy SAP ECC on the AWS EC2 instances.

2. Deploy Oracle DB as an RDS instance.

3. Configure the SAP to Oracle integration.

4. Deploy Spring Cloud Function to AWS.

5. Set up the Amazon API Gateway.

6. Set up Amazon SQS for messaging.


1.6.2 Spring Cloud Function on Knative and EKS on
AWS
If you want to implement a truly portable environment in AWS, you can
leverage the AWS EKS, which is a Kubernetes platform that AWS offers.
You can install Knative in EKS and this will give you a truly portable,
serverless container that allows for faster deployment and improved
cold starts. It uses appropriate technologies, such as Spring Cloud
Function on GraalVMs. GraalVMs uses the AOT (Ahead of Time)
compilation technique, which significantly improves execution times.
Subsequent sections address GraalVMs and Spring Cloud Function. See
Figure 1-12.

Figure 1-12 Spring Cloud Function on Knative on AWS

Follow this process to deploy the payroll system on Knative hosted


on an Azure AKS and ensure that the SAP ECC and Oracle DB are up and
integrated. You do this before developing and deploying Spring Cloud
Function on Knative:
1. Deploy SAP ECC on AWS EC2 instances.
2. Deploy Oracle DB as an RDS instance.

3. Configure the SAP to Oracle integration.

4. Set up Knative on an AWS EKS cluster.

5. Deploy Spring Cloud Function on Knative.

6. Set up the Amazon API Gateway.

7. Set up Amazon SQS for messaging.

1.6.3 Spring Cloud Function on Cloud Functions on


GCP
GCP Cloud Functions provide a cloud alternative to AWS Lambda
Functions. The GCP offering is newer than Lambda, but with the Anthos
strategy, it is gaining a good amount of the function space. Spring.io
works closely with Google to make the Spring.io components work
seamlessly with the GCP components.
To deploy the payroll system on Cloud Functions on GCP, follow the
process outlined here (see Figure 1-13). Ensure that the SAP ECC and
Oracle DB are up and integrated before developing and deploying
Spring Cloud Function on Cloud Functions:
1. Deploy SAP ECC onto GCE.

2. Deploy Oracle DB on GCE VMs, as there is no AWS RDS-like service


on GCP.

3. Configure the SAP to Oracle integration.

4. Set up a GCP Cloud Function project.

5. Deploy Spring Cloud Function onto GCP Cloud Functions.


6. Deploy Apigee on GCP to host function APIs.

7. Set up the Google Cloud pub/sub messaging platform.

Figure 1-13 Spring Cloud Function on GCP

1.6.4 Spring Cloud Function on Knative and GKE on


GCP
Knative, as discussed, is a way to make the functions portable. Knative,
incidentally, was created by Google. With GCP, you can set up Knative on
GKE, which is the Kubernetes engine provided by Google.
To deploy the payroll system on Knative hosted on a GCP GKE,
follow the process outlined here (Figure 1-14). Ensure that the SAP ECC
and Oracle DB are up and integrated before developing and deploying
Spring Cloud Function on Knative:
1. Deploy SAP ECC as a Docker image onto the GKE cluster.

2. Deploy Oracle DB as a Docker image onto the GKE cluster.


3. Configure the SAP to Oracle integration.

4. Configure a GKE cluster with Knative.

5. Deploy Spring Cloud Function onto Knative.

6. Set up the Apigee API Gateway.

7. Set up RabbitMQ on GKE for messaging.

8. Set up Google cloud pub/sub.

Figure 1-14 Spring Cloud Function on Knative on GCP

1.6.5 Spring Cloud Function on Azure Functions on


Azure
Spring Cloud Function deployed on Azure Functions is not portable due
to the explicit use of an Azure Function Invoker class. While Lambda
and Google Cloud Functions require a change to Pom.xml (if you are
using Maven), Azure needs an additional class. This makes it less
portable. If you have a portfolio of one thousand Spring Cloud
Functions in AWS that you need to move to Azure, you have to do a lot
of development activity. This is disruptive.
To deploy the payroll system on Azure Functions, follow the process
outlined here (see Figure 1-15). Ensure that the SAP ECC and Oracle DB
are up and integrated before developing and deploying Spring Cloud
Function on Azure Functions:
1. Deploy SAP ECC on Azure VMs.

2. Deploy Oracle DB on Azure VMs.

3. Configure the SAP to Oracle integration.

4. Configure Azure Functions.

5. Deploy Spring Cloud Function on Azure Functions.

6. Set up the Azure API Gateway on Azure.

7. Set up Azure Queue storage on Azure for messaging.


Figure 1-15 Spring Cloud Function on Azure

1.6.6 Spring Cloud Function on Knative and AKS on


Azure
Knative on Azure AKS is the only option for deploying Spring Cloud
Function on Azure that makes it portable. As in any Kubernetes
implementation, it requires an implementation of Knative to run the
functions. Transforming the payroll application to AKS requires an AKS
cluster.
To deploy the payroll system on Knative hosted on an Azure AKS
environment, follow the process outlined here (Figure 1-16). Ensure
that the SAP ECC and Oracle DB are up and integrated before
developing and deploying Spring Cloud Function on Knative:
1. Deploy SAP ECC on Azure VMs.

2. Deploy Oracle DB on Azure VMs.

3. Configure the SAP to Oracle integration.

4. Configure an AKS cluster with Knative.

5. Deploy Spring Cloud Function onto Knative.

6. Set up an Azure API Gateway on AKS.

7. Set up Azure Queue on Azure for messaging.


Figure 1-16 Spring Cloud Function on Knative on Azure

1.6.7 Spring Cloud Function on VMware Tanzu


(TKG, PKS)
VMware Tanzu is an evolution of Pivotal Cloud Foundry (PCF). Those
who are familiar with PCF should be aware of the “cf push” experience.
It was a one-click provisioning approach and was very popular in the
developer community. This is the same experience that Knative
provides through its Knative build feature. To transform the payroll
application to run on VMware Tanzu, you need the Tanzu Kubernetes
grid, also known as TKG. TKG is built using the main branch of
Kubernetes code. This can be deployed on-premises and in the cloud
and can facilitate a multi-cloud or hybrid-cloud strategy. You can start
up an instance of TKG on AWS, Azure, or Google by subscribing to the
service in the provider’s marketplace.
In a datacenter, you need a collection of servers or a hyper-
converged infrastructure like VxRail with PRA (Pivotal Ready
Architecture). You also need to upgrade your vSphere to Version 7.
Going back to the payroll application, you need to follow the process
outlined here (Figure 1-17). Ensure that the SAP ECC and Oracle DB
have been up and integrated before developing and deploying Spring
Cloud Function on Knative:
1. Deploy SAP ECC as a Docker image onto TKG.

2. Deploy Oracle DB as a Docker image onto TKG.

3. Configure the SAP to Oracle integration.

4. Configure a TKG cluster with Knative.

5. Deploy Spring Cloud Function onto Knative.

6. Set up a Spring Cloud Gateway on TKG as an API Gateway.

7. Set up RabbitMQ on TKG for messaging.

Figure 1-17 Spring Cloud Function on TKG


Figure 1-18 Four-node VxRail P570F cluster for vSphere with Tanzu and HAProxy

1.6.8 Spring Cloud Function on Red Hat OpenShift


(OCP)
Red Hat OpenShift can be an on-premises option for deploying Spring
Cloud Function. As in any Kubernetes implementation, it requires an
implementation of Knative to run the functions. OpenShift has its own
serverless implementation, called OpenShift serverless. Transforming
the payroll application to OpenShift requires an OpenShift cluster.
To deploy the payroll system to OpenShift hosted on a VMware
vSphere environment, follow the outlined process. First ensure that the
SAP ECC and Oracle DB are up and integrated before developing and
deploying Spring Cloud Function on Knative:
1. Deploy SAP ECC as a Docker image onto OpenShift cluster.

2. Deploy an Oracle DB as a Docker image onto the OpenShift cluster.

3. Configure the SAP to Oracle integration.


4. Configure an OpenShift cluster with Knative.

5. Deploy Spring Cloud Function onto Knative.

6. Set up a Red Hat 3scale API Gateway on OpenShift.

7. Set up RabbitMQ on TKG for messaging.

Figure 1-19 Spring Cloud Function on Red Hat OpenShift

1.7 Summary
This chapter discussed FaaS environments, Spring Cloud Function, and
Knative. You saw that FaaS containers/environments provided by AWS,
Google, or Microsoft Azure are not portable, as the underlying
components that host the FaaS environment do not have the same
architecture, which makes it difficult to move or migrate FaaS
containers between cloud providers. You also saw that Spring Cloud
Function can abstract the dependent AWS and Google libraries and
provide a portable alternative. Spring Cloud Function on Knative can
improve developer productivity by “writing once and deploying
anywhere.” You saw how to apply Spring Cloud Function and Knative to
an enterprise payroll application and learned about the various
implementation approaches. The next chapter walks through the
deployments step-by-step. You will also see how to develop and deploy
code to various targets, such as AWS, GCP, Azure, OpenShift, and
VMware Tanzu. This will help you understand the power of Spring
Cloud Function.
Other documents randomly have
different content
HILJAISTA MIEHUULLISUUTTA.

"Miten ne laulavat, kuulkaahan!" — Nuori hoitajatar kumartuu


innoissaan ulos ikkunasta. Kadulta kantautuu hiljaiseen
sairashuoneeseen reipas laulu tahdikkaan astunnan säestämänä.
Komppania marssii asemalle täysissä varustuksissa.

"Miten ne laulavat", sanoo hän uudelleen. — "Että ne saattavatkin


noin —." Hän ei päätä lausettaan, nojaa vain ikkunanpieleen ja
henkäisee äkisti syvään: hän ajattelee kaikkia niitä, jotka tulevat
menettämään henkensä — tai ehkä liikuntakykynsä, niinkuin hän
tuolla vuoteessa, nuori poika, joka yhä häilyy elämän ja kuoleman
välillä.

"Minkälainen oli muuten yö?" — Lääkäri nyökkää vuoteeseen päin.

"Entisellään. Hän hourailee lakkaamatta, kuinka muka ketju


murtui, kun hän ei kestänyt paikallaan vartiossa ja siihen tapaan.
Alituiseen, niin että oikein pahaa tekee kuunnella. — Poloinen,
niinkuin ei se hänen osaltaan riittäisi. Tokko saanee edes pitää
jalkansa."

"Vaikea sanoa. Parhaassa tapauksessa jää se kuitenkin aivan


jäykäksi.
Kun nyt edes yleisvointi korjautuisi."

Laulu ja askelten kaiku on edennyt kuulumattomiin. Hoitajatar


sulkee ikkunan. He lähtevät työhönsä. Niihin aikoihin ei siinä talossa
ollut yötä eikä päivää. Oli vain loppumatonta kuumeista askarrusta.
Ja yhä tuli lisää joka junan mukana haavottuneita — Raudun verisen
voiton lunnaita.

— — — Mutta eräänä päivänä herää Arvo Partio siitä pitkällisestä


yöpimeästä, johon kuume on hänet kahlehtinut. Hän katselee
ympärilleen kirkkain silmin hiljaisessa valkeassa huoneessa, johon
päivänpaiste valuu uudinten lomasta leveinä kultajuovina. Kukat
tuoksuvat yöpöydällä. Hän näkee ne ensi kertaa, jaksaa jo iloita
niistä. Hän tuntee palautuneensa tajunnan selkeyteen ja elämään —
vieläkin kerran.

"Arvatkaapas, arvatkaapas, mitä hyvää minä täältä tuon!" —


Hoitajatar pilkistää ovesta säteilevän iloisena. Valkea myssy on
istahtanut vinoon toiselle korvalliselle pelkästä hyvästä mielestä. Hän
katoaa ja sijalle ilmestyy —

"Ei mutta — ei mutta, Poke."

"Sama mies. Ukkoseni, veli rukka. Aune minulle kirjotti. En


tahtonut jaksaa aluksi niellä enkä sulattaa. — Sitä se sota tekee." —
Hän ravistelee toista karhun hellyydellä laihtuneista hartioista,
läimäyttelee ja ravistelee. Mutta hehän ovat niin sanomattoman
iloisia.

"Että sinä tosiaan. Miten selvisitkin?"


"Enpä ihmeemmin. Katsos, kaikenhan voi järjestää.
Komennuksella, komennuksella tietenkin ollaan. Haavottuneita
tuomassa. Tiedätkös, ei se komppania niin vain poikiaan unohda" —
hän läimäyttää tällä kertaa Arvon päänalaiseen, niin että vieteripatja
keinahtelee —. "Sitä sanoivat kaikki, että jopa oli sekapäinen se
luoti, joka sinut kempsautti jaloiltasi. No, minä viivana päällikön
puheille ja lomalippu lähti kuin itsestään."

Hän on niin kaltaisensa. Tekee hyvää kuunnella ja katsella häntä.


Päivettyneet kasvot hohtavat raikkauttaan, silmissä kipinöi ja vilkehtii
kuin majakkalyhty. On kuin kukkisi nuoruus ja voima hänen
veressään. Mutta hänpä onkin niitä, jotka ainaisesti purjehtivat
piristävässä aamutuulessa ja tuovat elämää ja vauhtia muassaan.

Arvo tuntee se selvemmin kuin konsaan ennen. Toisen käsistä


valuu sähkövirtana sykähyttelevä elämänhalu hänen kalpeisiin käsi
raukkoihinsa.

"Ukko rukkaseni, miten oletkin huvennut. Eihän sinusta ole jälellä


kuin hiukan silkkaa keskikohtaa. Vain yksi ulottuvaisuus kuin viivalla
Bonsdorfin 'kurnetriassa.' — Eläs, että todellakin oli vielä sen verran
sivistyksen rippeitä jälellä. Sen kun moititaan kenttäelämän niin
huikeasti muka metsistyttävän." — Hän nauraa tartuttavan iloisesti,
niin että hohtaa valkea tasainen hammasrivi. Vaikka oikeastaan
sydänalaa niin oudosti kouristaa katsellessa tuttuja rakkaita kasvoja
pieluksella. Ne ovat niin kapeat ja läpikuultavan kalpeat. Mutta Poke
ei ole niinä miehinäänkään, kulettaa valtioviisaasti keskustelunkin
ihan toisille urille.

Ja he antavat jutun luistaa kuin ennen.


"Toiset pojatko? Hohoi — ne ukkelit jaksavat pulskasti. Ja
paikkansa ne pitävät aina ja joka tempussa. Sen sanoo vaikka kuka,
päällikötkin. Iso-Jukka on ihan jyry miehekseen, koko komppanian
kaunistus. Ei hätäile eikä siekaile hikisimmissäkään paikoin.

"Muuten olemme viime viikkoina olleet hieman erillämme. Näes,


minua tuppasi kyllästyttämään se ainainen ketjussa loikominen. Pyrin
sitten tykistötiedustelijoihin. Se on ikäänkuin liikkuvampaa ja
reilumpaa ja pitää niin voiteessa miehen. Koikkalainen tietysti
piipertää kintereilläni kuin ennenkin.

"— Muuten muista minun sanoneeni. Se poika se vielä näkyy


Suomen armeijan riveissä — jos nyt yleensä elävänä selviämme
itsekukin. — Mutta väsyttääkö tämä sinua?"

Arvo on sulkenut silmänsä ja kasvot paistavat valkeina pieluksella.


"Ei, muuten vain —" ja sitten syvän surullisesti — "Minusta ei sitten
enää ole miksikään."

"Sinusta! Synti sitä on sanoa sinun, jolla on aina ollut päätä ja


kuntoa enemmän kuin meillä muilla yhteensä." — Poke yrittää
parastaan —. "Ja välipä nyt tästä yhdestä jalasta, kun paras
miehessä on jälellä. Sitä sanoi Aunekin, että olisi paljon hullumpaa,
jos se olisi esimerkiksi käsi. Ja kylläpähän sinä tästä vielä kohennut
kaikin puolin. Älä ole milläsikään."

"Vaan kun en oikeastaan kerinnyt olemaan miksikään hyödyksi."

"Vai et hyödyksi. Olithan ensimäisiä — ja helmikuussa, muistat


sen, olivat miehet kalliita."
"Ja sitten on niin raskasta ajatella, että te toiset siellä kannatte
kaiken kuorman sillä välin kun —"

"— — kun sinä makaat ja haudot silkkoja tyhmyyksiä." — Poke


sieppasi entisellään nokkelana sanat hänen suustaan. — "Viljelehän
järkeäsi, ukkoseni. — Miksi siis sinä makaat tässä ja kärsit? — Etkö
isänmaasi tähden, kuten muutkin. Eikö se sitten ole sama, missä se
tapahtuu, kunhan miehenä kantaa kohtalonsa — niin, tappionsakin,
Kuules, minusta tuntuu, että tässä sinun paikallasi vasta
miehuullisuutta kysytäänkin, etkö usko?" — Ja sitten veljellisellä
lämmöllä: "Tuossa se olisi, sanon minä, vapaudenristi paikallaan."

Hän taputtaa Arvon paidanrintaa, mutta ei hiiskahdakaan, että


hänellä on sellainen kalleus kotona, saatu erään huimanrohkean
öisen partion jälkeen.

"Miksi sinä sen pois otat?" oli ihmetellyt sisar, joka tapasi Poken
itse teossa, ratkomassa nauhaa.

"En minä, kun ei Arvollekaan vielä ole annettu", oli Poke lyhyeen
vastannut.

Ja sitten ystävykset siirtyivät puhumaan niiden päivien suurista


tapahtumista, iloisista voitonviesteistä ja ratkaisun varmuudesta.

"Kohta saat terveisiä Viipurista", kehaisee Poke poikamaiseen


tapaansa. — "Siihen mennessä toki sinäkin hiivittäydy tuohon
ikkunan poskeen, kun komppanian pojat hurraavat jälleen kotiansa
kohti. Me teemme sinulle tuolta ikkunan alta uljaasti kunniaa kuin
itse Mannerheimille. — Sekin suuruus on muuten nähty ihan näillä
silmin. Kävi tervehtimässä poikia siellä etulinjoilla. Sillä se oli ryhti ja
katsanto kuin Napoleonin kuvalla."
Hän "turisee" hilpeästi kuin kuunaan. Sitä on niin soma kuunnella,
Poken rupatusta. Se tulee ryöpsähtelee välittömänä ja tuoreena,
tekee äkkikäänteitä solahdellen alati uusiin uomiin. Ja kun hoitajatar
apulaisineen tulee hetken perästä hakemaan Arvoa
leikkuuhuoneeseen, hämmästyy hän syttyneitä silmiä ja punerrusta
poskilla.

"Rintamatuuli tekee hyvää", hymyilee hän Pokelle ja vetäytyy


käytävään, ettei häiritsisi heidän jäähyväisiään.

"Joko sinun nyt täytyy?"

"Niinhän se on määrä. Huomenna on oltava perillä. Olipa sentään


asia, että tämänkin verran."

"Niin, kiitos. Taisit tehdä minusta ihan elävän ihmisen."

"Tyhjiä. Hätäkös tässä nyt enää. Pidä vain miehen kurssi eläkä
anna luonnon aleta."

"Koetetaan, koetetaan."

"Ja voimmehan kirjottaakin. Minä tietysti annan raporttini


sotilaalliseen sähkösamatyyliin."

"Yhtä tervetulleita, vaikka miten lyhyet. — Sanohan toisillekin


terveisiä ja voikaa hyvin kaikki."

"Sinä samaten." — Mutta äkkiä Poke ottaa häntä väkevin käsin


hartioista ja sanoo oudon syvällä äänellä:

"Nyt sen voimme sanoa, että olemme olleet veljiä elämässä ja


kuolemassa, me kaksi —" ja sitten vielä matalammin — "Tiedätkö,
kuule. Sinun rinnallasi olisi hyvä vaikka kaatua."

Oven takaa vielä kuuluu hänen raikas äänensä, kun hän


hyvästelee hoitajatarta. Sitten reippaitten poistuvien askelten kaiku
— se pitkä käytävä kokoaa niin merkillisesti äänet. Sitten lähenevät
taas keveät askeleet ovea. Arvoa haetaan leikkuuhuoneeseen.

Se on jokapäiväinen kidutus, eikä lääkäri ole kertaakaan hennonut


ryhtyä huumaamatta tuskalliseen käsittelyyn. Mutta tänään sanoo
potilas lujasti ja selkeästi:

"Tohtori, ei oteta mitään nukutusaineita. Minulla on kai sitä lajia jo


liiaksikin veressä, kun muistelen, miten runsaasti ensimäinen
hoitajani niitä viljeli."

"Kuten tahdot", lääkäri katsoo pitkään potilaaseensa — "kuten


tahdot.
Jos vain kärsit kuunnella."

"Moni kärsii isänmaan tähden paljon enemmän" — tulee hiljaa ja


vakavasti, mutta säteilevin silmin.

Lääkäri ryhtyy työhönsä.

Sillä kertaa olivat tällaisiin tottuneen vanhemman hoitajattarenkin


kasvot liikutuksesta valkeat, mutta nuori poika siinä leikkuupöydällä
puri hampaansa yhteen niin että kuului, eikä yksikään valitus päässyt
hänen huultensa yli.

Mutta kun hänet sitten tuskien herpaisemana kannettiin


vuoteeseensa, seisoi lääkäri, kylmä karski mies, kauan ikkunan luona
selin muihin ja mietti.
*****

Ja sitten tuli kevät pitkin kiirehtivin askelin. Satoi virtanaan jonkun


vuorokauden ja sen perästä oli kirkkaita aurinkoisia päiviä. Ne tekivät
lopun kelistä. Eräänä aamuna saattoi Arvo kuulla pyörien ratinan
alhaalta hevostieltä. Ajurit olivat vaihtaneet rekensä rattaisiin.

Avonaisen ikkunan kautta tulvasivat sisään hilpeät keväiset äänet.


Räystäät ja katurännit pitivät iloista hälinää. Ja kevättuuli —
viileähkö vielä, sillä suurten selkien jäät olivat siihen kylmyyttään
henkineet — liehutteli valkeita uutimia ja hyväili sairaan pojan
kasvoja, jotka alkoivat jo vienosti punertaa.

Eräänä päivänä sai kaupunki kuin sähkötäräyksen ja kapsahti


miehissä jalkeille. Saapui korkeita vieraita — itse "valkoinen
kenraali." Se pani kaikki, mitä lie kaupungissa ollut miehistä sukua,
vaaksahousuista lähtien hamaan vanhaan tulliherraan, joka jo
horjahteli kohti kunnianarvoista yhdeksääkymmentään, tiukkaan
perusasentoon. Ei siinä kädenkäänteessä mitään erinäisiä
juhlallisuuksia kyetty puhaltamaan kokoon. Kunpahan nyt seisottiin
kunniakujana ja hurrattiin kurkut "kukonpojiksi."

Arvo Partio makasi ja kuunteli, miten räystäät soittivat


helähtelevää xylofoonia katurännien hoitaessa meluisaa säestystä,
kun ovi aukesi ja sisään astui lääkärin saattamana ylhäinen
sotilashenkilö. Arvo tiesi siinä hetkessä, kuka hän oli ja lennähti
punaiseksi.

Vieras lähestyi vuodetta ja sanoi eräänlaisella sydämellisellä


arvokkuudella:
"Olen kuullut, että olet ollut uljas poika sekä rintamalla että
varsinkin täällä. Isänmaan nimessä annan sinulle tämän vapauden
ristin." — Hän laski sen Arvon rinnalle ja kuunteli hymyillen, kun
Arvo, silmissä kostea kimmellys ja ääni värähdellen koki toimittaa:

"Ei olisi pitänyt. Mitäs minusta, kun niin lyhyen ajankin vain olin.
Toiset toverini, ne ovat olleet koko ajan. Niille pitäisi antaa."

"No, no, kyllähän muidenkin kelpo poikiemme ansiot aikanaan


saavat tunnustuksen." — "Valkoinen kenraali" taputti häntä kevyesti
olalle. — "Toivon, että parannuttuasi edelleen palvelet maatasi, ellet
kiväri kädessä, niin toisin asein."

"Harvinaisen kirkas katse", sanoi hän ovessa lääkärille, joka opasti


häntä kierroksella haavottuneiden luona.

Mutta Arvo ei oikein jaksa tajuta tätä kaikkea. Tuskin vielä


silloinkaan, kun "valkoisen kenraalin" juna on jo vierinyt tiehensä
valtavien eläköönhuutojen saattamana ja Heikki veli ryntää tuulen
tuomana suoraan asemalta Arvon luo purkamaan ihmeellisiä
vaikutelmiaan. Hän on niin täyteen ladattu kuin räjähtämäisillään.

Ja miten hän loistaa ja mahtailee. Tämä on ilmeisesti hänen


elämänsä ylpein päivä. Hänhän on ensi kertaa maailmassa nähnyt
ihmeitten ihmeen ja pojanunelmiensa korkeimman kunnian huipun:
oikean elävän kenraalin, ei mitään kuvaa. Ja ajatella -hän oli
puhutellut Heikkiä.

"Mitäs, kun minä seisoin siinä asemapihan portilla, niin että se


kulki ihan tuosta noinikään. Katsohan, noin läheltä." — Hän näyttää
niin läheltä kuin olisi Mannerheimin liepeet suorastaan hiipaisseet
hänen pientä terhakkaa pystynenäänsä. — "Ja minä seisoin
puhtaasti 'stillgestanden', uskotko?"

"Kuin tinasotamies, uskonhan minä."

"Ei, näinikään, katsohan! —" Hän pöyhistelee keskilattialla suorana


kuin tikku, pyöreäkuoppainen lapsenleuka pönäkästi pystyssä ja
kyynärpäät hauskasti sojottaen ulospäin kuin kaksikorvaisella
padalla. Arvon pingottunut mieli laukeaa keveään nauruun.

"Ja sitten se sanoi, että, arveles kun se sanoi ihan näinikään, että
'sinä olet varmaankin meidän reippaita karjalaisia koulupoikiamme',
sanoi se. Ja minäkös tein kunniaa — tällä lailla, katsohan ja sanoin
että" — se kiljaistaan kaikella keuhkojen väellä — "ensimäisellä
luokalla, herra kenraali."

"Olehan ole, kuulenhan minä vähemmälläkin", tyynnyttelee


vanhempi veli. Mutta Heikki, naama yhä loistaen siinä kunnian
päivänpaisteessa, palpattaa edelleen:

"Ja sitten se nauroi ja iöi minua olalle. Ja ne nauroivat muutkin


sotaherrat."

"No vähemmälläkin", pääsee Arvoltakin jo ihan helanauru.


"Sinähän järjestit heille oikean pienen paraadin."

"Nii-in", riemahtaa Heikki itsekin. "Ja minä tein kunniaa ihan koko
ajan, kun ne menivät ohi. Ja niitä oli koko junallinen, mutta kaikkein
uljain oli Mannerheim. Se oli sitten siinä paikassa kuin ne
komeimmat kuvat siinä isän suuressa 'Vänrikki Stoolissa.' Hatussa
vain ei ollut töyhtöjä. Miksikähän eivät enää pidä?" — Ja yhteen
henkäykseen: "Mutta, että se viitsiikin ajaa junassa ihan kuin
muutkin ihmiset. Minä jos olisin, niin ajaisin vain lentokoneella. Etkö
luule, että kenraalit saavat sellaisenkin ihan oman, ja mitä vaan —."

"Taitavatpa saada."

"Ja minä en antaisi kenenkään muun sitä ohjata ja lentäisin aina


muita korkeammalla. Enkä minä ottaisi minun ilmalaivaani muita kuin
toisen luokan Tolvasen. Siinä on sitten kanssa sellainen poika, että
se ei pelkää, ei niin mitään." — Ja hetken perästä: "Nyt minä tiedän,
mikä minusta tulee, kun tulen suureksi."

"No mikä? Ajurihan sinusta ensin piti tulla, ja sitten viime kesänä
ajattelit, että autonkuljettaja olisi sentään reilumpi."

"Pyh", pihahtaa ylenkatseellisesti toinen, että kun veli muka yhä


vieläkin niin matalalle tähtäilee, ne unelmat on jo ammoin potkaistu
nurin. Hän pullistaa rintaansa ja kajauttaa kantansa yhteen:

"Ei kun sotamies — sotamies tästä pojasta tulee!" — Ja tuleva


karski sotamies teikkaroi riemuissaan paraatimarssia äkkikääntein
ympäri huoneen. Sitten pysähtyy ja kunniaa tehden hihkaisee vielä
kerran:

"Eläköön kenraali!"

Mutta vanhempi veli on aivan tikahtua hilpeyteensä. Ilmeisesti


tämä viimeinen "kunnia" oli tarkotettu korkealentoisen sotamiehen
omalle tulevaiselle ylhäisyydelle.

"Ja minä jään ijäkseni nahkapojaksi. — Älä nyt sentään vielä


ilmaan lennä", tasottelee Arvo. — "Jos herra kenraali suvaitsisi
hetkeksi istua tuohon, niin näyttäisin jotain." — Arvo vetää
yöpöytänsä laatikosta esiin vapaudenristin.
Ihme, ettei Heikki veli siinä hetkessä istahtanut lattialle
ihmetyksestä, sillä vauhdilla kun hupsahti alas maaperään
kenraalinunelmiensa korkeuksista ja jäi silmät renkaina tuijottamaan
siihen ihmeeseen.

"Kenen se on sellainen?" — Hän nieleskeli ja lipoi kielellään.


Sellainen oli hänellä tapa, milloin hän tunsi itsensä neuvottoman
noloksi — niinkuin esimerkiksi kielioppitunneilla.

"Minun. Mannerheim itse antoi."

"Manner —" Heikki eistyi jo tarkastamaan sitä kädestä pitäen


taikauskoisen hartaudella. Sitten hän toipui ja ratkesi riemuun:

"Eläköön — onpa meidänkin kotona sitten vapaudenristi!"

Siinä hetkessä hän sai jalat alleen ja sen häntä nähtiinkin. Yleensä
Heikille aina tuli äkkilähtö, nyt hän sananmukaisesti haihtui. Kotiin
oli tietysti lennätettävä sana ja Kaatrakoskelle ja toisen luokan
Tolvaselle.

*****

Ovelle koputetaan.

"Minä se vain. Siellä meidän alapuutarhassa kukkivat krookukset


parhaillaan. Niitä on valkeita ja sinisiä. Minusta ovat valkeat
kauneimmat."

Se on tohtorin Aune. Hän on eräiden toveriensa kanssa ottanut


nimiinsä sairashuoneen "kukkamonopolin", niinkuin isä leikillään
sanoo.
"Ja sitten toin Poken kirjeen sinulle lukea, kun hän ei sano nyt
joutavansa kirjottamaan sinulle erikseen."

"Kuulenhan tästäkin, miten heidän on", Arvo avaa sen nopeasti. Se


on pian luettu ja lopussa seisoo juhlallisen lyhyesti:

"Ei vielä, mutta kohta."

Niihin aikoihin jo oli kevätilma täynnä kiihkeää odotusta ja iloista


voitonvarmuutta. — "Pian kuullaan uusia", sanoivat ihmiset toisilleen
rohkaisevasti, vaikka sydäntä värisytti ajatellessa voiton hintaa.

"Nyt minä tunnen, että saan ja tahdon elää ja että minuakin vielä
tarvitaan", sanoo Arvo Partio nuorelle tytölle, joka asettelee kukkiaan
veteen ja on itse niin terve ja tuore ja aamunraikas. — "Olen
ajatellut paljon kaikenlaista, minullahan on hyvää aikaa. — Se vanha
välskäri, tiedäthän, puhui minulle niin merkillisesti erotessa. 'Sinun ja
sinunlaistesi on korjattava tämän sodan rumat jäljet', sanoi se. Ja
mitä kauemmin sitä miettii, sitä selvemmäksi se käy. Se on sitä
ainaista uudelleen alkamista ja rakentamista, jota elämä oli
menneillekin polville — toisenluontoista ja vaikeampaa vain."

"Kun vain voisi olla oikein hyvä. Ei vihata ketään eikä kostaa. Vain
tahtoa oikeutta." — Nuori tyttö katselee miettien eteensä.

"Niin pitäisi. Sitä varten kannattaa elää. — Kaikella on niin


ihmeellisesti oma tarkotuksensa, niinkuin silläkin, että minun piti
nähdä elämää siellä rintaman toisellakin puolen. Oli niitä sielläkin
ihmisiä, niinkuin se välskäri sanoi —."

"Minun pitää lähteä. Voi hyvin taasen ensi näkemään. Tiedätkö,


sinä olet jo ihan ennallasi. Vain hieman laiha ja kalpea. Odotahan,
kun kesä tulee."

Ja Arvo onkin ennallaan, mielen tasapainoon nähden, makaa


tyynenä ja kirkkain miettivin silmin. Eikä hänen valoisa mielialansa
erityisesti synkisty silloinkaan, kun lääkäri kerran tuskallisen
kääreiden muuton jälkeen sanoo, että hänellä on vielä monta pitkää
kuukautta edessäpäin. Hän nyökkää vain tyynen alistuvana:

"Täytyyhän minunkin — kohdaltani."

Mutta kun poika on viety pois, sanoo lääkäri apulaiselleen:

"Mistä ihmeestä hän oikein tuon moraalisen voimansa noutaa?


Järkevästi otettuna on hänen seitsemäntoistavuotias elämänsä
tuhottu. Mitä hän on muuta kuin raajarikkoinen raukka tämän
perästä."

"Ja kuitenkin hänessä on virkeätä elämänhalua enemmän kuin


monella meistä, jotka kuljemme terveillä jaloillamme", täydentää
apulainen, nuori lääketieteen ylioppilas.

"Sehän tässä juuri ihmetyttää. Minä olen aina ollut kylmän järjen
ihminen ja suuri epäilijä varsinkin tunteiden arvoon nähden. Itseltäni
on ikäänkuin puuttunut elintä, jolla koetaan voimakkaat
tunnevirtaukset. Minun täytyy rehellisesti tunnustaa katselleeni
elämää ja ihmistä liian matalalta näkökulmalta. Sen olen oppinut
tuolta nuorelta pojalta."

"Niin, hänellä on se hehkuva isänmaallisuutensa sisäisenä


käyttövoimanaan. Sitäkö tohtori ajatteli?"

"Sitä. Katsokaas, minä olen epäillyt isänmaallisten tunteidenkin


alkuperäisyyttä, pitänyt niitä vain teennäisen paisutuksen ilmauksina.
Vaan kyllä niiden täytyy sittenkin olla jotain aivan oleellista ja
ulotuttaa juurensa luonnonvaistoihimme, niinkuin tuossa pojassa."

"Niin, hän oli aivan suurenmoinen sillä kertaa, kun hän kieltäytyi
ottamasta huumausaineita ja sanoi vain yksinkertaisesti: 'Kärsiihän
moni isänmaan tähden paljon enemmän'."

"Se on eräänlaista hiljaista miehekkyyttä, syvää ja totta." —


Tohtori katselee mietteissään eteensä leikkuupöydälle ja jatkaa:

"Täällä meillä se sankari tutaan. Luulisin, että joukkoinnostuksen


huumassa voi heittäytyä vaaroihin ja suorittaa hetkellisiä
voimannäytteitä siveellisesti heikompikin luonne — jos nyt on
vastaava määrä fyysillistä voimaa. Mutta kun joutuu yksin
kärsimyksineen, niin pitää olla syntyperäinen sankari voidakseen
kantaa kohtalonsa niinkuin tämä poika." — Ja sitten syvän
lämpimästi kuin liikutettuna:

"Sanokaamme, että hän on poikkeuksellinen ilmiö, mutta riittää,


että on todellisuudessa nähnyt senkin."
VOITTOHUUTOJEN KAIKUESSA.

"Rintama liikkuu eteenpäin. Vappuna marssimme Viipuriin", tiedottaa


Poken viimeinen kirje.

Oli enää kolme päivää Vappuun. Odotus jännitti mielet


lujimmilleen. Ja nyt jo osattiin arvioida ennakolta. Ennen Tampereen
ja Raudun valloitusta ei tiedetty kuvitellakaan, minkä ne maksoivat.
Nyt se tiedettiin, ja Viipurin tähden oli koko ajan muutenkin vapistu.

Ne varustukset, joita ryssät koko maailmansodan ajan olivat


kaupungin ympärille kyhäilleet!

Mutta silloin tapahtui kuin ihme — kevään ihme.

Padot avautuivat itsestään ja vastustus suli ja hupeni kuin talven


jäljet kevään voittokulun tieltä.

Vapun jälkeisenä päivänä kun voitonviestit kiersivät ympäri maan,


sai Arvo Partio kortin. Siinä oli Suomen leijona ja sen alla juhlalliset
sanat:

"In hoc signo vinces." [Tässä merkissä olet voittava.]

Ja toisella puolella:
"Tänään marssi voittoisa Karjalan armeija Viipuriin."

Se oli "Vapauden veljiltä" matkan periltä. Mutta Arvo Partio ei


voinut sille mitään, että voitonriemuun sekoittui pisarainen
katkeruutta:

Voi, jos sittenkin olisi saanut olla mukana —.

Myöhemmin päivällä tuli tieto, että Poke oli jäänyt Naulasaaren


veriselle kankaalle, kaatunut aivan voiton kynnyksellä, kun jo
vastaisella puolella valkoiset marssivat kaupunkiin riemuhuutojen
kaikuessa.

Vanha rehtori itse toi suruviestin Arvolle.

"Se on niin, että vain paras oli tässä kyllin hyvä", sanoi hän.

Ja nähdessään, miten Arvon silmissä aivan kuin sammui jokin,


laski hän kätensä pojan päälaelle:

"Sanoinhan minä kerran, että isänmaa teistä saisi kunniaa. En


voinut aavistaa silloin, että se teiltä tulisi vaatimaan näin kalliin
uhrin" — hänen äänensä värähteli — "Poikani, te olette verellänne
maksaneet Suomen vapauden lunnaat ja osottaneet, että tässäkin
sukupolvessa on niitä, jotka ovat syntyneet sankareiksi."

*****

Mutta kun historia kerran kertoo tulevien sukupolvien pojille, mitä


saivat kokea karjalaiset pojat Suomen vapaussodassa talvena 1918,
on se varmasti lisäävä:
"He olivat hakkapeliittain sankarisukua. Heidän ei tarvitse hävetä
uljaita edeltäjiään ja aseveikkojaan, Viipurin lukiolaisia."
*** END OF THE PROJECT GUTENBERG EBOOK ISIEN TEILLÄ ***

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
Welcome to our website – the perfect destination for book lovers and
knowledge seekers. We believe that every book holds a new world,
offering opportunities for learning, discovery, and personal growth.
That’s why we are dedicated to bringing you a diverse collection of
books, ranging from classic literature and specialized publications to
self-development guides and children's books.

More than just a book-buying platform, we strive to be a bridge


connecting you with timeless cultural and intellectual values. With an
elegant, user-friendly interface and a smart search system, you can
quickly find the books that best suit your interests. Additionally,
our special promotions and home delivery services help you save time
and fully enjoy the joy of reading.

Join us on a journey of knowledge exploration, passion nurturing, and


personal growth every day!

ebookmasss.com

You might also like