-
Notifications
You must be signed in to change notification settings - Fork 582
Add new package citus for work item 47499297 #13653
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 3.0-dev
Are you sure you want to change the base?
Changes from all commits
bd2d4f1
f844d87
929632b
4021cfb
2481ca3
ccec4dd
acefa79
6535225
4190f45
b6ed514
0d9e531
3c6b7f1
d93e23d
b1ed252
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"Signatures": { | ||
"citus-13.0.3.tar.gz": "0815c5139e1b3fa2ce95e35095761c3de159a64b67a0d0da8e42d9844c52e122" | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
Summary: PostgreSQL-based distributed RDBMS | ||
Name: citus | ||
Conflicts: %{name} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Check if we can put version number (something like < %{Version}) if the package conflicts with itself.. |
||
Version: 13.0.3 | ||
Release: 1%{?dist} | ||
License: AGPLv3 | ||
Vendor: Microsoft Corporation | ||
Distribution: Azure Linux | ||
Source0: https://github.com/citusdata/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz | ||
%if 0%{?with_check} | ||
Patch0: disable_unwanted_tests.patch | ||
%endif | ||
URL: https://github.com/citusdata/%{name} | ||
BuildRequires: postgresql-devel | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Many spec files put make and gcc in BuildRequires, do we need to put here explicitly for some environments to make this spec file work in those environments? |
||
BuildRequires: libcurl-devel | ||
BuildRequires: lz4-devel | ||
BuildRequires: pkgconfig(icu-i18n) | ||
BuildRequires: pkgconfig(icu-uc) | ||
%if 0%{?with_check} | ||
BuildRequires: shadow-utils | ||
%endif | ||
Requires: postgresql | ||
Provides: %{name} | ||
|
||
%description | ||
Citus horizontally scales PostgreSQL across commodity servers | ||
using sharding and replication. Its query engine parallelizes | ||
incoming SQL queries across these servers to enable real-time | ||
responses on large datasets. | ||
|
||
Citus extends the underlying database rather than forking it, | ||
which gives developers and enterprises the power and familiarity | ||
of a traditional relational database. As an extension, Citus | ||
supports new PostgreSQL releases, allowing users to benefit from | ||
new features while maintaining compatibility with existing | ||
PostgreSQL tools. Note that Citus supports many (but not all) SQL | ||
commands. | ||
|
||
%prep | ||
%autosetup -p1 -n %{name}-%{version} | ||
|
||
%build | ||
currentgccver="$(gcc -dumpversion)" | ||
requiredgccver="4.8.2" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should we put it as requiredmingccver for better communication? |
||
if [ "$(printf '%s\n' "$requiredgccver" "$currentgccver" | sort -V | head -n1)" != "$requiredgccver" ]; then | ||
echo ERROR: At least GCC version "$requiredgccver" is needed to build with security flags | ||
exit 1 | ||
fi | ||
%configure PG_CONFIG=%{_bindir}/pg_config --with-extra-version="%{?conf_extra_version}" --with-security-flags CC=$(command -v gcc) | ||
make %{?_smp_mflags} | ||
|
||
%install | ||
%make_install | ||
# Install documentation with a better name: | ||
%{__mkdir} -p %{buildroot}%{_docdir}/postgresql/extension | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is there any difference between this and below mkdir? If not, then we can make them uniform. |
||
%{__cp} README.md %{buildroot}%{_docdir}/postgresql/extension/README-%{name}.md | ||
%{__cp} NOTICE %{buildroot}%{_docdir}/postgresql/extension/NOTICE-%{name} | ||
|
||
%check | ||
%if 0%{?with_check} | ||
mkdir -p /run/postgresql | ||
useradd -s /usr/bin/sh test | ||
usermod -a -G root test | ||
chmod -R g+w %{_includedir}/postgresql | ||
chmod -R g+w %{_libdir}/postgresql | ||
chmod -R g+w %{_datadir}/postgresql | ||
chmod -R g+w /run/postgresql | ||
chown -R test . | ||
su test -s /bin/sh -c 'make check' | ||
%endif | ||
|
||
%files | ||
%defattr(-,root,root,-) | ||
%doc CHANGELOG.md | ||
%license LICENSE | ||
%{_includedir}/* | ||
%{_libdir}/* | ||
%{_datadir}/* | ||
%doc %{_docdir}/postgresql/extension/README-%{name}.md | ||
%doc %{_docdir}/postgresql/extension/NOTICE-%{name} | ||
|
||
%changelog | ||
* Mon Apr 29 2025 Sandeep Karambelkar <skarambelkar@microsoft.com> - 13.0.3-1 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It was Tue |
||
- Original version for Azure Linux | ||
- Based on the spec file of citus packaging | ||
- License verified |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
From 8f06aadb8edd71022565a6f70a05466082abfcb9 Mon Sep 17 00:00:00 2001 | ||
From: Sandeep Karambelkar <skarambelkar@microsoft.com> | ||
Date: Thu, 1 May 2025 12:56:59 +0000 | ||
Subject: [PATCH] Disable unwanted tests | ||
|
||
--- | ||
src/test/regress/Makefile | 2 +- | ||
src/test/regress/isolation_schedule | 2 -- | ||
src/test/regress/pg_regress_multi.pl | 1 - | ||
3 files changed, 1 insertion(+), 4 deletions(-) | ||
|
||
diff --git a/src/test/regress/Makefile b/src/test/regress/Makefile | ||
index 4bdc7a1..6d4ef46 100644 | ||
--- a/src/test/regress/Makefile | ||
+++ b/src/test/regress/Makefile | ||
@@ -45,7 +45,7 @@ vanilla_diffs_file = $(citus_abs_srcdir)/pg_vanilla_outputs/$(MAJORVERSION)/regr | ||
# intermediate, for muscle memory backward compatibility. | ||
check: check-full check-enterprise-full | ||
# check-full triggers all tests that ought to be run routinely | ||
-check-full: check-multi check-multi-mx check-multi-1 check-operations check-follower-cluster check-isolation check-failure check-split check-vanilla check-columnar check-columnar-isolation check-pg-upgrade check-arbitrary-configs check-citus-upgrade check-citus-upgrade-mixed check-citus-upgrade-local check-citus-upgrade-mixed-local check-pytest check-query-generator | ||
+check-full: check-multi check-operations check-isolation check-split | ||
# check-enterprise-full triggers all enterprise specific tests | ||
check-enterprise-full: check-enterprise check-enterprise-isolation check-enterprise-failure check-enterprise-isolation-logicalrep-1 check-enterprise-isolation-logicalrep-2 check-enterprise-isolation-logicalrep-3 | ||
|
||
diff --git a/src/test/regress/isolation_schedule b/src/test/regress/isolation_schedule | ||
index d8cc77c..12ae688 100644 | ||
--- a/src/test/regress/isolation_schedule | ||
+++ b/src/test/regress/isolation_schedule | ||
@@ -82,9 +82,7 @@ test: isolation_citus_schema_distribute_undistribute | ||
|
||
# Rebalancer | ||
test: isolation_blocking_move_single_shard_commands | ||
-test: isolation_blocking_move_multi_shard_commands | ||
test: isolation_blocking_move_single_shard_commands_on_mx | ||
-test: isolation_blocking_move_multi_shard_commands_on_mx | ||
test: isolation_shard_rebalancer | ||
test: isolation_rebalancer_deferred_drop | ||
test: isolation_shard_rebalancer_progress | ||
diff --git a/src/test/regress/pg_regress_multi.pl b/src/test/regress/pg_regress_multi.pl | ||
index 66016f7..54cea92 100755 | ||
--- a/src/test/regress/pg_regress_multi.pl | ||
+++ b/src/test/regress/pg_regress_multi.pl | ||
@@ -115,7 +115,6 @@ GetOptions( | ||
'valgrind-log-file=s' => \$valgrindLogFile, | ||
'pg_ctl-timeout=s' => \$pgCtlTimeout, | ||
'connection-timeout=s' => \$connectionTimeout, | ||
- 'mitmproxy' => \$useMitmproxy, | ||
'conninfo=s' => \$conninfo, | ||
'worker-1-public-hostname=s' => \$publicWorker1Host, | ||
'worker-2-public-hostname=s' => \$publicWorker2Host, | ||
-- | ||
2.45.3 | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason we didn't start with the
.spec
available upstream?https://github.com/citusdata/packaging/blob/all-citus/citus.spec
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We did use the same spec and fixed it for azure linux.