Skip to content

Commit

Permalink
Merge pull request #5 from nautible/feature/modify_directory
Browse files Browse the repository at this point in the history
構造見直しに伴うドキュメント修正
  • Loading branch information
SaitoMunenori authored Apr 7, 2022
2 parents 5f77148 + fd3a92d commit 4012a06
Show file tree
Hide file tree
Showing 8 changed files with 36 additions and 28 deletions.
12 changes: 9 additions & 3 deletions about/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ nautibleの技術スタックを適用することで、以下のような開発
| ---- | ---- |
| コンテナ化 | <ul><li>Docker</li></ul> |
| CI/CD | <ul><li>ArgoCD</li><li>GitHub Actions</li></ul> |
| オーケストレーション | <ul><li>Amazon EKS</li></ul> |
| オーケストレーション | <ul><li>Amazon EKS</li><li>Azure AKS</li></ul> |
| 可観測性・分析 | <ul><li>prometheus</li><li>Grafana</li></ul> |
| プロキシ・サービスメッシュ | <ul><li>Istio</li></ul> |
| ネットワーク・セキュリティ | <ul><li>T.B.D</li></ul> |
Expand Down Expand Up @@ -76,8 +76,14 @@ nautibleは以下のリポジトリを公開しています。必要なリポジ
<tr>
<td>インフラ構築</td>
<td>nautible-infra</td>
<td><ul><li>Infrastructure as Codeの実装</li><li>ArgoCDの構成例</li></ul></td>
<td><ul><li>AWS上にEKSクラスタを構築し、リファレンスアプリケーションをデプロイするものです</li></ul></td>
<td><ul><li>Infrastructure as Codeの実装</li></ul></td>
<td><ul><li>クラウド上にKubernetesクラスタを構築します</li></ul></td>
</tr>
<tr>
<td>エコシステム・アプリケーションの導入</td>
<td>nautible-plugin</td>
<td><ul><li>エコシステム・アプリケーション導入用マニフェストファイル</li></ul></td>
<td><ul><li>Kubernetes上にエコシステムやサンプルアプリケーションを導入します</li></ul></td>
</tr>
<tr>
<td>リファレンスアプリケーション</td>
Expand Down
16 changes: 8 additions & 8 deletions reference/quarkus/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ local-dev.quarkus.log.console.json=false
```
~省略~
containers:
- name: nautible-app-customer
- name: nautible-app-ms-customer
env:
   ~省略~
- name: JAVA_VERSION
Expand All @@ -105,14 +105,14 @@ local-dev.quarkus.log.console.json=false
Listing files to watch...
~省略~
Press Ctrl+C to exit
Forwarding container nautible-app-customer-ff499f84c-r4vhp/nautible-app-customer to local port 8081.
Forwarding container nautible-app-ms-customer-ff499f84c-r4vhp/nautible-app-ms-customer to local port 8081.
Not watching for changes...
Port forwarding service/nautible-app-customer in namespace nautible-app, remote port 8080 -> address 127.0.0.1 port 8080
Port forwarding pod/nautible-app-customer-ff499f84c-r4vhp in namespace nautible-app, remote port 8080 -> address 127.0.0.1 port 8081
Forwarding container nautible-app-customer-ff499f84c-r4vhp/nautible-app-customer to local port 9003.
Port forwarding service/nautible-app-customer in namespace nautible-app, remote port 9000 -> address 127.0.0.1 port 9002
Port forwarding pod/nautible-app-customer-ff499f84c-r4vhp in namespace nautible-app, remote port 9000 -> address 127.0.0.1 port 9003
Port forwarding pod/nautible-app-customer-ff499f84c-r4vhp in namespace nautible-app, remote port 5005 -> address 127.0.0.1 port 5005
Port forwarding service/nautible-app-ms-customer in namespace nautible-app-ms, remote port 8080 -> address 127.0.0.1 port 8080
Port forwarding pod/nautible-app-ms-customer-ff499f84c-r4vhp in namespace nautible-app-ms, remote port 8080 -> address 127.0.0.1 port 8081
Forwarding container nautible-app-ms-customer-ff499f84c-r4vhp/nautible-app-ms-customer to local port 9003.
Port forwarding service/nautible-app-ms-customer in namespace nautible-app-ms, remote port 9000 -> address 127.0.0.1 port 9002
Port forwarding pod/nautible-app-ms-customer-ff499f84c-r4vhp in namespace nautible-app-ms, remote port 9000 -> address 127.0.0.1 port 9003
Port forwarding pod/nautible-app-ms-customer-ff499f84c-r4vhp in namespace nautible-app-ms, remote port 5005 -> address 127.0.0.1 port 5005
```

### 監視
Expand Down
3 changes: 3 additions & 0 deletions referenceapp-architecture/1_context/app-common/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# アプリケーションの概要

## マイクロサービスアプリケーション

リファレンスアプリケーションは商品、注文、在庫、決済、顧客の5つのサービスから構成され,
Kubernetes(EKS)にデプロイされます。クライアントはCloudfrontによってエンドユーザーに配信され、サービスが公開しているAPIにアクセスして商品を購入するユースケースを実現しています。各種詳細についてはリファレンスアプリケーションの[トップページ](../../README.md)から参照できるようになっています。

Expand Down
14 changes: 6 additions & 8 deletions referenceapp-architecture/2_function/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
顧客関連の機能を提供するサービスです。

- リポジトリ
nautible-app-customer
nautible-app-ms-customer
- 機能
- 顧客情報取得
顧客IDを指定して、顧客情報を取得するAPI。
Expand All @@ -15,7 +15,7 @@
商品関連の機能を提供するサービスです。

- リポジトリ
nautible-app-product
nautible-app-ms-product
- 機能
- 商品検索
商品検索を検索するAPI。
Expand All @@ -25,7 +25,7 @@
## 在庫サービス
在庫関連の機能を提供するサービスです。
- リポジトリ
nautible-app-stock
nautible-app-ms-stock
- 機能
- 在庫引当予約
在庫引当の予約を行うAPI。SAGAオーケストレーションから実行されます。在庫数を確認し、在庫引当の予約を行います。
Expand All @@ -35,10 +35,10 @@
在庫引当予約の取り消しを行うAPI。SAGAオーケストレーションから実行されます。SAGA処理中に問題が発生した場合に在庫引当予約を取り消します。

## 決済サービス
決済関連の機能を提供するサービスです。決済種類毎(現金、コンビニ払い、クレジット支払い)にサービスは分離しています。決済処理を取りまとめるサービス(bff)が決済処理を受付て、決済種類毎に分離しているサービスに処理を委譲します
決済関連の機能を提供するサービスです。外部からのリクエストを受け付けるBFFサービスと決済種類毎(現金、クレジット支払い)のサービスがあります

- リポジトリ
nautible-app-payment
nautible-app-ms-payment
- 機能
- 決済
決済を行うAPI。SAGAオーケストレーションから実行されます。
Expand All @@ -48,13 +48,11 @@
## 注文サービス
注文関連の機能を提供するサービスです。
- リポジトリ
nautible-app-order
nautible-app-ms-order
- 機能
- カート情報取得
カート情報を取得するAPI。
- カート情報更新
カート情報を更新するAPI。商品の追加、削除、更新を行う。
- 注文
注文処理を行うAPI。SAGAのオーケストレーションパターン実装です。在庫、決済サービスと連携して決済処理を実現しています。


Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
### ・サービス内データ整合性
注文サービスでのDB(例 AWSの場合はDynamoDB)更新と各サービス呼出メッセージングはアトミックな処理になっていない(注文サービスでのDB更新に失敗しても、各サービス呼出のメッセージングは続行し、呼出先サービスの処理が続行する)。


このような業務トランザクションとメッセージングのアトミックな処理の実現方式として [transaction outbox pattern](https://microservices.io/patterns/data/transactional-outbox.html) などがあるが、リファレンスアプリケーションでは採用していない。

理由としては、1つは前述のサービス間データ整合性で示した通り、サービス間ではサーガ処理中の途中状態に対し、Semantic Lock を導入することで、不整合な処理に対するガードを行っていること。
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,17 @@
```
>skaffold dev --port-forward
Listing files to watch...
- XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-customer
- XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-ms-customer
Generating tags...
- XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-customer -> XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-customer:9bce2ed-dirty
- XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-ms-customer -> XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-ms-customer:9bce2ed-dirty
Found [minikube] context, using local docker daemon.
Building [XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-customer]...
Building [XXXXXXXXXXXX.dkr.ecr.ap-northeast-1.amazonaws.com/nautible-app-ms-customer]...
~省略~
Press Ctrl+C to exit
Watching for changes...
Port forwarding service/customer-dynamodb in namespace nautible-app, remote port 4566 -> address 127.0.0.1 port 4566
Port forwarding service/nautible-app-customer in namespace nautible-app, remote port 8080 -> address 127.0.0.1 port 8080
Port forwarding service/nautible-app-customer in namespace nautible-app, remote port 9000 -> address 127.0.0.1 port 9002
Port forwarding service/customer-dynamodb in namespace nautible-app-ms, remote port 4566 -> address 127.0.0.1 port 4566
Port forwarding service/nautible-app-ms-customer in namespace nautible-app-ms, remote port 8080 -> address 127.0.0.1 port 8080
Port forwarding service/nautible-app-ms-customer in namespace nautible-app-ms, remote port 9000 -> address 127.0.0.1 port 9002
```

Expand Down Expand Up @@ -182,7 +182,7 @@ spec:

アプリケーションのマニフェストはkustomizeで管理している。baseに全環境共通の定義、overlaysに各環境固有の定義(差分)を行い、kustomizeでマージした結果を各環境に適用している。
```
nautible-app-xxx-manifest
nautible-app-ms-xxx-manifest
├─base ・・・全環境共通のマニフェストを管理する。
Expand Down
2 changes: 1 addition & 1 deletion referenceapp-architecture/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
---
## 7. 運用
### 7.1 サービスの運用
- [動作確認用テストデータ](https://github.com/nautible/nautible-app-order/blob/main/testdata.md
- [動作確認用テストデータ](https://github.com/nautible/nautible-app-ms-order/blob/main/testdata.md
"動作確認用テストデータ")
- [Istio](https://github.com/nautible/nautible-infra/blob/main/ArgoCD/ecosystems/base/istio/README.md)
- [監視系(モニタリング/ロギング/トレーシング)](https://github.com/nautible/nautible-infra/blob/main/ArgoCD/ecosystems/base/observation/README.md "監視系(モニタリング/ロギング/トレーシング)")
Expand Down
2 changes: 2 additions & 0 deletions tutorial/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# 環境構築/利用方法

## [環境構築](https://github.com/nautible/nautible-infra "環境構築")

## [エコシステム・アプリケーションの導入](https://github.com/nautible/nautible-plugin "エコシステム・アプリケーションの導入")

0 comments on commit 4012a06

Please sign in to comment.