This is an automated email from the ASF dual-hosted git repository.
yiconghuang pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/texera.git
The following commit(s) were added to refs/heads/main by this push:
new 3a4b5615ae chore: relocate root project build out from core (#3852)
3a4b5615ae is described below
commit 3a4b5615aea09b3c71cd6a008a891bfb35346542
Author: Yicong Huang <[email protected]>
AuthorDate: Sat Oct 11 13:47:26 2025 -0700
chore: relocate root project build out from core (#3852)
According to the reorganization plan #3846, we want to move components
(such as services) out from `core/` to be in root. This PR is the firs
step to do so by declaring the sbt project in root. To reduce the name
`Core`, this PR also renames the root project to `Texera`. This can also
better align with our future release name.
resolves #3854
---
.github/workflows/github-action-build.yml | 6 ++---
core/.scalafmt.conf => .scalafmt.conf | 0
core/build.sbt => build.sbt | 26 +++++++++++-----------
core/amber/build.sbt | 2 +-
core/dao/src/main/resources/jooq-conf.xml | 2 +-
.../scala/org/apache/texera/dao/MockTexeraDB.scala | 2 +-
.../resource/WorkflowCompilationResourceSpec.scala | 3 ++-
.../apache/amber/storage/FileResolverSpec.scala | 2 +-
{core/project => project}/build.properties | 0
{core/project => project}/plugins.sbt | 0
10 files changed, 22 insertions(+), 21 deletions(-)
diff --git a/.github/workflows/github-action-build.yml
b/.github/workflows/github-action-build.yml
index d5e71c1916..d838b94d28 100644
--- a/.github/workflows/github-action-build.yml
+++ b/.github/workflows/github-action-build.yml
@@ -107,7 +107,7 @@ jobs:
with:
extraSbtFiles: '["core/*.sbt", "core/project/**.{scala,sbt}",
"core/project/build.properties" ]'
- name: Lint with scalafmt
- run: cd core && sbt scalafmtCheckAll
+ run: sbt scalafmtCheckAll
- name: Create Databases
run: |
psql -h localhost -U postgres -f core/scripts/sql/texera_ddl.sql
@@ -120,9 +120,9 @@ jobs:
env:
PGPASSWORD: postgres
- name: Compile with sbt
- run: cd core && sbt clean package
+ run: sbt clean package
- name: Run backend tests
- run: cd core && sbt test
+ run: sbt test
python_udf:
strategy:
diff --git a/core/.scalafmt.conf b/.scalafmt.conf
similarity index 100%
rename from core/.scalafmt.conf
rename to .scalafmt.conf
diff --git a/core/build.sbt b/build.sbt
similarity index 81%
rename from core/build.sbt
rename to build.sbt
index 25b5a2d4d1..4ec20d4d0a 100644
--- a/core/build.sbt
+++ b/build.sbt
@@ -15,11 +15,11 @@
// specific language governing permissions and limitations
// under the License.
-lazy val DAO = project in file("dao")
-lazy val Config = project in file("config")
-lazy val Auth = (project in file("auth"))
+lazy val DAO = project in file("core/dao")
+lazy val Config = project in file("core/config")
+lazy val Auth = (project in file("core/auth"))
.dependsOn(DAO, Config)
-lazy val ConfigService = (project in file("config-service"))
+lazy val ConfigService = (project in file("core/config-service"))
.dependsOn(Auth, Config)
.settings(
dependencyOverrides ++= Seq(
@@ -27,7 +27,7 @@ lazy val ConfigService = (project in file("config-service"))
"com.fasterxml.jackson.module" %% "jackson-module-scala" % "2.17.0"
)
)
-lazy val AccessControlService = (project in file("access-control-service"))
+lazy val AccessControlService = (project in
file("core/access-control-service"))
.dependsOn(Auth, Config, DAO)
.settings(
dependencyOverrides ++= Seq(
@@ -37,11 +37,11 @@ lazy val AccessControlService = (project in
file("access-control-service"))
)
.configs(Test)
.dependsOn(DAO % "test->test", Auth % "test->test")
-lazy val WorkflowCore = (project in file("workflow-core"))
+lazy val WorkflowCore = (project in file("core/workflow-core"))
.dependsOn(DAO, Config)
.configs(Test)
.dependsOn(DAO % "test->test") // test scope dependency
-lazy val ComputingUnitManagingService = (project in
file("computing-unit-managing-service"))
+lazy val ComputingUnitManagingService = (project in
file("core/computing-unit-managing-service"))
.dependsOn(WorkflowCore, Auth, Config)
.settings(
dependencyOverrides ++= Seq(
@@ -49,7 +49,7 @@ lazy val ComputingUnitManagingService = (project in
file("computing-unit-managin
"com.fasterxml.jackson.module" %% "jackson-module-scala" % "2.17.0"
)
)
-lazy val FileService = (project in file("file-service"))
+lazy val FileService = (project in file("core/file-service"))
.dependsOn(WorkflowCore, Auth, Config)
.configs(Test)
.dependsOn(DAO % "test->test") // test scope dependency
@@ -62,8 +62,8 @@ lazy val FileService = (project in file("file-service"))
)
)
-lazy val WorkflowOperator = (project in
file("workflow-operator")).dependsOn(WorkflowCore)
-lazy val WorkflowCompilingService = (project in
file("workflow-compiling-service"))
+lazy val WorkflowOperator = (project in
file("core/workflow-operator")).dependsOn(WorkflowCore)
+lazy val WorkflowCompilingService = (project in
file("core/workflow-compiling-service"))
.dependsOn(WorkflowOperator, Config)
.settings(
dependencyOverrides ++= Seq(
@@ -74,7 +74,7 @@ lazy val WorkflowCompilingService = (project in
file("workflow-compiling-service
)
)
-lazy val WorkflowExecutionService = (project in file("amber"))
+lazy val WorkflowExecutionService = (project in file("core/amber"))
.dependsOn(WorkflowOperator, Auth, Config)
.settings(
dependencyOverrides ++= Seq(
@@ -94,7 +94,7 @@ lazy val WorkflowExecutionService = (project in file("amber"))
.dependsOn(DAO % "test->test", Auth % "test->test") // test scope dependency
// root project definition
-lazy val CoreProject = (project in file("."))
+lazy val TexeraProject = (project in file("."))
.aggregate(
DAO,
Config,
@@ -109,7 +109,7 @@ lazy val CoreProject = (project in file("."))
WorkflowExecutionService
)
.settings(
- name := "core",
+ name := "texera",
version := "1.0.0",
organization := "org.apache",
scalaVersion := "2.13.12",
diff --git a/core/amber/build.sbt b/core/amber/build.sbt
index 4b61049623..91783b243e 100644
--- a/core/amber/build.sbt
+++ b/core/amber/build.sbt
@@ -15,7 +15,7 @@
// specific language governing permissions and limitations
// under the License.
-name := "texera"
+name := "amber"
organization := "org.apache"
version := "1.0.0"
diff --git a/core/dao/src/main/resources/jooq-conf.xml
b/core/dao/src/main/resources/jooq-conf.xml
index a81829caae..8d5d516dc1 100644
--- a/core/dao/src/main/resources/jooq-conf.xml
+++ b/core/dao/src/main/resources/jooq-conf.xml
@@ -64,7 +64,7 @@
<packageName>org.apache.texera.dao.jooq.generated</packageName>
<!-- The destination directory of your generated classes. Using
Maven directory layout here -->
- <directory>dao/src/main/scala</directory>
+ <directory>core/dao/src/main/scala</directory>
</target>
</generator>
</configuration>
diff --git a/core/dao/src/test/scala/org/apache/texera/dao/MockTexeraDB.scala
b/core/dao/src/test/scala/org/apache/texera/dao/MockTexeraDB.scala
index 0f94ccf92d..8f13eebbe2 100644
--- a/core/dao/src/test/scala/org/apache/texera/dao/MockTexeraDB.scala
+++ b/core/dao/src/test/scala/org/apache/texera/dao/MockTexeraDB.scala
@@ -84,7 +84,7 @@ trait MockTexeraDB {
dbInstance = Some(embedded)
val ddlPath = {
- Paths.get("./scripts/sql/texera_ddl.sql").toRealPath()
+ Paths.get("core/scripts/sql/texera_ddl.sql").toRealPath()
}
val source = Source.fromFile(ddlPath.toString)
val content =
diff --git
a/core/workflow-compiling-service/src/test/scala/org/apache/texera/service/resource/WorkflowCompilationResourceSpec.scala
b/core/workflow-compiling-service/src/test/scala/org/apache/texera/service/resource/WorkflowCompilationResourceSpec.scala
index 6a7797bc55..4a169900cd 100644
---
a/core/workflow-compiling-service/src/test/scala/org/apache/texera/service/resource/WorkflowCompilationResourceSpec.scala
+++
b/core/workflow-compiling-service/src/test/scala/org/apache/texera/service/resource/WorkflowCompilationResourceSpec.scala
@@ -129,7 +129,8 @@ class WorkflowCompilationResourceSpec extends AnyFlatSpec
with BeforeAndAfterAll
it should "compile workflow successfully with multiple filter and limit
operations" in {
// construct the LogicalPlan: CSVScan --> Projection --> Limit --> Filter
(TotalProfit > 10000) --> Filter (Region != "JPN") --> Limit
- val localCsvFilePath =
"workflow-compiling-service/src/test/resources/country_sales_small.csv"
+ val localCsvFilePath =
+
"core/workflow-compiling-service/src/test/resources/country_sales_small.csv"
val csvSourceOp = getCsvScanOpDesc(localCsvFilePath, header = true)
val projectionOpDesc = getProjectionOpDesc(List("Region", "Total Profit"))
val limitOpDesc1 = getLimitOpDesc(10)
diff --git
a/core/workflow-core/src/test/scala/org/apache/amber/storage/FileResolverSpec.scala
b/core/workflow-core/src/test/scala/org/apache/amber/storage/FileResolverSpec.scala
index 7f6d9b5598..bb7de496f1 100644
---
a/core/workflow-core/src/test/scala/org/apache/amber/storage/FileResolverSpec.scala
+++
b/core/workflow-core/src/test/scala/org/apache/amber/storage/FileResolverSpec.scala
@@ -77,7 +77,7 @@ class FileResolverSpec
datasetVersion
}
- private val localCsvFilePath =
"workflow-core/src/test/resources/country_sales_small.csv"
+ private val localCsvFilePath =
"core/workflow-core/src/test/resources/country_sales_small.csv"
private val datasetACsvFilePath =
"/[email protected]/test_dataset/v2/directory/a.csv"
diff --git a/core/project/build.properties b/project/build.properties
similarity index 100%
rename from core/project/build.properties
rename to project/build.properties
diff --git a/core/project/plugins.sbt b/project/plugins.sbt
similarity index 100%
rename from core/project/plugins.sbt
rename to project/plugins.sbt