DavidBM / rsmq-async-rs

RSMQ port to async rust. RSMQ is a simple redis queue system that works in any redis v2.6+
MIT License
43 stars 8 forks source link

Upgrade redis to 0.25 #19

Closed emmiegit closed 2 months ago

emmiegit commented 2 months ago

The redis crate is now on 0.25.3. The most notable change is the deprecation of redis::aio::Connection. Otherwise, the build occurs with no errors.

Build warnings ```rs warning: use of deprecated struct `redis::aio::Connection`: aio::Connection is deprecated. Use aio::MultiplexedConnection instead. --> src/normal_facade.rs:9:36 | 9 | struct RedisConnection(redis::aio::Connection); | ^^^^^^^^^^ | = note: `#[warn(deprecated)]` on by default warning: use of deprecated struct `redis::aio::Connection`: aio::Connection is deprecated. Use aio::MultiplexedConnection instead. --> src/normal_facade.rs:20:42 | 20 | functions: RsmqFunctions, | ^^^^^^^^^^ warning: use of deprecated struct `redis::aio::Connection`: aio::Connection is deprecated. Use aio::MultiplexedConnection instead. --> src/normal_facade.rs:48:33 | 48 | connection: redis::aio::Connection, | ^^^^^^^^^^ warning: use of deprecated struct `redis::aio::Connection`: aio::Connection is deprecated. Use aio::MultiplexedConnection instead. --> src/pooled_facade.rs:49:42 | 49 | functions: RsmqFunctions, | ^^^^^^^^^^ warning: use of deprecated struct `redis::aio::Connection`: aio::Connection is deprecated. Use aio::MultiplexedConnection instead. --> src/pooled_facade.rs:25:35 | 25 | type Connection = redis::aio::Connection; | ^^^^^^^^^^ warning: use of deprecated struct `redis::aio::Connection`: aio::Connection is deprecated. Use aio::MultiplexedConnection instead. --> src/pooled_facade.rs:32:53 | 32 | async fn is_valid(&self, conn: &mut redis::aio::Connection) -> Result<(), Self::Error> { | ^^^^^^^^^^ warning: use of deprecated method `redis::Client::get_async_connection`: aio::Connection is deprecated. Use client::get_multiplexed_async_connection instead. --> src/normal_facade.rs:37:33 | 37 | let connection = client.get_async_connection().await?; | ^^^^^^^^^^^^^^^^^^^^ warning: use of deprecated method `redis::Client::get_async_connection`: aio::Connection is deprecated. Use client::get_multiplexed_async_connection instead. --> src/pooled_facade.rs:29:21 | 29 | self.client.get_async_connection().await | ^^^^^^^^^^^^^^^^^^^^ warning: `rsmq_async` (lib) generated 8 warnings ```
DavidBM commented 2 months ago

Thanks for the notice. I will update the crate, hopefully today.

DavidBM commented 2 months ago

I updated the crate to the version 9. The biggest change is that the multiplexed facade has is now the one used on the Rsmq struct, and the normal facade that was used for that struct previously has been deleted.

So now there are only two options, Rsmq and PooledRsmq, both using the MultiplexedConnection