Skip to main content

Local Development Guide

Guide for developing and testing the Zenoo Hub locally without requiring AWS cloud services.

Overview: Two Approaches

The Hub supports two approaches for local development:
  1. Local Provider (Recommended) - In-memory storage with zero dependencies
  2. LocalStack - AWS service emulation for testing AWS-specific behavior

Quick Comparison

When to Use Local Provider

Use local provider when:
  • Developing features that don’t depend on AWS-specific behavior
  • Running unit and integration tests
  • Building CI/CD pipelines
  • Quick prototyping and experimentation
  • No need for data persistence
  • Want instant startup and teardown
Configuration:
Complete local provider guide

When to Use LocalStack

Use LocalStack when:
  • Testing AWS-specific features (DynamoDB queries, TTL, etc.)
  • Validating AWS configuration before deployment
  • Testing multi-region behavior
  • Need persistence between restarts
  • Developing AWS-specific integrations
Configuration:

Local Provider Setup

The local provider requires minimal setup and is perfect for most local development scenarios.

1. Add Dependency

Already included in backend-integration-tests and sample-hub-instance:

2. Configure

application-local.yml:

3. Run

The Hub will start instantly with in-memory storage. All data is lost on restart.

Testing with Local Provider

Example Integration Test:

CI/CD with Local Provider

Perfect for continuous integration:

LocalStack Setup

LocalStack provides local emulation of AWS services.

Installation

Using Docker

Using Docker Compose

Start with:

Hub Configuration for LocalStack

Running the Hub

Accessing LocalStack Services

DynamoDB

Secrets Manager

Testing

Unit Tests

Run unit tests without any cloud services:

Integration Tests with LocalStack

Test Configuration

IntelliJ IDEA Setup

Run Configuration

  1. Create new Spring Boot run configuration
  2. Set main class: com.zenoo.hub.HubApplication
  3. Set active profiles: local
  4. Set environment variables:

Debug Configuration

Same as run configuration with debug mode enabled.

Troubleshooting

LocalStack Not Starting

Tables Not Created

Connection Refused

Check LocalStack is running:

See Also