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

Clients cannot connect to Redis #2

Open
imbur opened this issue Jun 19, 2018 · 0 comments
Open

Clients cannot connect to Redis #2

imbur opened this issue Jun 19, 2018 · 0 comments

Comments

@imbur
Copy link

imbur commented Jun 19, 2018

Hi,
the packaged client.jar fails with an exception (see console output below) after trying to connect to Redis.

What I do:

  1. Pull redis image: docker pull redis
  2. Building the image: decking build thomas/models15
  3. Creating the cluster: decking create main
  4. Starting the cluster: decking start main
  5. Examine the output: decking attach main

I also tried to rebuild the client.jar with maven, however, the generated jar in the org.kevoree.proto.models15.client/target folder seems to be a different "client" artifact, since it is not runnable in itself.

Thank you very much for your kind help in advance again!

Redis console:

(redis)      1:C 19 Jun 20:17:59.564 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
(redis)      1:C 19 Jun 20:17:59.564 # Redis version=4.0.10, bits=64, commit=00000000, modified=0, pid=1, just started
(redis)      1:C 19 Jun 20:17:59.564 # Warning: no config file specified, using the default config. In order to specify a config file use redis-server /path/to/redis.conf
(redis)      1:M 19 Jun 20:17:59.567 * Running mode=standalone, port=6379.
(redis)      1:M 19 Jun 20:17:59.567 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.
(redis)      1:M 19 Jun 20:17:59.567 # Server initialized
(redis)      1:M 19 Jun 20:17:59.567 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
(redis)      1:M 19 Jun 20:17:59.567 # WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled.
(redis)      1:M 19 Jun 20:17:59.567 * Ready to accept connections

Client exception:

Error during Event Listener Redis
Exception in thread "main" redis.clients.jedis.exceptions.JedisConnectionException: java.net.SocketTimeoutException: connect timed out
	at redis.clients.jedis.Connection.connect(Connection.java:155)
	at redis.clients.jedis.BinaryClient.connect(BinaryClient.java:83)
	at redis.clients.jedis.Connection.sendCommand(Connection.java:94)
	at redis.clients.jedis.Connection.sendCommand(Connection.java:89)
	at redis.clients.jedis.Jedis.get(Jedis.java:97)
	at org.kevoree.modeling.databases.redis.RedisContentDeliveryDriver.atomicGetMutate(RedisContentDeliveryDriver.java:54)
	at org.kevoree.modeling.api.data.manager.DefaultKDataManager$4.on(DefaultKDataManager.java:240)
	at org.kevoree.modeling.api.data.manager.DefaultKDataManager$4.on(DefaultKDataManager.java:236)
	at org.kevoree.modeling.databases.redis.RedisContentDeliveryDriver.connect(RedisContentDeliveryDriver.java:138)
	at org.kevoree.modeling.api.data.manager.DefaultKDataManager.connect(DefaultKDataManager.java:236)
	at org.kevoree.modeling.api.abs.AbstractKModel.connect(AbstractKModel.java:27)
	at org.kevoree.proto.models15.client.TEST2_Client.start(TEST2_Client.java:65)
	at org.kevoree.proto.models15.client.TEST2_Client.main(TEST2_Client.java:141)
Caused by: java.net.SocketTimeoutException: connect timed out
	at java.net.PlainSocketImpl.socketConnect(Native Method)
	at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345)
	at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
	at java.net.Socket.connect(Socket.java:589)
	at redis.clients.jedis.Connection.connect(Connection.java:149)
	... 12 more
redis.clients.jedis.exceptions.JedisConnectionException: java.net.SocketTimeoutException: connect timed out
	at redis.clients.jedis.Connection.connect(Connection.java:155)
	at redis.clients.jedis.BinaryClient.connect(BinaryClient.java:83)
	at redis.clients.jedis.Connection.setTimeoutInfinite(Connection.java:66)
	at redis.clients.jedis.Jedis.subscribe(Jedis.java:2589)
	at org.kevoree.modeling.databases.redis.RedisContentDeliveryDriver$1.run(RedisContentDeliveryDriver.java:33)
	at java.lang.Thread.run(Thread.java:745)
Caused by: java.net.SocketTimeoutException: connect timed out
	at java.net.PlainSocketImpl.socketConnect(Native Method)
	at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345)
	at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
	at java.net.Socket.connect(Socket.java:589)
	at redis.clients.jedis.Connection.connect(Connection.java:149)
	... 5 more
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

1 participant