Skip to content

Latest commit

 

History

History
82 lines (65 loc) · 2.8 KB

File metadata and controls

82 lines (65 loc) · 2.8 KB

Setup

Note:- If You have already setup JAVA_17 then skip this step

  1. Java 17 Installation on macOS
    brew tap homebrew/cask-versions
    brew install --cask temurin17
    
  2. Set JAVA_17 Env value. Follow step 2 here

How build & run this project?

Running locally

Install and run DynamoDB on your local machine:

  1. Install AWS CLI and Configure

    1. Install AWS CLI Run following commands
      • curl "https://awscli.amazonaws.com/AWSCLIV2.pkg" -o "AWSCLIV2.pkg"
      • sudo installer -pkg ./AWSCLIV2.pkg -target /
    2. To verify AWS CLI Run following commands
      • which aws
      • aws --version
    3. Configure AWS CLI
      • aws configure
        • Enter AccessKey : "local"
        • Enter SecretKey : "12345"
        • Enter region : "us-west-2"
        • Enter output : "json"
    4. Reference
  2. Install DynamoDB

    1. Download DynamoDB
    2. Extract downloaded file
    3. navigate to the directory where you extracted DynamoDBLocal.jar, and enter the following command.
      • java -Djava.library.path=./DynamoDBLocal_lib -jar DynamoDBLocal.jar -sharedDb
    4. Verify DynamoDB
      • aws dynamodb list-tables --endpoint-url http://localhost:8000
    5. Create table for Ad
      • aws dynamodb create-table --cli-input-json file://example-table-definition.json --endpoint-url http://localhost:8000
    6. Reference
  3. Visualizing the DynamoDB Table data

    1. Download and Install NoSQL Workbench
    2. Open NoSQL Workbench and Setup DynamoDB local connection
      • Click on operation builder
      • Click on Add connection
      • Click on DynamoDB Local
    3. Reference

There are a few options to run the application (from more flexible to least)

  1. You can just use the SpringBoot run functionality that is default in IntelliJ or SpringTools in Eclipse.

  2. Start the service with Maven.

    mvn spring-boot:run -Dspring.profiles.active=local
  3. Package the jar file and run it

mvn clean package
java -jar ./target/example-service-exec.jar

Invoking example Service

You can use your favourite gRPC client (e.g. BloomRPC)

Import path in BloomRPC Then import .proto file

JWT token algo

{
  "alg": "HS256",
  "typ": "JWT"
}