---
# System prepended metadata

title: Case

---

# Case

Imagine that you are joining as a Senior engineer at Zehitomo. Your first mission is to develop a new functionality whose release date is set to 6 months from now. 

## Questions

### Question 1 (System Design)
Based on the information below, please describe the system design of the product that you plan to build and release. 
Note that you have to build the product form scratch. So you don't need to worry about an existing system. But be aware of the current tech stack.

## Additional information

### Product Requirements
- Administration interface for pro's (eg. flower shop, coiffeur, etc.)
    - Create/edit/publish/disable service opening
    - Assignes budget for advertisement campaings (=> improving ranking position in service search result page)
    - Track requests/revenue and ad campaigns related to service openings


### Tech stack

- Node.js
- Mongo DB
- React
- AWS

# Solution

## System design

企業規模（店舗の数）によってシステムが変わる
まずは１店舗の管理システムから開始
複数ユーザー管理
    1. ID、パスワード（Proの数：1000、1 Proに対して約5ユーザまで）
        AWS Cognito（セキュリティー、管理しやすさ）
        RDS
    2. SNSログイン
サービスの登録、編集、削除
    Transaction管理が必須：AWS Aurora（1 Proに対して20 service）
        Read：
            Tables：一覧、詳細、カテゴリー
        Write
        Update: 240万/年
        Delete

検索
    SolR, ElasticSearch
        検索に必要な情報を一つのドキュメントにまとめ
            Document数：2万
            In-Memory Update
        更新はリアルタイム
        
Node.js/lambda
1 lambda、複数のendpoint

RDS→Batch→SolR

CloudWatch
Datadog
- Database connection数
- Transaction Read/Write
- RDS Memory
- Lambdaのresponse time
- SolRのresponse time

CodePipelineを使いたいが、実際の使い方を要確認
Github Actions

    
Zehitomoの既存APIを利用し、サービス内容をpublishする




