Any MVC framework-like features for vert.x such as template and authentication?

1,329 views
Skip to first unread message

Andy

unread,
Nov 28, 2012, 8:30:04 PM11/28/12
to vert.x
Hi,

New to vert.x. The application I'm building would benefit from
traditional web MVC framework features such as templates, user
authentication, facebook login, etc. Are these features available for
vert.x or is this not the best use case for vert.x?

Thanks.

Guillaume Laforge

unread,
Nov 29, 2012, 1:47:52 AM11/29/12
to ve...@googlegroups.com
For the template engine, you can use Groovy's built in one.

Guillaume
> --
> You received this message because you are subscribed to the Google Groups "vert.x" group.
> To post to this group, send an email to ve...@googlegroups.com.
> To unsubscribe from this group, send email to vertx+un...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/vertx?hl=en-GB.
>

Tim Fox

unread,
Nov 29, 2012, 6:03:54 AM11/29/12
to ve...@googlegroups.com
+1

Or you could try the mustache module which was recently contributed.

Vert.x is a low level platform (similar in this way to node.js) so doesn't provide any templating per se. But this is the kind of thing we should expect to find in modules that use vert.x
Message has been deleted

Joris Hermans

unread,
Nov 29, 2012, 7:02:54 AM11/29/12
to ve...@googlegroups.com
You start by viewing a basic demo on https://github.com/jorishermans/vertx-demos/tree/master/template_demo how to use the mustache template demo! I haven't used the postgress module or mongodb module, but that are modules that you can use to grab the data and pass them to the mustache module!

Futher plans for mustache module is the ability to add client side templates and insert them into the page. So you can easily render serverside, good for seo and use also mustache on the clientside!

Asset pipeline is also an item that I am planning to look into!

I am also working on a oauth module, so that is coming.
I want to build an omniauth (ruby on rails) and everyauth kind of like module. But I will first start with facebook and then google+ and twitter will follow.
You can find the source on github so if you want to help please do and fork my project ;-)

Another thing that I am missing is the fact of adding multiple handlers to a RouteMatch, and that every handler can stop the process, or is this already possible?
It is nice to have that so we can create one handler for checking authentication and if not authenticated we are going to redirect them to the login page ...

bytor99999

unread,
Nov 29, 2012, 11:01:39 AM11/29/12
to ve...@googlegroups.com
Thanks Joris. I will also have a need for oauth and was also going to build an oauth module. One part for logging into our app with Facebook, Twitter, but also to act as an oauth authentication server too. I will have to look at your project and maybe work with it, helping out. But we won't reach that point for a month or so.

Mark

bytor99999

unread,
Nov 29, 2012, 11:08:21 AM11/29/12
to ve...@googlegroups.com
On the templating side. Besides using it to generate html. What other use cases might this be used. I am trying to figure out if it would be helpful in our app. I can see maybe for the json messages. But we are using Groovy, so that is extremely simple, actually simpler than using something like Mustache. (I use ICanHaz.js a lot)

Or maybe in some cases templates for db calls with things like Mongo perisister module. 

Anyway, just thinking out loud

Mark

Joris Hermans

unread,
Nov 29, 2012, 1:28:37 PM11/29/12
to ve...@googlegroups.com
Thanks for the feedback! I use mustache alot so for me it was a logic step to build a module for that!

Brad Orego

unread,
Apr 29, 2013, 6:59:35 PM4/29/13
to ve...@googlegroups.com
Hi Joris,

I was really excited when I saw a Handlebars module for vertx, but thus far I've been completely unable to get it working at all. I've tried my own setup as well as trying to replicate your demo, both with no luck.

Could you possibly provide a little more instruction/documentation on how the module is meant to be used? I keep getting a "File not found : templates\count.html" error when I try to navigate to any route that should be utilizing Handlebars.

Any help would be much appreciated :)

- Brad
Reply all
Reply to author
Forward
0 new messages