Skip to content
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

[VL] prefer to use static packaging #4942

Open
zhouyuan opened this issue Mar 13, 2024 · 9 comments
Open

[VL] prefer to use static packaging #4942

zhouyuan opened this issue Mar 13, 2024 · 9 comments
Labels
enhancement New feature or request

Comments

@zhouyuan
Copy link
Contributor

zhouyuan commented Mar 13, 2024

Description

The dynamic packaging will make a jar with all necessary dependencies for shared libs. On gluten start it will try to extract the libs and then load into JVM.
This method is introduced in early stage of Gluten. The production env is quite different: Cent7, Cent8, Ubuntu 20, Debian, ArchLinux and some customized Linux releases. For different OS the dependencies are different, especially on the library path and the library versions. The code is quite difficult to maintain as Velox is bumping the dependencies.

For better packaging releasing/maintaining, gluten may should pick the static packaging(vcpkg based) so all dependencies are all statically linked and can work on all OS.

Edit:
We need to keep the dynamic packaging method as it's already used in some production env.

CC: @weiting-chen

Thanks,
-yuan

@zhouyuan zhouyuan added the enhancement New feature or request label Mar 13, 2024
@FelixYBW
Copy link
Contributor

We may mention this in dev maillist.

static build makes the deployment much easier. The only issue may be the jar size but now even with debug info, it's just ~88MB.

For developer with current build script, all static library will only be built once. Or build again after vcpkg script changed. velox will be built when commit id changed. So not an issue to development either. It may increase the link time somehow.

See if anyone have concerns about this.

@boneanxs
Copy link
Contributor

We may mention this in dev maillist.

Hey @zhouyuan @FelixYBW Since we're in Apache incubator community now, if we decide to use dev maillist, better update

## 4.1 Community
to reflect email address whereas others can join it.

@zhouyuan
Copy link
Contributor Author

We may mention this in dev maillist.

Hey @zhouyuan @FelixYBW Since we're in Apache incubator community now, if we decide to use dev maillist, better update

## 4.1 Community

to reflect email address whereas others can join it.

Hi Rex, yes, will add the maillist to the doc, thanks!

Thanks,
-yuan

@PHILO-HE
Copy link
Contributor

FYI.
Just tried using static link on centos-8, then running test on centos-7. An issue was reported at runtime:

java.lang.UnsatisfiedLinkError: 
version `GLIBC_2.27' not found (required by /tmp/gluten-de464be8-5c4e-45eb-8fda-8749954938c4/jni/6730a5e2-3e06-4112-b509-6941ceb4126f/gluten-6403925142698728788/libarrow.so.1400.1.0)

@zhouyuan
Copy link
Contributor Author

#5013

We may mention this in dev maillist.

Hey @zhouyuan @FelixYBW Since we're in Apache incubator community now, if we decide to use dev maillist, better update

## 4.1 Community

to reflect email address whereas others can join it.

Hi Rex, yes, will add the maillist to the doc, thanks!

Thanks, -yuan

@ulysses-you
Copy link
Contributor

ulysses-you commented Mar 25, 2024

I have an another issue about libarrow.so. It seems similar with @PHILO-HE
image

@zhouyuan
Copy link
Contributor Author

I have an another issue about libarrow.so. It seems similar with @PHILO-HE image

@ulysses-you the issue should be fixed by using static building libarrow.so/libparquet.so, will try to fix this in
#5033

Thanks,
-yuan

@ulysses-you
Copy link
Contributor

thank you @zhouyuan !

@Yohahaha
Copy link
Contributor

We can provide options to choose building static or dynamic artifacts, and enable static by default. Just not force ban dynamic packaging directly, thank you.

@zhouyuan zhouyuan changed the title [VL] remove dynamic packaging and use static packaing [VL] prefer to use static packaging May 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

6 participants