Skip to content

Commit

Permalink
[Feature][scaleph-ui-react] update flink job detail web (#708)
Browse files Browse the repository at this point in the history
* feature: update kubernetes resource watch

* feature: update kubernetes resource watch

* feature: update security resource web

* feature: add license header

* feature: add license header

* feature: add license header

* feature: add license header

* feature: update kubernetes resource event source

* feature: add paimon dockerfile

* feature: update kubernetes resource event source

* feature: update oam and add mysql schema

* feature: update oam and add mysql schema

* feature: add oam mapper

* feature: add oam model

* feature: add paimon dockerfile

* feature: add oam controller

* feature: add oam controller

* feature: add oam controller

* feature: add oam definition web

* feature: remove snapshot repository

* feature: remove snapshot repository

* fix: flink job error

* feature: prepare release 2.0.3

---------

Co-authored-by: wangqi <[email protected]>
  • Loading branch information
kalencaya and wangqi authored Apr 29, 2024
1 parent d052a24 commit b942b53
Show file tree
Hide file tree
Showing 131 changed files with 4,004 additions and 494 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/ci-docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,8 @@ jobs:
uses: docker/build-push-action@v5
with:
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: false
context: .
platforms: linux/amd64,linux/arm64
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/release-manual-docker-flink-cdc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ jobs:
- name: Build image
uses: docker/build-push-action@v5
with:
no-cache: true
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: true
context: .
build-args: |
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release-manual-docker-flink.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ jobs:
uses: docker/build-push-action@v5
with:
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: true
context: .
build-args: FLINK_VERSION=${{ env.FLINK_VERSION }}
Expand Down
87 changes: 87 additions & 0 deletions .github/workflows/release-manual-docker-paimon.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

name: Release-Docker-Paimon

on:
workflow_dispatch:
inputs:
flinkVersion:
description: 'flink version'
required: true
default: '1.18'
type: choice
options:
- 1.18
flinkCDCVersion:
description: 'flink-cdc version'
required: true
default: '3.0.1'
type: choice
options:
- 3.0.1
paimonVersion:
description: 'paimon version'
required: true
default: '0.7.0-incubating'
type: choice
options:
- 0.7.0-incubating
env:
HUB: ghcr.io/flowerfine/scaleph-paimon
FLINK_VERSION: ${{ inputs.flinkVersion }}
FLINK_CDC_VERSION: ${{ inputs.flinkCDCVersion }}
PAIMON_VERSION: ${{ inputs.paimonVersion }}

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
timeout-minutes: 360
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Log in to the Container registry
uses: docker/login-action@3
with:
registry: ${{ env.HUB }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
with:
platforms: amd64,arm64
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build image
uses: docker/build-push-action@v5
with:
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: true
context: .
build-args: |
FLINK_VERSION=${{ env.FLINK_VERSION }}
FLINK_CDC_VERSION=${{ env.FLINK_CDC_VERSION }}
PAIMON_VERSION=${{ env.PAIMON_VERSION }}
platforms: linux/amd64,linux/arm64
file: tools/docker/build/scaleph-paimon/Dockerfile
tags: ${{ env.HUB }}:${{ env.PAIMON_VERSION }}-flink-${{ env.FLINK_VERSION }}
4 changes: 3 additions & 1 deletion .github/workflows/release-manual-docker-seatunnel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ jobs:
- name: Build image
uses: docker/build-push-action@v5
with:
no-cache: true
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: true
context: .
build-args: |
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release-manual-docker-sql-template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ jobs:
uses: docker/build-push-action@v5
with:
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: true
context: .
build-args: FLINK_VERSION=${{ env.FLINK_VERSION }}
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release-master-docker-scaleph.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ jobs:
uses: docker/build-push-action@v5
with:
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: true
context: .
platforms: linux/amd64,linux/arm64
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release-tag-docker-scaleph.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ jobs:
uses: docker/build-push-action@v5
with:
no-cache: false
cache-from: type=gha
cache-to: type=gha
push: true
context: .
platforms: linux/amd64,linux/arm64
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Secondly, take followed steps.
git clone https://github.com/flowerfine/scaleph.git

cd scaleph
git checkout 2.0.1
git checkout 2.0.3

cd scaleph/tools/docker/deploy/scaleph
docker-compose up
Expand Down
28 changes: 16 additions & 12 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,6 @@
</repository>
</distributionManagement>

<repositories>
<repository>
<id>sonatype-nexus</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots/</url>
</repository>
</repositories>

<modules>
<module>scaleph-ui-react</module>
<module>scaleph-ui-react2</module>
Expand Down Expand Up @@ -137,7 +129,7 @@
<velocity.engine.version>2.2</velocity.engine.version>
<knife4j.version>4.1.0</knife4j.version>
<auto-service.version>1.0.1</auto-service.version>
<hutool.version>5.8.22</hutool.version>
<hutool.version>5.8.27</hutool.version>
<commons.lang3.version>3.12.0</commons.lang3.version>
<commons.beanutils.version>1.9.4</commons.beanutils.version>
<commons.text.version>1.9</commons.text.version>
Expand All @@ -157,8 +149,8 @@
<okhttp.version>4.10.0</okhttp.version>
<guava.version>32.1.3-jre</guava.version>
<minio.version>8.3.8</minio.version>
<milky.version>1.0.13-SNAPSHOT</milky.version>
<sakura.version>1.0.2-SNAPSHOT</sakura.version>
<milky.version>1.0.13</milky.version>
<sakura.version>1.0.2</sakura.version>
<hadoop.version>3.3.4</hadoop.version>
<hive.version>3.1.3</hive.version>
<akka.version>2.6.21</akka.version>
Expand All @@ -177,6 +169,7 @@
<cola.version>4.3.2</cola.version>
<fury.version>0.4.1</fury.version>
<jgrapht.version>1.5.2</jgrapht.version>
<gravitino.version>0.5.0</gravitino.version>
</properties>

<dependencyManagement>
Expand Down Expand Up @@ -291,6 +284,11 @@
<version>${project.version}</version>
</dependency>

<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>scaleph-application-oam</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>scaleph-application-flink</artifactId>
Expand Down Expand Up @@ -610,7 +608,7 @@

<dependency>
<groupId>cn.sliew</groupId>
<artifactId>sakura-catalog</artifactId>
<artifactId>sakura-catalog-flink</artifactId>
<version>${sakura.version}</version>
</dependency>

Expand Down Expand Up @@ -782,6 +780,12 @@
<artifactId>jgrapht-core</artifactId>
<version>${jgrapht.version}</version>
</dependency>

<dependency>
<groupId>com.datastrato.gravitino</groupId>
<artifactId>client-java-runtime</artifactId>
<version>${gravitino.version}</version>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@

package cn.sliew.scaleph.api.config;

import cn.sliew.scaleph.common.util.NetUtils;
import org.redisson.config.Config;
import org.redisson.config.SingleServerConfig;
import org.redisson.spring.starter.RedissonAutoConfiguration;
import org.redisson.spring.starter.RedissonAutoConfigurationCustomizer;
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
Expand All @@ -30,6 +32,7 @@ public class RedissionConfig implements RedissonAutoConfigurationCustomizer {

@Override
public void customize(Config config) {

SingleServerConfig singleServerConfig = config.useSingleServer();
singleServerConfig.setAddress(NetUtils.replaceLocalhost(singleServerConfig.getAddress()));
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package cn.sliew.scaleph.api.controller.oam;

import cn.sliew.scaleph.api.annotation.Logging;
import cn.sliew.scaleph.application.oam.model.definition.ComponentDefinition;
import cn.sliew.scaleph.application.oam.model.definition.PolicyDefinition;
import cn.sliew.scaleph.application.oam.model.definition.TraitDefinition;
import cn.sliew.scaleph.application.oam.service.OamComponentDefinitionService;
import cn.sliew.scaleph.application.oam.service.OamPolicyDefinitionService;
import cn.sliew.scaleph.application.oam.service.OamTraitDefinitionService;
import cn.sliew.scaleph.application.oam.service.OamWorkloadDefinitionService;
import cn.sliew.scaleph.system.model.PaginationParam;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.validation.Valid;

@Tag(name = "OAM管理-Definition管理")
@RestController
@RequestMapping(path = "/api/oam/definition")
public class OamDefinitionController {

@Autowired
private OamComponentDefinitionService oamComponentDefinitionService;
@Autowired
private OamPolicyDefinitionService oamPolicyDefinitionService;
@Autowired
private OamTraitDefinitionService oamTraitDefinitionService;
@Autowired
private OamWorkloadDefinitionService oamWorkloadDefinitionService;

@Logging
@GetMapping("components")
@Operation(summary = "查询 ComponentDefinition 列表", description = "查询 ComponentDefinition 列表")
public ResponseEntity<Page<ComponentDefinition>> listComponents(@Valid PaginationParam param) {
Page<ComponentDefinition> result = oamComponentDefinitionService.listByPage(param);
return new ResponseEntity<>(result, HttpStatus.OK);
}

@Logging
@GetMapping("policies")
@Operation(summary = "查询 PolicyDefinition 列表", description = "查询 PolicyDefinition 列表")
public ResponseEntity<Page<PolicyDefinition>> listPolicies(@Valid PaginationParam param) {
Page<PolicyDefinition> result = oamPolicyDefinitionService.listByPage(param);
return new ResponseEntity<>(result, HttpStatus.OK);
}


@Logging
@GetMapping("traits")
@Operation(summary = "查询 TraitDefinition 列表", description = "查询 TraitDefinition 列表")
public ResponseEntity<Page<TraitDefinition>> listTraits(@Valid PaginationParam param) {
Page<TraitDefinition> result = oamTraitDefinitionService.listByPage(param);
return new ResponseEntity<>(result, HttpStatus.OK);
}
}
6 changes: 6 additions & 0 deletions scaleph-api/src/main/resources/application-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@ spring:
app:
host: localhost:4200

gravitino:
# type: local
url: ${GRAVITINO_URL:http://127.0.0.1:8090}
metalake: ${spring.application.name}
user: ${spring.application.name}

file-system:
# type: local
type: s3
Expand Down
1 change: 1 addition & 0 deletions scaleph-application/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
<packaging>pom</packaging>

<modules>
<module>scaleph-application-oam</module>
<module>scaleph-application-flink</module>
<module>scaleph-application-doris</module>
</modules>
Expand Down
4 changes: 4 additions & 0 deletions scaleph-application/scaleph-application-doris/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@
<artifactId>scaleph-application-doris</artifactId>

<dependencies>
<dependency>
<groupId>${project.parent.groupId}</groupId>
<artifactId>scaleph-application-oam</artifactId>
</dependency>
<dependency>
<groupId>${project.parent.groupId}</groupId>
<artifactId>scaleph-workspace-project</artifactId>
Expand Down
4 changes: 4 additions & 0 deletions scaleph-application/scaleph-application-flink/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@
<artifactId>scaleph-application-flink</artifactId>

<dependencies>
<dependency>
<groupId>${project.parent.groupId}</groupId>
<artifactId>scaleph-application-oam</artifactId>
</dependency>
<dependency>
<groupId>cn.sliew</groupId>
<artifactId>scaleph-engine-sql-gateway</artifactId>
Expand Down
Loading

0 comments on commit b942b53

Please sign in to comment.