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

Iodine fails to build on alpine 3.21 [gcc (14.2.0-r4)] #156

Open
michal-kazmierczak opened this issue Dec 13, 2024 · 10 comments
Open

Iodine fails to build on alpine 3.21 [gcc (14.2.0-r4)] #156

michal-kazmierczak opened this issue Dec 13, 2024 · 10 comments

Comments

@michal-kazmierczak
Copy link

michal-kazmierczak commented Dec 13, 2024

System Information

  • OS: [alpine 3.21]
  • Ruby: [3.3.6]
  • Version: [0.7.58]

Description

Minimum reproducible example:

Failing scenario (alpine3.21)
❯ cat Dockerfile
FROM ruby:3.3.6-alpine3.21

RUN apk --no-cache add g++ make
RUN gem install iodine

❯ docker build .

[+] Building 7.0s (6/6) FINISHED                                                                                                                                                                                                                                                                                                                       docker:desktop-linux
 => [internal] load build definition from Dockerfile                                                                                                                                                                                                                                                                                                                   0.0s
 => => transferring dockerfile: 121B                                                                                                                                                                                                                                                                                                                                   0.0s
 => [internal] load metadata for docker.io/library/ruby:3.3.6-alpine3.21                                                                                                                                                                                                                                                                                               0.0s
 => [internal] load .dockerignore                                                                                                                                                                                                                                                                                                                                      0.0s
 => => transferring context: 2B                                                                                                                                                                                                                                                                                                                                        0.0s
 => [1/3] FROM docker.io/library/ruby:3.3.6-alpine3.21                                                                                                                                                                                                                                                                                                                 0.0s
 => [2/3] RUN apk --no-cache add g++ make                                                                                                                                                                                                                                                                                                                              5.4s
 => ERROR [3/3] RUN gem install iodine                                                                                                                                                                                                                                                                                                                                 1.5s
------
 > [3/3] RUN gem install iodine:
0.923 Building native extensions. This could take a while...
1.465 ERROR:  Error installing iodine:
1.465   ERROR: Failed to build gem native extension.
1.465
1.465     current directory: /usr/local/bundle/gems/iodine-0.7.58/ext/iodine
1.465 /usr/local/bin/ruby extconf.rb
1.465 detected `epoll`
1.465 checking for -lcrypto... no
1.465 creating Makefile
1.465
1.465 current directory: /usr/local/bundle/gems/iodine-0.7.58/ext/iodine
1.465 make DESTDIR\= sitearchdir\=./.gem.20241213-1-b3yyw1 sitelibdir\=./.gem.20241213-1-b3yyw1 clean
1.465
1.465 current directory: /usr/local/bundle/gems/iodine-0.7.58/ext/iodine
1.465 make DESTDIR\= sitearchdir\=./.gem.20241213-1-b3yyw1 sitelibdir\=./.gem.20241213-1-b3yyw1
1.465 compiling fio.c
1.465 In file included from fio.c:13:
1.465 ./fio.h:346:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465   346 | #if FIO_FORCE_MALLOC
1.465       |     ^~~~~~~~~~~~~~~~
1.465 ./fio.h:349:7: warning: "__clang__" is not defined, evaluates to 0 [-Wundef]
1.465   349 | #elif __clang__ || __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 8)
1.465       |       ^~~~~~~~~
1.465 ./fio.h:531:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465   531 | #if DEBUG
1.465       |     ^~~~~
1.465 ./fio.h:2228:5: warning: "__BIG_ENDIAN__" is not defined, evaluates to 0 [-Wundef]
1.465  2228 | #if __BIG_ENDIAN__
1.465       |     ^~~~~~~~~~~~~~
1.465 ./fio.h:2465:5: warning: "FIO_USE_RISKY_HASH" is not defined, evaluates to 0 [-Wundef]
1.465  2465 | #if FIO_USE_RISKY_HASH
1.465       |     ^~~~~~~~~~~~~~~~~~
1.465 ./fio.h:2848:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  2848 | #if DEBUG
1.465       |     ^~~~~
1.465 ./fio.h:3052:5: warning: "DEBUG_SPINLOCK" is not defined, evaluates to 0 [-Wundef]
1.465  3052 | #if DEBUG_SPINLOCK
1.465       |     ^~~~~~~~~~~~~~
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 ./fio.h:3116:25: warning: "FIO_FORCE_MALLOC_TMP" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |                         ^~~~~~~~~~~~~~~~~~~~
1.465 In file included from fio.c:16:
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 ./fio.h:3116:25: warning: "FIO_FORCE_MALLOC_TMP" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |                         ^~~~~~~~~~~~~~~~~~~~
1.465 In file included from fio.c:20:
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 ./fio.h: In function 'fio_ls_push':
1.465 ./fio.h:3339:49: warning: 'calloc' sizes specified with 'sizeof' in the earlier argument and not in the later argument [-Wcalloc-transposed-args]
1.465  3339 |   fio_ls_s *item = (fio_ls_s *)FIO_MALLOC(sizeof(*item));
1.465       |                                                 ^
1.465 ./fio.h:3117:34: note: in definition of macro 'FIO_MALLOC'
1.465  3117 | #define FIO_MALLOC(size) calloc((size), 1)
1.465       |                                  ^~~~
1.465 ./fio.h:3339:49: note: earlier argument should specify number of elements, later size of each element
1.465  3339 |   fio_ls_s *item = (fio_ls_s *)FIO_MALLOC(sizeof(*item));
1.465       |                                                 ^
1.465 ./fio.h:3117:34: note: in definition of macro 'FIO_MALLOC'
1.465  3117 | #define FIO_MALLOC(size) calloc((size), 1)
1.465       |                                  ^~~~
1.465 fio.c: At top level:
1.465 fio.c:56:5: warning: "HAVE_OPENSSL" is not defined, evaluates to 0 [-Wundef]
1.465    56 | #if HAVE_OPENSSL
1.465       |     ^~~~~~~~~~~~
1.465 fio.c:62:5: warning: "HAVE_OPENSSL" is not defined, evaluates to 0 [-Wundef]
1.465    62 | #if HAVE_OPENSSL
1.465       |     ^~~~~~~~~~~~
1.465 In file included from fio.c:321:
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 fio.c:406:24: warning: "FIO_ENGINE_WSAPOLL" is not defined, evaluates to 0 [-Wundef]
1.465   406 | #if FIO_ENGINE_POLL || FIO_ENGINE_WSAPOLL
1.465       |                        ^~~~~~~~~~~~~~~~~~
1.465 fio.c:413:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465   413 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c:1135:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  1135 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c:1623:6: warning: "FIO_DISABLE_HOT_RESTART" is not defined, evaluates to 0 [-Wundef]
1.465  1623 | #if !FIO_DISABLE_HOT_RESTART
1.465       |      ^~~~~~~~~~~~~~~~~~~~~~~
1.465 fio.c: In function 'sig_int_handler':
1.465 fio.c:1671:6: warning: "FIO_DISABLE_HOT_RESTART" is not defined, evaluates to 0 [-Wundef]
1.465  1671 | #if !FIO_DISABLE_HOT_RESTART
1.465       |      ^~~~~~~~~~~~~~~~~~~~~~~
1.465 fio.c: In function 'fio_signal_handler_setup':
1.465 fio.c:1740:6: warning: "FIO_DISABLE_HOT_RESTART" is not defined, evaluates to 0 [-Wundef]
1.465  1740 | #if !FIO_DISABLE_HOT_RESTART
1.465       |      ^~~~~~~~~~~~~~~~~~~~~~~
1.465 fio.c: In function 'fio_signal_handler_reset':
1.465 fio.c:1771:6: warning: "FIO_DISABLE_HOT_RESTART" is not defined, evaluates to 0 [-Wundef]
1.465  1771 | #if !FIO_DISABLE_HOT_RESTART
1.465       |      ^~~~~~~~~~~~~~~~~~~~~~~
1.465 fio.c: At top level:
1.465 fio.c:2106:5: warning: "FIO_ENGINE_KQUEUE" is not defined, evaluates to 0 [-Wundef]
1.465  2106 | #if FIO_ENGINE_KQUEUE
1.465       |     ^~~~~~~~~~~~~~~~~
1.465 fio.c:2394:5: warning: "FIO_ENGINE_WSAPOLL" is not defined, evaluates to 0 [-Wundef]
1.465  2394 | #if FIO_ENGINE_WSAPOLL
1.465       |     ^~~~~~~~~~~~~~~~~~
1.465 fio.c: In function 'fio_sock_sendfile_from_fd':
1.465 fio.c:3388:7: error: implicit declaration of function 'sendfile64'; did you mean 'sendfile'? [-Wimplicit-function-declaration]
1.465  3388 |       sendfile64(fd, packet->data.fd, (off_t *)&packet->offset, packet->length);
1.465       |       ^~~~~~~~~~
1.465       |       sendfile
1.465 fio.c: In function 'fio_force_close':
1.465 fio.c:3635:24: warning: "FIO_ENGINE_WSAPOLL" is not defined, evaluates to 0 [-Wundef]
1.465  3635 | #if FIO_ENGINE_POLL || FIO_ENGINE_WSAPOLL
1.465       |                        ^~~~~~~~~~~~~~~~~~
1.465 fio.c: In function 'fio_lib_init':
1.465 fio.c:4332:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  4332 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c:4365:24: warning: "FIO_ENGINE_WSAPOLL" is not defined, evaluates to 0 [-Wundef]
1.465  4365 | #if FIO_ENGINE_POLL || FIO_ENGINE_WSAPOLL
1.465       |                        ^~~~~~~~~~~~~~~~~~
1.465 fio.c:4388:24: warning: "FIO_ENGINE_WSAPOLL" is not defined, evaluates to 0 [-Wundef]
1.465  4388 | #if FIO_ENGINE_POLL || FIO_ENGINE_WSAPOLL
1.465       |                        ^~~~~~~~~~~~~~~~~~
1.465 fio.c: In function 'fio_sentinel_worker_thread':
1.465 fio.c:4622:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  4622 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c: In function 'fio_start':
1.465 fio.c:4697:5: warning: "HAVE_OPENSSL" is not defined, evaluates to 0 [-Wundef]
1.465  4697 | #if HAVE_OPENSSL
1.465       |     ^~~~~~~~~~~~
1.465 In file included from fio.c:6001:
1.465 ./fio.h: At top level:
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 In file included from fio.c:6006:
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 ./fio.h:5264:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  5264 | #if DEBUG
1.465       |     ^~~~~
1.465 In file included from fio.c:6012:
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 In file included from fio.c:6669:
1.465 ./fio.h:3116:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |     ^~~~~~~~~~~~~~~~
1.465 ./fio.h:3116:25: warning: "FIO_FORCE_MALLOC_TMP" is not defined, evaluates to 0 [-Wundef]
1.465  3116 | #if FIO_FORCE_MALLOC || FIO_FORCE_MALLOC_TMP
1.465       |                         ^~~~~~~~~~~~~~~~~~~~
1.465 fio.c: In function 'fio_cluster_data_cleanup':
1.465 fio.c:6701:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  6701 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c: In function 'fio_cluster_listen_on_close':
1.465 fio.c:7050:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  7050 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c: In function 'fio_cluster_inform_root_about_channel':
1.465 fio.c:7213:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  7213 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c: At top level:
1.465 fio.c:7643:5: warning: "FIO_FORCE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  7643 | #if FIO_FORCE_MALLOC
1.465       |     ^~~~~~~~~~~~~~~~
1.465 fio.c:7885:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  7885 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c:8141:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  8141 | #if DEBUG
1.465       |     ^~~~~
1.465 fio.c: In function 'fio_mem_destroy':
1.465 fio.c:8215:5: warning: "FIO_MEM_DUMP" is not defined, evaluates to 0 [-Wundef]
1.465  8215 | #if FIO_MEM_DUMP
1.465       |     ^~~~~~~~~~~~
1.465 fio.c: In function 'fio_malloc':
1.465 fio.c:8227:5: warning: "FIO_OVERRIDE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  8227 | #if FIO_OVERRIDE_MALLOC
1.465       |     ^~~~~~~~~~~~~~~~~~~
1.465 fio.c: At top level:
1.465 fio.c:8319:5: warning: "FIO_OVERRIDE_MALLOC" is not defined, evaluates to 0 [-Wundef]
1.465  8319 | #if FIO_OVERRIDE_MALLOC
1.465       |     ^~~~~~~~~~~~~~~~~~~
1.465 fio.c:8490:5: warning: "__BIG_ENDIAN__" is not defined, evaluates to 0 [-Wundef]
1.465  8490 | #if __BIG_ENDIAN__ /* SipHash is Little Endian */
1.465       |     ^~~~~~~~~~~~~~
1.465 fio.c: In function 'fio_sha2_result':
1.465 fio.c:9229:6: warning: "__BIG_ENDIAN__" is not defined, evaluates to 0 [-Wundef]
1.465  9229 | #if !__BIG_ENDIAN__
1.465       |      ^~~~~~~~~~~~~~
1.465 fio.c: At top level:
1.465 fio.c:9615:5: warning: "DEBUG" is not defined, evaluates to 0 [-Wundef]
1.465  9615 | #if DEBUG
1.465       |     ^~~~~
1.465 cc1: note: unrecognized command-line option '-Wno-self-assign' may have been intended to silence earlier diagnostics
1.465 cc1: note: unrecognized command-line option '-Wno-parentheses-equality' may have been intended to silence earlier diagnostics
1.465 cc1: note: unrecognized command-line option '-Wno-constant-logical-operand' may have been intended to silence earlier diagnostics
1.465 make: *** [Makefile:248: fio.o] Error 1
1.465
1.465 make failed, exit code 2
1.465
1.465 Gem files will remain installed in /usr/local/bundle/gems/iodine-0.7.58 for inspection.
1.465 Results logged to /usr/local/bundle/extensions/aarch64-linux-musl/3.3.0/iodine-0.7.58/gem_make.out
------
Dockerfile:5
--------------------
   3 |     RUN apk --no-cache add g++ make
   4 |
   5 | >>> RUN gem install iodine
   6 |
--------------------
ERROR: failed to solve: process "/bin/sh -c gem install iodine" did not complete successfully: exit code: 1
Passing scenario (alpine3.20)
❯ cat Dockerfile
FROM ruby:3.3.6-alpine3.20

RUN apk --no-cache add g++ make
RUN gem install iodine

❯ docker build .
[+] Building 24.3s (7/7) FINISHED                                                                                                                                                                                                                                                                                                                      docker:desktop-linux
 => [internal] load build definition from Dockerfile                                                                                                                                                                                                                                                                                                                   0.0s
 => => transferring dockerfile: 121B                                                                                                                                                                                                                                                                                                                                   0.0s
 => [internal] load metadata for docker.io/library/ruby:3.3.6-alpine3.20                                                                                                                                                                                                                                                                                               0.0s
 => [internal] load .dockerignore                                                                                                                                                                                                                                                                                                                                      0.0s
 => => transferring context: 2B                                                                                                                                                                                                                                                                                                                                        0.0s
 => [1/3] FROM docker.io/library/ruby:3.3.6-alpine3.20                                                                                                                                                                                                                                                                                                                 0.0s
 => [2/3] RUN apk --no-cache add g++ make                                                                                                                                                                                                                                                                                                                              4.4s
 => [3/3] RUN gem install iodine                                                                                                                                                                                                                                                                                                                                      19.4s
 => exporting to image                                                                                                                                                                                                                                                                                                                                                 0.4s
 => => exporting layers                                                                                                                                                                                                                                                                                                                                                0.4s
 => => writing image sha256:56f38f8948198e98302610238d7de83f968975a421b52c4e3c151ebb25962a9a

Probably, what's the most interesting, here are the packages installed for alpine3.20 vs alpine3.21:

alpine3.21

1/13) Installing libstdc++-dev (14.2.0-r4)
(2/13) Installing jansson (2.14-r4)
(3/13) Installing zstd-libs (1.5.6-r1)
(4/13) Installing binutils (2.43.1-r1)
(5/13) Installing libgomp (14.2.0-r4)
(6/13) Installing libatomic (14.2.0-r4)
(7/13) Installing isl26 (0.26-r1)
(8/13) Installing mpfr4 (4.2.1-r0)
(9/13) Installing mpc1 (1.3.1-r1)
(10/13) Installing gcc (14.2.0-r4)
(11/13) Installing musl-dev (1.2.5-r8)
(12/13) Installing g++ (14.2.0-r4)
(13/13) Installing make (4.4.1-r2)

alpine3.20

(1/13) Installing libstdc++-dev (13.2.1_git20240309-r0)
(2/13) Installing jansson (2.14-r4)
(3/13) Installing zstd-libs (1.5.6-r0)
(4/13) Installing binutils (2.42-r0)
(5/13) Installing libgomp (13.2.1_git20240309-r0)
(6/13) Installing libatomic (13.2.1_git20240309-r0)
(7/13) Installing isl26 (0.26-r1)
(8/13) Installing mpfr4 (4.2.1-r0)
(9/13) Installing mpc1 (1.3.1-r1)
(10/13) Installing gcc (13.2.1_git20240309-r0)
(11/13) Installing musl-dev (1.2.5-r0)
(12/13) Installing g++ (13.2.1_git20240309-r0)
(13/13) Installing make (4.4.1-r2)

I haven't checked further into the backward-incompatible differences between g++ (13.2.1_git20240309-r0) and g++ (14.2.0-r4), but is this a known issue?

@boazsegev
Copy link
Owner

Hi @michal-kazmierczak ,

Thank you for bringing this to my attention. Do you have a docker file I could use for testing this?

There really shouldn't be a problem between the two compilers. If you have installation logs, maybe we could find the issue in there.

Also, could you please see if iodine 0.8 (development version) installs properly. It should work well enough for now except it doesn't have Redis support just yet.

Thanks!
B.

@fabio
Copy link

fabio commented Dec 14, 2024

Hi,

the compilation error is:

fio.c: In function 'fio_sock_sendfile_from_fd':
fio.c:3388:7: error: implicit declaration of function 'sendfile64'; did you mean 'sendfile'? [-Wimplicit-function-declaration]
 3388 |       sendfile64(fd, packet->data.fd, (off_t *)&packet->offset, packet->length);
      |       ^~~~~~~~~~
      |       sendfile

Iodine 0.8 compile with success.

Two Docker files to test Alpine 3.21 with both Iodine versions

FROM ruby:3.3-alpine3.21
RUN apk --update add build-base && cd /app; gem install iodine

# Build image:
#
#   docker build --tag alpaiodine-test .
#
# Optionally tag as latest:
#
#   docker tag alpaiodine-test alpaiodine:latest
#
# Run container:
#
#   docker run --rm -i -t alpaiodine-test
#
# Enter running container:
#
#   docker run -i -t alpaiodine-test /bin/sh

FROM ruby:3.3-alpine3.21
RUN apk --update add build-base git && \
    cd /app; \
    echo "gem 'iodine', git: 'https://github.com/boazsegev/iodine', tag: 'rw8.0'" > Gemfile && \
    bundle install

KR
-- fabio

@michal-kazmierczak
Copy link
Author

michal-kazmierczak commented Dec 14, 2024

Thank you @boazsegev for a quick response and @fabio for your input 🙇

I've included my Dockerfiles in my original message in the collapsible sections (Failing scenario (alpine3.21) and Passing scenario (alpine3.21) are/should be clickable).

I can also confirm that 0.8 compiles on alpine3.21.

@boazsegev
Copy link
Owner

Hi,

Thanks for pointing out the details I've missed.

I committed a patch to GitHub, but I'm not sure when (and if) it will be released. This patch might break backwards compatibility, as I have no idea how the system routing happens when calling sendfile on different systems.

On the newer glibc, the routing (64 bit vs 32 bit) is performed by glibc, which is why there's no longer any sendfile64. However, on other compilers and older versions the route ng might require explicity (which is how I wrote the code originally).

By the way, how is the 0.8.0.dev version working for you? Did you try it?

I still need to update and police some details (such as which tasks run on worker threads and which tasks run on the root / IO thread), and the Redis implementation is still missing (I need to rewrite it for scratch for the new Redis protocol)... but it should be quite solid (even more solid than the 0.7.x architecture).

The rewrite changes the core architecture, which should still prevent new clients from connecting to busy workers while also improving IO performance for existing (connected) clients, improving static file service availability (for connected clients), improving worker process load balancing, improving slow client and buffering resilience (slowloris immunity) and maintaining IO performance when all Ruby threads are busy with slow requests.

Also, the new architecture provides solutions for long-polling and streaming, utilizing NeoRack's approach and following its Specifications. This, of course, isn't necessarily a good fit for every app / route, but it's definitely shaping up to be a great tool for some micro-services that use WebSocket / SSE connections and publish or listen to an event stream.

Thanks for reading... I'm a bit excited about the new version and so I may have over-responded.

Good luck,
B.

@fabio
Copy link

fabio commented Dec 16, 2024

By the way, how is the 0.8.0.dev version working for you? Did you try it?

It works fine in testing. I can't test it as much as I would like with a production load because my largest application uses Redis.

I'm looking forward to trying it out on a production server with Redis implementation. Thanks for the updates and information you provided.

KR,
-- fabio

@akostadinov
Copy link
Contributor

When is 0.8.0 going to be released?

akostadinov added a commit to akostadinov/websocket-echo-io that referenced this issue Dec 25, 2024
akostadinov added a commit to akostadinov/websocket-echo-io that referenced this issue Dec 25, 2024
@boazsegev
Copy link
Owner

When is 0.8.0 going to be released?

Hi @akostadinov , thanks for your interest.

I'm mostly done, I think. I plan to release iodine once I finish the Redis Engine module (if I don't give up on it).

I was also hoping to finish the DataBase integration design, just in case it requires changes to the core API, but I'm doubtful if I will wait with the release until that's done. I just need to cover all the existing features to avoid breakage and this means implementing Redis.

However, I didn't even start rewriting the Redis parser and engine. It requires a rewrite in order to take advantage of new Redis features... so it might be a while.

B.

@akostadinov
Copy link
Contributor

Ok, no problems, just asking. I had to implement a workaround anyway. Happy holidays!

@boazsegev
Copy link
Owner

@akostadinov ,

Happy holidays :)

A workaround? Would you mind opening a new issue and describing the issue. As the 0.8 version is still under development, perhaps we can find a solution that works well for you.

Or, if you're using the iodine development version, perhaps we can add a commit tag that would prevent any further changes from breaking your release.

As for Redis, I'm looking into leveraging the redis client gem as an alternative to a native solution.

B.

@akostadinov
Copy link
Contributor

My workaround was to stick to alpine 3.20. Not a big deal for my use case. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants