I have a small Netty server, and im trying to follow the chat example.
I'm using maven and already added the dependency as follows:
<dependency> <groupId>io.netty</groupId> <artifactId>netty-all</artifactId> <version>5.0.0.Alpha1</version> </dependency> Now when I try to import SelfSignedCertificate or any other class from io.netty.handler.ssl.util. Eclipse complains, because it's not in the .jar file that was added by that dependency.
Any hint on what should i include? Thanks!
1 Answer
Version 5.0.0.Alpha1 is actually a pretty old version (December 22 2013).
According to The Central Repository the latest version of io.netty is 4.0.19.Final, released on April 30 2014.
However, if you look at the pom file for the chat example program you can see that it's importing version 5.0.0.Alpha2-SNAPSHOT of all the netty code.
A little further research shows that the API docs for 5.0.0.Alpha2-SNAPSHOT don't include that package, but if you go out to github and look at the handler code you can see that the util package was added 24 days ago, and the example you linked shows as only 18 days old.
I think you're going to either have to wait for that package to be merged into a release, or go download and build 5.0.0.Alpha2-SNAPSHOT yourself and install it locally.