Best way to set up Restlet with non-blocking connector

17 views
Skip to first unread message

Robert Sjödahl

unread,
Jan 28, 2018, 1:04:25 PM1/28/18
to Restlet Framework (Discuss)
Hey,

I'm using Restlet version 2.3.12 running it today with Jetty. I would like to run Restlet with a non-blocking connector. I found that there is an NIO connector. I tried that and it seems to work fine but in the documentation, it says that it is in "preview mode"? There do also seem to be an org.restlet.ext.netty package, but I read somewhere that it was an experimental feature in 2.0 and that it was removed in 2.1. And also it is not listed as a connector here: https://restlet.com/open-source/documentation/user-guide/2.3/core/base/connectors.

So what is the best way to run Restlet with a non-blocking asynchronous server connector? Should I use the NIO connector or a netty connector? Is there a third alternative?

I also know that Restlet will support netty (better?) from version 3.0, according to the roadmap: https://github.com/restlet/restlet-framework-java/wiki/Road-map-of-version-3

Thanks,
/Robert

Jerome Louvel

unread,
Feb 2, 2018, 4:56:40 AM2/2/18
to Robert Sjödahl, Restlet Framework (Discuss)

Hi Robert,

The best way today to get asynchronous NIO performance today is to use the Jetty connector and to configure it properly (see the available parameters).

The NIO and Netty extensions were experimentation to provide alternative NIO-based connectors but never reached enough feature completion nor quality to be used in production.

In our plans for version 3, there is a replacement for the pluggable connectors architecture in version 2 by a single connector based on the Netty framework. I'll come back to this point in your next email.

Best regards,
Jerome


De : framewor...@restlet.org <framewor...@restlet.org> de la part de Robert Sjödahl <robert....@gmail.com>
Envoyé : dimanche 28 janvier 2018 19:04:25
À : Restlet Framework (Discuss)
Objet : Best way to set up Restlet with non-blocking connector
 

Robert Sjödahl

unread,
Feb 7, 2018, 4:04:15 AM2/7/18
to Restlet Framework (Discuss), robert....@gmail.com
Ok, so basically reading corresponding docs for Jetty 9.2.x as this (could not find thoose docs online?) and configuring jetty accordingly: https://www.eclipse.org/jetty/documentation/9.3.x/high-load.html

Regards,
/Robert

Jerome Louvel

unread,
Feb 7, 2018, 5:21:55 AM2/7/18
to Robert Sjödahl, Restlet Framework (Discuss)

The mode I was suggesting relies on the embedded Jetty connector (based on org.restlet.ext.jetty.jar) as documented here.

You can also use Jetty as a regular Servlet container with the org.restlet.ext.servlet.jar bridge provided and documented here.


Best regards,

Jerome



Envoyé : mercredi 7 février 2018 10:04:14
À : Restlet Framework (Discuss)
Cc : robert....@gmail.com
Objet : Re: Best way to set up Restlet with non-blocking connector
 
--
You received this message because you are subscribed to the Google Groups "Restlet Framework (Discuss)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to framework-disc...@restlet.org.
Reply all
Reply to author
Forward
0 new messages