Vert.x 3 archetypes

246 views
Skip to first unread message

Erwin de Gier

unread,
Mar 14, 2015, 5:41:22 AM3/14/15
to ve...@googlegroups.com
Since I wasn't able to find any vert.x 3 maven archetypes, I created two myself. A simple archetype based on the Maven verticle example and an archetype which includes the MongoDB connection and an Angular JS app. 
I use these for quickstarting vert.x 3 example applications and in workshops. They currently use the 3.0.0-SNAPSHOT version, but I will upgrade them one a final version is released.

Links:

Git clone and mvn install to install them in your local repository. 

Of course I am open to any improvements/comments. 

Julien Viet

unread,
Mar 14, 2015, 9:04:56 AM3/14/15
to ve...@googlegroups.com, Erwin de Gier
Hi,

I’ve done a pull request with a Vertx Unit test for your verticle in the vertx-simple-archetype.

I’m suggesting you add  another archetype using the RxJava api.

-- 
Julien Viet
www.julienviet.com
--
You received this message because you are subscribed to the Google Groups "vert.x" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vertx+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Erwin de Gier

unread,
Mar 14, 2015, 9:26:00 AM3/14/15
to ve...@googlegroups.com
Thank you, I merged the request, the Unit test is a good addition. Is there any specific example with the RxJava api that you want to see in the archetype?

Julien Viet

unread,
Mar 14, 2015, 9:32:33 AM3/14/15
to ve...@googlegroups.com, Erwin de Gier
I don’t, it’s your archetype :-)

I will add soon a few Rx examples in the vertx examples repo (https://github.com/vert-x3/vertx-examples) perhaps you can add one of them at this moment.

-- 
Julien Viet
www.julienviet.com

On 14 Mar 2015 at 14:26:03, Erwin de Gier (er...@edegier.nl) wrote:

Thank you, I merged the request, the Unit test is a good addition. Is there any specific example with the RxJava api that you want to see in the archetype?

javadevmtl

unread,
Mar 17, 2015, 10:28:45 AM3/17/15
to ve...@googlegroups.com, er...@edegier.nl
Julien would you create an RX example that show how to use RX Java with the Vertx observables? When we look at the RX docs it's not quite obvious, especially when new to RX. I think vertx-when has really good example showing how we can make multiple HTTP client or event bus calls in one shot and merge them back together.

I think this verry explanatory compared to just saying that Vertx can return observables.

List<Promise<Message<JsonObject>>> promises = new ArrayList<>();

promises
.add(whenEventBus.<JsonObject>send("et.vertx.eb.1", new JsonObject().putString("message", "hello")));
promises
.add(whenEventBus.<JsonObject>send("et.vertx.eb.2", new JsonObject().putString("message", "world")));

when.all(promises).then(
        replies
-> {
           
// On success
           
return null;
       
},
        t
-> {
           
// On fail
           
return null;
       
});


Julien Viet

unread,
Mar 17, 2015, 10:32:59 AM3/17/15
to ve...@googlegroups.com, javadevmtl, er...@edegier.nl
I’ve been contributing on this since yesterday.


there are other simpler examples.

I will add one that combines event bus too.


-- 
Julien Viet
www.julienviet.com
Reply all
Reply to author
Forward
0 new messages