Use Deephaven with AWS EC2
Amazon Web Services (AWS) is the world's most popular cloud computing service. It offers a wide variety of cloud solutions - these tend to pair well with Deephaven Community Core.
This guide will show you how to run Deephaven on an AWS EC2 (Elastic Compute Cloud) instance, then connect to the UI from your local machine and run queries.
Create an AWS EC2 instance
The type of AWS EC2 instance you will need to make will depend entirely on what operating system you prefer, what kind of data you want to work with, and the nature of the calculations you wish to execute. There are many different AWS EC2 instance types to choose from.
AWS offers a variety of operating systems for cloud instances. For this blog, we will create an AWS EC2 instance with AWS-Linux as the OS with the following steps.
- Follow the steps in Amazon's Set up to use Amazon EC2 guide.
- Follow the steps in Amazon's Get started with Amazon EC2 Linux instances guide.
- Read any of Amazon's other tutorials that fit your needs.
Install and run Deephaven
We recommend using Docker to install and run Deephaven from the cloud:
Follow the instructions in the linked guides above to install Deephaven on your AWS EC2 instance.
AWS EC2 2022 Linux instances come with amazon-linux-extras installed. Java 11 (required by source builds) can be easily installed on an AWS Linux instance with this command.
sudo amazon-linux-extras install java-openjdk11
If amazon-linux-extras
is not installed on your instance, you can install it with yum
.
sudo yum install -y amazon-linux-extras
A full list of software that can be easily installed with amazon-linux-extras
can be found here.
Amazon also offers their own OpenJDK distribution, Corretto. It works well on AWS, and can be used in place of Oracle's OpenJDK. Corretto user guides can be found here. For this guide, we'll install Corretto 11 on AWS Linux 2.
sudo yum install java-11-amazon-corretto
Connect to Deephaven
With Deephaven running on your AWS instance, all that's left to do is to connect to the user interface (UI) via your local machine. For that, you'll need the IP or hostname of your AWS EC2 instance. For example, let's say that the IP of your instance is 172.16.1.1
, and that you're running Deephaven on the standard port 10000
. In your web browser, go to http://172.16.1.1:10000/ide
, and you'll see your Deephaven UI!