Skip to content

DATAREDIS-682 - Connect to Redis using unix domain sockets. #286

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

Closed
wants to merge 5 commits into from

Conversation

mp911de
Copy link
Member

@mp911de mp911de commented Oct 13, 2017

We now support Redis connections using OS-native transports through unix domain sockets when using the Lettuce driver. Domain sockets do not require a roundtrip through the networking layer but directly use native epoll or kqueue interfaces.

LettuceConnectionFactory factory = new LettuceConnectionFactory(new RedisSocketConfiguration("/var/run/redis.sock"));

Unix domain socket support requires netty's native epoll/kqueue dependencies matching the runtime environment:

<dependency>
	<groupId>io.netty</groupId>
	<artifactId>netty-transport-native-epoll</artifactId>
	<classifier>linux-x86_64</classifier>
	<version>${netty}</version>
</dependency>

<dependency>
	<groupId>io.netty</groupId>
	<artifactId>netty-transport-native-kqueue</artifactId>
	<classifier>osx-x86_64</classifier>
	<version>${netty}</version>
</dependency>

Related ticket: DATAREDIS-682.

We now support Redis connections using OS-native transports through unix domain sockets when using the Lettuce driver. Domain sockets do not require a roundtrip through the networking layer but directly use native epoll or kqueue interfaces.

LettuceConnectionFactory factory = new LettuceConnectionFactory(new RedisSocketConfiguration("/var/run/redis.sock"));

Unix domain socket support requires netty's native epoll/kqueue dependencies matching the runtime environment:

<dependency>
	<groupId>io.netty</groupId>
	<artifactId>netty-transport-native-epoll</artifactId>
	<classifier>linux-x86_64</classifier>
	<version>${netty}</version>
</dependency>

<dependency>
	<groupId>io.netty</groupId>
	<artifactId>netty-transport-native-kqueue</artifactId>
	<classifier>osx-x86_64</classifier>
	<version>${netty}</version>
</dependency>
Remove rdb file on make clean.
…aces.

Introduce interfaces to generalize aspects of configuration objects.

Replace repeating if-branches in connection factories with stream selector returning the appropriate configuration object.
christophstrobl pushed a commit that referenced this pull request Nov 17, 2017
We now support Redis connections using OS-native transports through unix domain sockets when using the Lettuce driver. Domain sockets do not require a roundtrip through the networking layer but directly use native epoll or kqueue interfaces.

LettuceConnectionFactory factory = new LettuceConnectionFactory(new RedisSocketConfiguration("/var/run/redis.sock"));

Unix domain socket support requires netty's native epoll/kqueue dependencies matching the runtime environment:

<dependency>
	<groupId>io.netty</groupId>
	<artifactId>netty-transport-native-epoll</artifactId>
	<classifier>linux-x86_64</classifier>
	<version>${netty}</version>
</dependency>

<dependency>
	<groupId>io.netty</groupId>
	<artifactId>netty-transport-native-kqueue</artifactId>
	<classifier>osx-x86_64</classifier>
	<version>${netty}</version>
</dependency>

Original Pull Request: #286
christophstrobl added a commit that referenced this pull request Nov 17, 2017
Enforce nullability constraints and update documentation.

Original Pull Request: #286
@christophstrobl christophstrobl deleted the issue/DATAREDIS-682 branch November 17, 2017 16:33
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

Successfully merging this pull request may close these issues.

2 participants