• Stars
    star
    230
  • Rank 172,939 (Top 4 %)
  • Language
    JavaScript
  • License
    Other
  • Created about 7 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Cumulus Framework + Cumulus API

Cumulus Framework

npm version Coverage Status

About Cumulus

Cumulus is an open source cloud-based data ingest, archive, distribution, and management framework developed for NASA's future Earth Science data streams. This repo supports the development, deployment, and testing of Cumulus and supplies useful tips on configuration, workflow management, and operations. To learn more about Cumulus and NASA's Earth Observing System Data and Information System (EOSDIS) cloud initiatives go to More Information.


πŸš€ Getting Started

Below is in-depth guidance to help get you started with your Cumulus development. To get a quick start on Cumulus deployment go to our Getting Started section.

Contents


πŸ“– Documentation

πŸ”¨ Development

The Cumulus core repo is a monorepo managed by Lerna. Lerna is responsible for installing the dependencies of the packages and tasks that belong in this repo. In general, Cumulus's npm packages can be found in the packages directory, and workflow tasks can be found in the tasks directory.

To help cut down on the time and disk space required to install the dependencies of the packages in this monorepo, all devDependencies are defined in the top-level package.json. The Node module resolution algorithm allows all of the packages and tasks to find their dev dependencies in that top-level node_modules directory.

TL;DR - If you need to add a devDependency to a package, add it to the top-level package.json file, not the package.json associated with an individual package.

Installation

This is for installation for Cumulus development. See the Cumulus deployment section for instructions on deploying the released Cumulus packages.

Prerequisites

  • NVM and node version 16.19.0
  • AWS CLI
  • Bash
  • Docker (only required for testing)
  • docker-compose (only required for testing pip install docker-compose)
  • Python 3.10
  • pipenv

You may use brew to install the prerequisites. Visit Homebrew documentation for guidance.

Install the correct node version:

nvm install
nvm use

Install Lerna

We use Lerna to manage multiple Cumulus packages in the same repo. You need to install Lerna as a global module first:

npm install -g lerna

Install Local Dependencies

We use npm for local package management. Run the following to get your dependencies set up.

npm install
npm run bootstrap

Build all packages:

npm run build

Build and watch packages:

npm run watch

To add new packages go to Adding New Packages for guidance.

Running the Cumulus APIs locally

Start the API:

npm run serve

Or start the distribution API:

npm run serve-dist

See the API package documentation for more options.

πŸ“ Tests

Unit Tests

LocalStack

LocalStack provides local versions of most AWS services for testing.

The LocalStack repository has installation instructions.

Localstack is included in the docker-compose file. You only need to run the docker-compose command in the next section in order to use it with your tests.

Docker containers

Turn on the docker containers first:

npm run start-unit-test-stack

Stop localstack/unit test services:

npm run stop-unit-test-stack

Run database migrations

npm run db:local:migrate

Using an AWS-hosted Elasticsearch server

The tests can be run against an Elasticsearch server running in AWS. This is useful if you are using an ARM-equipped Mac and are unable to run the old Intel version of Elasticsearch in Docker. These instructions assume that you have a deployment of Cumulus available, and the deployment name is "EXAMPLE".

Pre-Reqs
  • The AWS CLI is installed
  • The Session Manager plugin for the AWS CLI is installed
  • jq is installed
  • Your Cumulus deployment specified a key_name in cumulus-tf/terraform.tfvars that will grant you access to the EC2 instances that are part of that deployment
  • You are able to SSH into one of your EC2 instances (you are connected to a NASA VPN if required)
Configure ssh

Add the following to your ~/.ssh/config file

Host i-*
  User ec2-user
  ProxyCommand sh -c "aws ssm start-session --target %h --document-name AWS-StartSSHSession --parameters 'portNumber=%p'"
  StrictHostKeyChecking no
  UserKnownHostsFile /dev/null
Start the ssh tunnel to Elasticsearch

Open an SSH tunnel to Elasticsearch with the following command.

./bin/es-tunnel.sh EXAMPLE

At this point you can send requests to https://localhost:8443 and get responses from your Elasticsearch domain running in AWS. Note that, because you're tunneling TLS-encrypted traffic, the certificates are not going to match. The test code handles this already but, if you're using curl, make sure to use the -k option to disable strict certificate checks.

$ curl -k https://localhost:8443
{
  "name" : "ABC123",
  "cluster_name" : "123:abc-es-vpc",
  "cluster_uuid" : "abc-Ti6N3IA2ULvpBQ",
  "version" : {
    "number" : "5.3.2",
    "build_hash" : "6bc5aba",
    "build_date" : "2022-09-02T09:03:07.611Z",
    "build_snapshot" : false,
    "lucene_version" : "6.4.2"
  },
  "tagline" : "You Know, for Search"
}
Run the tests

With the tunnel configured, you can now run the tests with the following command:

env \
  LOCAL_ES_HOST_PORT=8443 \
  LOCAL_ES_HOST_PROTOCOL=https \
  LOCAL_ES_HOST=localhost \
  LOCALSTACK_HOST=127.0.0.1 \
npm test

Run tests

Run the test commands next

export LOCAL_ES_HOST=127.0.0.1
export LOCALSTACK_HOST=127.0.0.1
npm test

Coverage tests

If tests are working, run coverage tests

export LOCAL_ES_HOST=127.0.0.1
export LOCALSTACK_HOST=127.0.0.1
npm run test:coverage

These tests will fail if coverage drops below certain thresholds or if unit tests fail.

an environment variable can be set to only measure and not threshold

export FAIL_ON_COVERAGE=false
npm run test:coverage

Additionally, you can facilitate updating coverage values with the included coverage script

npm run coverage -- --update

Integration Tests

For more information please read this.

Running tests via VS Code debugger

Copy the .vscode.example directory to .vscode to create your debugger launch configuration. Refer to the VS Code documentation on how to use the debugger.

πŸ”¦ Code Coverage and Quality

For more information please read this.

πŸ“¦ Adding New Packages

Create a new folder under packages if it is a common library or create folder under cumulus/tasks if it is a lambda task. cd to the folder and run npm init.

Make sure to name the package as @cumulus/package-name.

Running command in all package folders

lerna exec -- rm -rf ./package-lock.json

Cleaning Up all the repos

npm run clean

Contribution

Please refer to: https://github.com/nasa/cumulus/blob/master/CONTRIBUTING.md for more information.

πŸ›’ Release

To release a new version of cumulus read this.


More Information

For more information about this project or more about NASA's Earth Observing System Data and Information System (EOSDIS) and its cloud work, please contact Katie Baynes or visit us at https://earthdata.nasa.gov.

More Repositories

1

openmct

A web based mission control framework.
JavaScript
11,117
star
2

fprime

FΒ΄ - A flight software and embedded systems framework
C++
10,018
star
3

NASA-3D-Resources

Here you'll find a growing collection of 3D models, textures, and images from inside NASA.
Mathematica
2,804
star
4

astrobee

NASA Astrobee Robot Software
C++
811
star
5

apod-api

Astronomy Picture of the Day API service
Python
800
star
6

earthdata-search

Earthdata Search is a web application developed by NASA EOSDIS to enable data discovery, search, comparison, visualization, and access across EOSDIS' Earth Science data holdings.
JavaScript
738
star
7

trick

Trick Simulation Environment. Trick provides a common set of simulation capabilities and utilities to build simulations automatically.
C++
685
star
8

Transform-to-Open-Science

Transformation to Open Science
639
star
9

cFS

The Core Flight System (cFS)
CMake
537
star
10

XPlaneConnect

The X-Plane Communications Toolbox is a research tool used to interact with the X-Plane flight simulator
C
536
star
11

osal

The Core Flight System (cFS) Operating System Abstraction Layer (OSAL)
C
486
star
12

api-docs

api.nasa.gov
SCSS
433
star
13

NASTRAN-95

Fortran
393
star
14

spaceapps

363
star
15

cFE

The Core Flight System (cFS) Core Flight Executive (cFE)
C
343
star
16

World-Wind-Java

World Wind, an open source 3D interactive world viewer, was created by NASA's Learning Technologies project, and released in mid-2004. It is now developed by NASA staff and open source community developers.
C++
328
star
17

instructions

https://github.com/nasa/nasa.github.io/blob/master/docs/INSTRUCTIONS.md
HTML
328
star
18

ogma

Haskell
327
star
19

Common-Metadata-Repository

Clojure
302
star
20

VICAR

291
star
21

CFL3D

Fortran
267
star
22

Open-Source-Catalog

Contains the NASA open source software catalog for automatic deployment to code.nasa.gov
JavaScript
259
star
23

openmct-tutorial

A tutorial for OpenMCT that guides you through integrating historical and realtime telemetry.
JavaScript
242
star
24

code-nasa-gov

code.nasa.gov site leveraging the Open Source Catalog on github.com, powered by Polymer
CSS
236
star
25

eefs

EEPROM File System
C
232
star
26

T-MATS

An open source thermodynamic modeling package completed on behalf of NASA. The Toolbox for the Modeling and Analysis of Thermodynamic Systems (T-MATS) package offers a MATLAB/Simulink toolbox that gives a developer the ability to create simulations of such thermodynamic systems as turbomachinery and gas turbines. Keywords: TMATS, Control System, Numerical Methods, Newton-Raphson, Jacobian Calculation, Propulsion, Aircraft Engine, Jet, Turbofan, Turbojet, Compressor, Turbine, Nozzle, Inlet, open source
HTML
216
star
27

isle

JavaScript
213
star
28

europa

C++
207
star
29

nasa-latex-docs

An easy and convenient package to create technical LaTeX documents.
TeX
197
star
30

pvslib

NASA PVS Library of Formal Developments
Common Lisp
186
star
31

delta

Deep Learning for Satellite Imagery
Python
184
star
32

CrisisMappingToolkit

NASA Ames Crisis Mapping Toolkit
Python
183
star
33

nos3

NASA Operational Simulator for Small Satellites
C
167
star
34

icarous

ICAROUS is a software architecture for the development of UAS applications
C
147
star
35

DERT

DERT is an open source software tool for exploring NASA's digital terrain models in 3D
Java
142
star
36

NASTRAN-93

NASTRAN is the NASA Structural Analysis System, a finite element analysis program (FEA)
Fortran
134
star
37

ow_simulator

Python
129
star
38

meshNetwork

C++
127
star
39

prog_models

The NASA Prognostic Model Package is a Python framework focused on defining and building models for prognostics (computation of remaining useful life) of engineering systems, and provides a set of prognostics models for select components developed within this framework, suitable for use in prognostics applications for these components.
122
star
40

QuIP

QuIP provides an interactive environment for computing and presenting images and image sequences, manipulating and storing arbitrary data, and general scientific computing and plotting. The current release supports unix-like operating systems (tested on Linux and Mac OSX), and Apple's iOS mobile operating system. GPU acceleration is supported with either CUDA or OpenCL. There is built-in support for psychophysical experimentation, with general-purpose staircase routines and analysis of psychometric functions.
C
118
star
41

autodoc

Create Microsoft Documents automatically using Text and Template files
106
star
42

Kodiak

Library for rigorous verification of non-linear arithmetic
C++
103
star
43

PrognosticsAlgorithmLibrary

MATLAB
103
star
44

EMIT-Data-Resources

This repository provides guides, short how-tos, and tutorials to help users access and work with data from the Earth Surface Mineral Dust Source Investigation (EMIT) mission.
HTML
102
star
45

CompDam_DGD

Fortran
99
star
46

astrobee_android

NASA Astrobee Robot Software, Android
Java
96
star
47

OpenSPIFe

The Open Scheduling and Planning Interface for Exploration (OpenSPIFe) is an integrated planning and scheduling toolkit based on hundreds of hours of expert observation, use, and refinement of state-of-the-art planning and scheduling technology for several applications within NASA.
Java
95
star
48

HDTN

High-rate Delay Tolerant Network (HDTN) Software
C++
90
star
49

PrognosticsModelLibrary

MATLAB
89
star
50

mmt

NASA's Metadata Management Tool.
Ruby
86
star
51

kepler-pipeline

Kepler Science Data Processing Pipeline
C
84
star
52

IDF

C++
80
star
53

nasapress

A WordPress theme built on the NASA Web Design Standards
PHP
79
star
54

PyTDA

Python Turbulence Detection Algorithm (PyTDA)
Jupyter Notebook
78
star
55

RHEAS

Regional Hydrologic Extremes Assessment System
Python
73
star
56

astrobot

A slack bot integration with NASA data
JavaScript
73
star
57

podaacpy

A python utility library for interacting with NASA JPL's PO.DAAC
Python
73
star
58

CCDD

CFS Command and Data Dictionary Tool (CCDDT)
Java
72
star
59

SMCPy

Python module for uncertainty quantification using a parallel sequential Monte Carlo sampler
Python
71
star
60

NASA-Acronyms

JavaScript
71
star
61

harmony

Application for providing services for Earth observation data in the cloud using standards-based APIs
TypeScript
70
star
62

PointCloudsVR

C++
68
star
63

channel-emulator

C++
66
star
64

cFS-GroundSystem

The Core Flight System (cFS) Ground System Lab Tool (cFS-GroundSystem)
Python
65
star
65

CFS-101

63
star
66

AprilNav

C++
61
star
67

common-mapping-client

CMC is a starter-kit for creating web-based mapping applications
JavaScript
60
star
68

PSP

The Core Flight System (cFS) Platform Support Package (PSP)
C
60
star
69

NASAaccess

NASAaccess is R package that can generate gridded ascii tables of climate (CIMP5) and weather data (GPM, TRMM, GLDAS) needed to drive various hydrological models (e.g., SWAT, VIC, RHESSys, ..etc)
R
60
star
70

CryptoLib

Provide a software-only solution using the CCSDS Space Data Link Security Protocol - Extended Procedures (SDLS-EP) to secure communications between a spacecraft running the core Flight System (cFS) and a ground station.
C
60
star
71

GTM_DesignSim

MATLAB
59
star
72

dictionaries

A collection of NASA "dictionaries", including thesauri, taxonomies and ontologies.
HTML
58
star
73

libSPRITE

libSPRITE is a set of libraries that have been used on several past projects including flight, technology demonstration, and simulation projects. libSPRITE provides a diverse set of functions to attempt to simplify coding and reduce code errors. For example, libSPRITE defines engineering units as types (i.e., Meters or Radians instead of double or int). It includes an engineering unit aware math library. libSPRITE includes a task scheduling system that abstracts pthreads and includes a publish subscribe data system for data routing. In addition, libSPRITE includes an optional binding to the Lua scripting language for configuring the program, setting parameters, running Lua scripts within C++ tasks and even interacting with the application during runtime.
C++
57
star
74

prog_algs

The Prognostic Algorithm Package is a python framework for model-based prognostics (computation of remaining useful life) of engineering systems, and provides a set of algorithms for state estimation and prediction, including uncertainty propagation. The algorithms take as inputs prognostic models (from NASA's Prognostics Model Package), and perform estimation and prediction functions. The library allows the rapid development of prognostics solutions for given models of components and systems. Different algorithms can be easily swapped to do comparative studies and evaluations of different algorithms to select the best for the application at hand.
57
star
75

utm-apis

The collection of APIs for NASA's UTM project in the form of OpenAPI documents.
55
star
76

cumulus-dashboard

Cumulus API Dashboard
JavaScript
55
star
77

hybridq

HybridQ is a highly extensible platform designed to provide a common framework to integrate multiple state-of-the-art techniques to simulate large scale quantum circuits on a variety of hardware. HybridQ provides tools to manipulate, develop, and extend noiseless and noisy circuits for different hardware architectures. HybridQ also supports large-scale high-performance computing (HPC) simulations, automatically balancing workload among different processor nodes and enabling the use of multiple backends to maximize parallel efficiency. Everything is then glued together by a simple and expressive language that allows seamless switching from one technique to another as well as from one hardware to the next, without the need to write lengthy translations, thus greatly simplifying the development of new hybrid algorithms and techniques.
Python
55
star
78

pretrained-microscopy-models

Python
54
star
79

GFR

GFR (Glenn Flux Reconstruction) software (LEW-19709-1) has been approved for an open source release
Fortran
54
star
80

refine

C
53
star
81

NASA-Space-Weather-Media-Viewer

Space Weather and the Sun.
52
star
82

progpy

The NASA Prognostic Python Packages is a Python framework focused on defining and building models and algorit for prognostics (computation of remaining useful life) of engineering systems, and provides a set of models and algorithms for select components developed within this framework, suitable for use in prognostic applications.
Python
52
star
83

EADINLite

EADIN_Lite Network Protocol
C++
51
star
84

SingleDop

Single Doppler Retrieval Toolkit (SingleDop)
Jupyter Notebook
50
star
85

multipath-tcp-tools

C++
49
star
86

OnAIR

The On-board Artificial Intelligence Research (OnAIR) Platform is a framework that enables AI algorithms written in Python to interact with NASA's cFS. It is intended to explore research concepts in autonomous operations in a simulated environment.
Python
48
star
87

MMM-Py

Marshall MRMS Mosaic Python Toolkit
Jupyter Notebook
48
star
88

ipv6_python

Python
47
star
89

CF

The Core Flight System (cFS) CFDP application.
C
47
star
90

MLMCPy

Python
47
star
91

TTECTrA

An open source, semi-automated, control design tool for subsonic aircraft engine simulations written in the MATLAB/Simulink environment. The Tool for Turbine Engine Closed-loop Transient Analysis provides the user a preliminary estimate of the closed-loop transient performance of an engine model.
47
star
92

WellClear

Well-Clear Boundary Models for Integration of UAS in the NAS
HTML
46
star
93

CertWare

Java
46
star
94

giant

Goddard Image Analysis and Navigation Tool
Python
46
star
95

fpp

F Prime Prime: A modeling language for F Prime
C++
46
star
96

bingo

Python
45
star
97

podaac_tools_and_services

A meta-repository which essentially lists code related to all tools and services software for NASA JPL's PO.DAAC
Python
44
star
98

RtRetrievalFramework

C++
43
star
99

cmr-stac

TypeScript
43
star
100

mplStyle

Matplotlib object oriented style system
Python
43
star