Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Helltab/dubbo-kubernetes
Browse files Browse the repository at this point in the history
…into feature/ui/framework/vue3

* 'master' of https://github.com/Helltab/dubbo-kubernetes:
  fix demo page refresh problem
  Recursive handling of special cases
  fix problem about after refreshing the page, the current menu item is not activated
  Update README.md
  Update README.md
  Update README.md
  compress images
  update ui demo picture
  update
  update
  add documentation
  Extract public types
  Implement global search style
  Implement global search request and mock
  add i18n
  fix problem about sum of column `span` in a line not match `column` of Descriptions
  Improve the 404 page
  add 404 default page
  charts: Addition of custom resources and authorization, along with remediation of existing issues

# Conflicts:
#	ui-vue3/src/base/i18n/en.ts
#	ui-vue3/src/base/i18n/zh.ts
#	ui-vue3/src/main.ts
  • Loading branch information
Helltab committed Jan 22, 2024
2 parents 0f832e0 + 7c43062 commit 62bff9c
Show file tree
Hide file tree
Showing 59 changed files with 2,096 additions and 507 deletions.
27 changes: 27 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
## Contributing to Dubbo
Dubbo is released under the non-restrictive Apache 2.0 licenses and follows a very standard Github development process, using Github tracker for issues and merging pull requests into master. Contributions of all form to this repository is acceptable, as long as it follows the prescribed community guidelines enumerated below.

### Sign the Contributor License Agreement
Before we accept a non-trivial patch or pull request (PRs), we will need you to sign the Contributor License Agreement. Signing the contributors' agreement does not grant anyone commits rights to the main repository, but it does mean that we can accept your contributions, and you will get an author credit if we do. Active contributors may get invited to join the core team that will grant them privileges to merge existing PRs.

### Contact

#### Mailing list

The mailing list is the recommended way of pursuing a discussion on almost anything related to Dubbo. Please refer to this [guide](https://github.com/apache/dubbo/wiki/Mailing-list-subscription-guide) for detailed documentation on how to subscribe.

- [[email protected]](mailto:[email protected]): the developer mailing list where you can ask questions about an issue you may have encountered while working with Dubbo.
- [[email protected]](mailto:[email protected]): the commit updates will get broadcasted on this mailing list. You can subscribe to it, should you be interested in following Dubbo's development.
- [[email protected]](mailto:[email protected]): all the Github [issue](https://github.com/apache/dubbo/issues) updates and [pull request](https://github.com/apache/dubbo/pulls) updates will be sent to this mailing list.

### Reporting issue

Please crete an issue here https://github.com/apache/dubbo-kubernetes


### Contribution flow

A rough outline of an ideal contributors' workflow is as follows:


Thanks for contributing!
5 changes: 5 additions & 0 deletions DEVELOPER.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Developer documentation

The source code guidance of this project.

With this documentation, developers can learn which part of the project they need to change in order to fix a bug or introduce a new feature. How can they verify their codes work as expected before submit a pull request, by running the project locally or running the test suite.
194 changes: 121 additions & 73 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,76 +10,124 @@ The Dubbo Kubernetes Integration
[![codecov](https://codecov.io/gh/apache/dubbo-kubernetes/branch/master/graph/badge.svg)](https://codecov.io/gh/apache/dubbo-kubernetes)
![license](https://img.shields.io/badge/license-Apache--2.0-green.svg)

This repository contains libraries and tools for creating and deploying Dubbo applications in any Kubernetes environment, i.e. on Kubernetes, Aliyun ACK, etc.

## Prerequisites:
* Ensure you have Go installed, version 1.20 or higher.
* Make sure you install kubectl.
* Ensure you have Dubboctl installed.

## Quick Start
### Create a Dubbo application
Use `dubboctl create` to create a project template.

```shell
dubboctl create -l java
```

This should generate a simple project with a demo service properly configured and is ready to run.

> For java developers, it's recommended to use [start.dubbo.apache.org]() or [IntelliJ IDEA plugin]() to generate more complicated templates.
### Deploy application to Kubernetes
Before deploying the application, let's install Nacos, Zookeeper, Prometheus and other components necessary for running a Dubbo application or microservice cluster.

```shell
dubboctl install --profile=demo # This will install Nacos, Prometheus, Grafana, Admin, etc.
```

Next, build your application as docker image and deploy it into kubernetes cluster with `dubboctl deploy`, it will do the following two steps:

1. Build your application from source code into docker image and push the image to remote repository.
2. Generate all the kubernetes configurations (e.g., deployments, services, load balancers) needed to run your application on vanilla Kubernetes.

```shell
dubboctl deploy --out=deployment.yml
```

Finally, apply manifests into kubernetes cluster.

```shell
kubectl apply -f deployment.yml
```

### Monitor and manage your application
We already have the application up and running, now it's time to continuously monitor the status or manage the traffics of our applications.

#### Admin
Run the following command and open `http://localhost:38080/admin/` with your favourite browser.

```shell
dubboctl dashboard admin
```

![Admin Console]()


![Admin Grafana]()

#### Tracing
```shell
dubboctl dashboard zipkin
```

#### Traffic Management
Please refer to our official website to learn the traffic policies in Dubbo with some well-designed tasks.
* Timeout
* Accesslog
* Region-aware traffic split
* Weight-based traffic split
* Circuit breaking
* Canary release




**The universal Control Plane and Console for managing microservices on any environment - VM and Kubernetes.**

![architecture](./docs/images/homepage/arch1.png)

## Quick Start (under development)
> NOTICE: As the project has not been officially released yet, the following commands may not run properly. The best way for now is to refer to the [Developer's Guide](./DEVELOPER.md) to learn how to download the source code and build it locally!

1. Download `dubbo-control-plane` binary package.
```shell
curl -L https://raw.githubusercontent.com/apache/dubbo-kubernetes/master/release/downloadDubbo.sh | sh -

cd dubbo-$version
export PATH=$PWD/bin:$PATH
```

2. Install `control-plane` on Kubernetes
```shell
dubboctl install --profile=demo
```

3. Check installation
```shell
kubectl get services -n dubbo-system
```

4. Next, deploy Dubbo applications to Kubernetes as shown below:

```yaml
apiVersion: v1
kind: Service
metadata:
name: demo-service
namespace: dubbo-demo
spec:
selector:
app: dubbo-demo
type: ClusterIP
ports:
- name: port1
protocol: http
port: 80
targetPort: 8080
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: example-app
namespace: dubbo-demo
spec:
...
template:
metadata:
...
labels:
app: dubbo-demo
dubbo.apache.org/service: dubbo-demo
spec:
containers:
...
```

> If you want to create your own Dubbo application from scratch and deploy it, please use [dubboctl]() we provided below.


5. Open the following page to check deployment status on control plane UI:
```shell
kubectl port-forward svc/dubbo-control-plane \
-n dubbo-system 5681:5681
```

visit, 127.0.0.1:5681/admin

![ui-demo](./docs/images/homepage/ui-demo.png)

## Architecture

![architecture](./docs/images/homepage/arch2.png)

The microservcice architecture built with Dubbo Control Plane consists of two main components:

- The **`Dubbo Control Plane`** configures the data plane - applications developed with Dubbo SDK, for handling service traffic. Users create [policies]() that the dubbo control plane processes to generate configurations for the data plane.
- The data plane - the **`Dubbo SDK`**, connets directly to control plane and receives configurations that can work as the sources for service discovery, traffic routing, load balancing, etc.

Dubbo Control Plane supports two deployment modes: **`kubernetes`** and **`universal`**.

- **`kubernetes`** mode is like the classic Service Mesh architecture, with all microservices concepts bonded to kubernetes resources. Unlike classic service mesh solutions like istio, Dubbo favors a proxyless data plane deployment - with no envoy sidecar.
- **`universal`** is the traditional microservice architecture that all Dubbo users are already familiar with. Unlike the kubernetes mode, it usually needs a dedicated registry like Nacos or Zookeeper for service discovery, etc.

### Kubernetes
In kubernetes mode, the control plane will interact directly with the Kubernetes API-SERVER, watching the kubernetes resources and transform them as xDS resources for service discovery and traffic management configurations.

![kubernetes-mode](./docs/images/homepage/kubernetes-mode.png)

We all know the `service` definitions of Kubernetes and Dubo are different, `Kubernetes Service` is more like an application concept run on a selected group of pods while `Dubbo Service` can mean a specific RPC service inside the application process. So how does dubbo control plane manages to bridge the `interface-application` gap, check [here]() for more details.

### Universal
In Universal mode, Dubbo still uses Nacos or Zookeeper as registries for service discovery, control plane then interact with registry directly to work as the console UI, as the entry point for viewing and managing the cluster.

![universal-mode](./docs/images/homepage/universal-mode.png)

### Multiple clusters
Dubbo Control Plane supports running your services in multiple zones. It is even possible to run with a mix of Kubernetes and Universal zones. Your microservice environment can include multiple isolated services, and workloads running in different regions, on different clouds, or in different datacenters. A zone can be a Kubernetes cluster, a VPC, or any other deployment you need to include in the same distributed microservice environment. The only condition is that all the data planes running within the zone must be able to connect to the other data planes in this same zone.

Dubbo Control Plane supports a **`global`** deployment mode that can connect different **`zone`** region clusters. The picture below shows how it works.

![multiple-cluster](./docs/images/homepage/multiple-cluster.png)

## Roadmap

- Security
- Metrics
- Cross-cluster communication
- Console

## Refereces

- Dubboctl
- Console UI Design
- Dubbo java xDS implementation
- Dubbo go xDS implementation
18 changes: 11 additions & 7 deletions deploy/charts/admin/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,19 @@
# See the License for the specific language governing permissions and
# limitations under the License.

annotations:
licenses: Apache-2.0
name: admin
home: https://github.com/apache/dubbo-kubernetes
description: Admin is an application within the service governance control plane
responsible for functions such as service governance and visual representation of microservice clusters.
apiVersion: v2
name: Admin-Stack
description: ""
home: https://cn.dubbo.apache.org
kubeVersion: '>=1.28.0-0'
appVersion: 0.0.1
maintainers:
- name: dubbo
- name: Dubbo
email: [email protected]
kubeVersion: '>=1.28.0-0'
sources:
- https://github.com/apache/dubbo-kubernetes
type: application
version: 0.1.0
- https://dubbo.apache.org
version: 3.2.9
Loading

0 comments on commit 62bff9c

Please sign in to comment.