MCPcopy Index your code
hub / github.com/apache/linkis

github.com/apache/linkis @release-1.8.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release release-1.8.0 ↗ · + Follow
19,577 symbols 49,985 edges 2,937 files 1,991 documented · 10%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Apache Linkis

Linkis builds a computation middleware layer to facilitate connection, governance and orchestration between the upper applications and the underlying data engines.

Apache Linkis | Website

Apache Linkis | DeepWiki

EN docs 简体中文文档

<a target="_blank" href="https://search.maven.org/search?q=g:org.apache.linkis%20AND%20a:linkis">
    <img src="https://img.shields.io/maven-central/v/org.apache.linkis/linkis.svg?label=maven%20central" />
</a>
<a target="_blank" href="https://github.com/apache/linkis/blob/master/LICENSE">
    <img src="https://img.shields.io/badge/License-Apache%202.0-blue.svg?label=license" />
</a>
<a target="_blank" href="https://www.oracle.com/technetwork/java/javase/downloads/index.html">
    <img src="https://img.shields.io/badge/JDK-8-green.svg" />
</a>
<a target="_blank" href="https://github.com/apache/linkis/actions">
    <img src="https://github.com/apache/linkis/actions/workflows//build-backend.yml/badge.svg" />
</a>

github forks github stars github contributors


English | 中文

Introduction

Linkis builds a layer of computation middleware between upper applications and underlying engines. By using standard interfaces such as REST/WS/JDBC provided by Linkis, the upper applications can easily access the underlying engines such as MySQL/Spark/Hive/Presto/Flink, etc., and achieve the intercommunication of user resources like unified variables, scripts, UDFs, functions and resource files at the same time.

As a computation middleware, Linkis provides powerful connectivity, reuse, orchestration, expansion, and governance capabilities. By decoupling the application layer and the engine layer, it simplifies the complex network call relationship, and thus reduces the overall complexity and saves the development and maintenance costs as well.

Since the first release of Linkis in 2019, it has accumulated more than 700 trial companies and 1000+ sandbox trial users, which involving diverse industries, from finance, banking, tele-communication, to manufactory, internet companies and so on. Lots of companies have already used Linkis as a unified entrance for the underlying computation and storage engines of the big data platform.

Apache Linkis | DeepWiki : https://deepwiki.com/apache/linkis

linkis-intro-01

linkis-intro-03

Features

  • Support for diverse underlying computation storage engines : Spark, Hive, Python, Shell, Flink, JDBC, Pipeline, Sqoop, OpenLooKeng, Presto, ElasticSearch, Trino, SeaTunnel, etc.;

  • Support for diverse language : SparkSQL, HiveSQL, Python, Shell, Pyspark, Scala, JSON and Java;

  • Powerful computing governance capability : It can provide task routing, load balancing, multi-tenant, traffic control, resource control and other capabilities based on multi-level labels;

  • Support full stack computation/storage engine : The ability to receive, execute and manage tasks and requests for various compute and storage engines, including offline batch tasks, interactive query tasks, real-time streaming tasks and data lake tasks;

  • Unified context service : supports cross-user, system and computing engine to associate and manage user and system resource files (JAR, ZIP, Properties, etc.), result sets, parameter variables, functions, UDFs, etc., one setting, automatic reference everywhere;

  • Unified materials : provides system and user level material management, can share and flow, share materials across users, across systems;

  • Unified data source management : provides the ability to add, delete, check and change information of Hive, ElasticSearch, Mysql, Kafka, MongoDB and other data sources, version control, connection test, and query metadata information of corresponding data sources;

  • Error code capability : provides error codes and solutions for common errors of tasks, which is convenient for users to locate problems by themselves;

Engine Type

| Engine name | **Support underlying component version

(default dependency version) | Linkis Version Requirements | Included in Release Package By Default | Description** | |:---- |:---- |:---- |:---- |:---- | |Spark|Apache >= 2.0.0,

CDH >= 5.4.0,

(default Apache Spark 3.2.1)|>=1.0.3|Yes|Spark EngineConn, supports SQL , Scala, Pyspark and R code| |Hive|Apache >= 1.0.0,

CDH >= 5.4.0,

(default Apache Hive 3.1.3)|>=1.0.3|Yes |Hive EngineConn, supports HiveQL code| |Python|Python >= 2.6,

(default Python2*)|>=1.0.3|Yes |Python EngineConn, supports python code| |Shell|Bash >= 2.0|>=1.0.3|Yes|Shell EngineConn, supports Bash shell code| |JDBC|MySQL >= 5.0, Hive >=1.2.1,

(default Hive-jdbc 2.3.4)|>=1.0.3|No |JDBC EngineConn, already supports ClickHouse, DB2, DM, Greenplum, kingbase, MySQL, Oracle, PostgreSQL and SQLServer, can be extended quickly Support other DB, such as SQLite| |Flink |Flink >= 1.12.2,

(default Apache Flink 1.12.2)|>=1.0.2|No |Flink EngineConn, supports FlinkSQL code, also supports starting a new Yarn in the form of Flink Jar Application| |Pipeline|-|>=1.0.2|No|Pipeline EngineConn, supports file import and export| |openLooKeng|openLooKeng >= 1.5.0,

(default openLookEng 1.5.0)|>=1.1.1|No|openLooKeng EngineConn, supports querying data virtualization engine with Sql openLooKeng| |Sqoop| Sqoop >= 1.4.6,

(default Apache Sqoop 1.4.6)|>=1.1.2|No|Sqoop EngineConn, support data migration tool Sqoop engine| |Presto|Presto >= 0.180|>=1.2.0|No|Presto EngineConn, supports Presto SQL code| |ElasticSearch|ElasticSearch >=6.0|>=1.2.0|No|ElasticSearch EngineConn, supports SQL and DSL code| |Trino | Trino >=371 | >=1.3.1 | No | Trino EngineConn, supports Trino SQL code | |Seatunnel | Seatunnel >=2.1.2 | >=1.3.1 | No | Seatunnel EngineConn, supportt Seatunnel SQL code |

Download

Please go to the Linkis Releases Page to download a compiled distribution or a source code package of Linkis.

Compile and Deploy

For more detailed guidance see: - [Backend Compile] - [Management Console Build]


Note: If you want use `-Dlinkis.build.web=true` to build  linkis-web image, you need to compile linkis-web first.

## compile backend
### Mac OS/Linux

# 1. When compiling for the first time, execute the following command first
./mvnw -N install

# 2. make the linkis distribution package
# - Option 1: make the linkis distribution package only
./mvnw clean install -Dmaven.javadoc.skip=true -Dmaven.test.skip=true

# - Option 2: make the linkis distribution package and docker image
#   - Option 2.1: image without mysql jdbc jars
./mvnw clean install -Pdocker -Dmaven.javadoc.skip=true -Dmaven.test.skip=true
#   - Option 2.2: image with mysql jdbc jars
./mvnw clean install -Pdocker -Dmaven.javadoc.skip=true -Dmaven.test.skip=true -Dlinkis.build.with.jdbc=true

# - Option 3: linkis distribution package and docker image (included web)
./mvnw clean install -Pdocker -Dmaven.javadoc.skip=true -Dmaven.test.skip=true -Dlinkis.build.web=true

# - Option 4: linkis distribution package and docker image (included web and ldh (hadoop all in one for test))
./mvnw clean install -Pdocker -Dmaven.javadoc.skip=true -Dmaven.test.skip=true -Dlinkis.build.web=true -Dlinkis.build.ldh=true -Dlinkis.build.with.jdbc=true

### Windows
mvnw.cmd -N install
mvnw.cmd clean install -Dmaven.javadoc.skip=true -Dmaven.test.skip=true

## compile web
cd linkis/linkis-web
npm install
npm run build

Bundled with MySQL JDBC Driver

Due to the MySQL licensing restrictions, the MySQL Java Database Connectivity (JDBC) driver is not bundled with the official released linkis image by default. However, at current stage, linkis still relies on this library to work properly. To solve this problem, we provide a script which can help to creating a custom image with mysql jdbc from the official linkis image by yourself, the image created by this tool will be tagged as linkis:with-jdbc by default.

$> LINKIS_IMAGE=linkis:1.3.1 
$> ./linkis-dist/docker/scripts/make-linkis-image-with-mysql-jdbc.sh

Please refer to Quick Deployment to do the deployment.

Examples and Guidance

Documentation & Vedio

Architecture

Linkis services could be divided into three categories: computation governance services, public enhancement services and microservice governance services - The computation governance services, support the 3 major stages of processing a task/request: submission -> preparation -> execution - The public enhancement services, including the material library service, context service, and data source service - The microservice governance services, including Spring Cloud Gateway, Eureka and Open Feign

Below is the Linkis architecture diagram. You can find more detailed architecture docs in Linkis-Doc/Architecture. architecture

Contributing

Contributions are always welcomed, we need more contributors to build Linkis together. either code, or doc, or other supports that could help the community.
For code and documentation contributions, please follow the contribution guide.

Contact Us

  • Any questions or suggestions please kindly submit an issue.
  • By mail dev@linkis.apache.org
  • You can scan the QR code below to join our WeChat group to get more immediate response

Who is Using Linkis

We opened an issue [Who is Using Linkis] for users to feedback and record who is using Linkis.
Since the first release of Linkis in 2019, it has accumulated more than 700 trial companies and 1000+ sandbox trial users, which involving diverse industries, from finance, banking, tele-communication, to manufactory, internet companies and so on.

Extension points exported contracts — how you extend this code

MetadataFsService (Interface)
Metadata Fs service [8 implementers]
linkis-public-enhancements/linkis-pes-common/src/main/java/org/apache/linkis/metadata/query/common/service/MetadataFsService.java
UdfTreeService (Interface)
@description Database operation Service for the [linKIS_PS_UDF_tree] table @createDate 2022-08-13 15:13:27 [10 implementers]
linkis-public-enhancements/linkis-pes-publicservice/src/main/java/org/apache/linkis/basedatamanager/server/service/UdfTreeService.java
Parser (Interface)
1. parse cmd arguments and fill into template 2. generate unique identifier for sub command 3. transform parsed template [19 …
linkis-computation-governance/linkis-client/linkis-cli/src/main/java/org/apache/linkis/cli/application/interactor/command/parser/Parser.java
LinkisErrorCode (Interface)
Linkis error code interface [50 implementers]
linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/errorcode/LinkisErrorCode.java
NonJobOperation (Interface)
(no doc) [17 implementers]
linkis-engineconn-plugins/flink/flink-core/src/main/java/org/apache/linkis/engineconnplugin/flink/client/sql/operation/NonJobOperation.java
EsClientOperate (Interface)
(no doc) [7 implementers]
linkis-engineconn-plugins/elasticsearch/src/main/java/org/apache/linkis/engineplugin/elasticsearch/executor/client/EsClientOperate.java
KeywordParser (Interface)
(no doc) [19 implementers]
linkis-public-enhancements/linkis-cs-server/src/main/java/org/apache/linkis/cs/server/parser/KeywordParser.java
ResourceHelper (Interface)
(no doc) [6 implementers]
linkis-public-enhancements/linkis-bml-server/src/main/java/org/apache/linkis/bml/common/ResourceHelper.java

Core symbols most depended-on inside this repo

error
called by 887
linkis-engineconn-plugins/impala/src/main/java/org/apache/linkis/engineplugin/impala/client/ExecutionListener.java
put
called by 708
linkis-public-enhancements/linkis-cs-server/src/main/java/org/apache/linkis/cs/contextcache/cache/ContextCache.java
getValue
called by 633
linkis-public-enhancements/linkis-pes-common/src/main/java/org/apache/linkis/cs/common/entity/object/CSProperty.java
add
called by 623
linkis-public-enhancements/linkis-jobhistory/src/main/scala/org/apache/linkis/jobhistory/service/JobHistoryQueryService.java
equals
called by 476
linkis-computation-governance/linkis-manager/linkis-label-common/src/main/java/org/apache/linkis/manager/label/entity/CombinedLabel.java
append
called by 414
linkis-computation-governance/linkis-engineconn/linkis-engineconn-executor/accessible-executor/src/main/java/org/apache/linkis/engineconn/acessible/executor/log/SendAppender.java
get
called by 407
linkis-public-enhancements/linkis-cs-server/src/main/java/org/apache/linkis/cs/contextcache/ContextCacheService.java
delete
called by 402
linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/io/Fs.java

Shape

Method 15,141
Class 3,534
Function 398
Interface 393
Enum 111

Languages

Java75%
Ruby21%
TypeScript3%
Python1%

Modules by API surface

linkis-engineconn-plugins/hbase/hbase-shims-2.5.3/src/main/resources/hbase-ruby/hbase/admin.rb113 symbols
linkis-engineconn-plugins/hbase/hbase-shims-2.2.6/src/main/resources/hbase-ruby/hbase/admin.rb103 symbols
linkis-computation-governance/linkis-jdbc-driver/src/main/java/org/apache/linkis/ujes/jdbc/LinkisBaseResultSet.java96 symbols
linkis-engineconn-plugins/spark/src/main/java/org/apache/linkis/engineplugin/spark/client/context/SparkConfig.java91 symbols
linkis-engineconn-plugins/hbase/hbase-shims-1.4.3/src/main/resources/hbase-ruby/hbase/admin.rb85 symbols
linkis-public-enhancements/linkis-jobhistory/src/main/java/org/apache/linkis/jobhistory/entity/QueryTaskVO.java69 symbols
linkis-engineconn-plugins/hbase/hbase-shims-1.2.0/src/main/resources/hbase-ruby/hbase/admin.rb69 symbols
linkis-computation-governance/linkis-manager/linkis-application-manager/src/main/java/org/apache/linkis/manager/am/vo/AMEngineNodeVo.java57 symbols
linkis-computation-governance/linkis-computation-governance-common/src/main/java/org/apache/linkis/governance/common/entity/task/RequestPersistTask.java57 symbols
linkis-public-enhancements/linkis-jobhistory/src/main/java/org/apache/linkis/jobhistory/entity/QueryTask.java49 symbols
linkis-computation-governance/linkis-manager/linkis-manager-persistence/src/main/java/org/apache/linkis/manager/dao/LabelManagerMapper.java49 symbols
linkis-public-enhancements/linkis-udf-service/src/main/java/org/apache/linkis/udf/service/impl/UDFServiceImpl.java47 symbols

Datastores touched

(mysql)Database · 1 repos
hive_metadataDatabase · 1 repos
(mongodb)Database · 1 repos
davinciDatabase · 1 repos
dbNameDatabase · 1 repos
db_nameDatabase · 1 repos
dbnameDatabase · 1 repos
dip_linkisDatabase · 1 repos

For agents

$ claude mcp add linkis \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact