grails server push - grails

I've been evaluating grails server push technologies, and I keep coming across the grails atmosphere plugin, but it doesn't seem like it is actively being developed. I've also seen the grails events push plugin. Is there a standard plugin that is being used for server push in grails? Is it one of these or another one all together?

The Grails events push plugin is the recommended one.
(I am the creator of Atmosphere).

Related

Internal mailing system plugin for Grails

Is there any internal mailing plugin for Grails? I want the registered users on my system and send mail to each other internally - not using a third party systems such as Gmail or Hotmail .
Is there something like that? Even if it is developed by java.
I haven't tried it myself, but this might do the job (assuming you are fine with an internal messaging system instead of real emails):
https://grails.org/plugin/grails-direct-messages
https://github.com/kaleidos/grails-direct-messages
You can use the grails mail plugin but configure it to use your own mail server.
You can use the company exchange server or run your own server using the Apache James Project or a multitude of other mail server application.

Order of Grails Bootstrap classes

On one of our feature branches of our project we have a strange issue with running our grails integration tests. In our application we have the base project and one plugin, which relies on data from the base application. The default data is created in the "Bootstrap" Classes of the project and the plugin.
since yesterday the bootstrap of the plugin is called before the base bootstrap, and fails, because of the missing data from the application. This happens only if we run the integration tests, and only on our buildserver (Windows Server 2012 with Atlassian Bamboo).
test-app -integration --stacktrace -non-interactive
how can we fix this problem?
Grails makes no guarantees about ordering of BootStrap classes so it isn't something that should be relied about in your application.
If you need to control ordering of logic that is run at startup there are better solutions, for example you could use the platform-core plugin's event model to trigger an event in your application that your plugin listens to once the data it needs is in place. See http://grails-plugins.github.io/grails-platform-core/guide/events.html

Configure an Activiti BPM?

I want to know that how to configure/run Activiti BPM in Grails?? I'm using fedora as my OS, Grails 2.1 . If their is any tutorial websites are is plz mention it also..
There is a plugin for Grails applications that provides much of Activiti within a Grails app. http://grails.org/plugin/activiti However, development has sadly stopped on it by the main developer. The last update was for Activiti 5.9 and Grails 2.1, though much of the plugin content seems to be built for older versions of Grails; for example, actions in the plugin's TaskController are all closures, not methods. Also, someone did issue a pull request to update it to 5.10.
I've been trying to puzzle through the source for that plugin myself. I keep vacillating between simply setting up a standalone Activiti server and utilizing the RESTful API from within a Grails Service class, importing a few of the Activiti classes into my Grails app, or trying to re-engineer the plugin to suit my needs (my site is stuck on Grails 2.0.1 for the time being).

Grails with Comet working example

I'm trying to implement server Push technology in Grails application using Comet by working out few simple examples, but I'm struggling to make it really work. I've been trying out 2 examples from the below 2 links and it is not working. Not working in the sense, am not able to see the expected result, though I don't get any errors/exceptions.
Using Cometd 2.x with Grails
Grails-based Comet (Bayeux Protocol)
Any help in the form of working example, pointers, links, suggestions, etc. are really appreciated.
NOTE: As you can see from above posts, the article is 2-3 years old. Currently, I'm running Grails v2.1.0 and cometd plugin is v0.2.2. IDE is NetBeans v7.2.
I managed to find a solution for server push technology using Grails Events Push Plugin, though, instead of Cometd / Bayeux.
Following links were helpful in implementing server push technology:
Grails with Comet working example
Issue with grails events push plugin
Example of Events-Push in action in the SpringOne2GX Day 1 Keynote video by Graeme (goto 1:06 in the video)

grails plugin to get gmail attachment

I am working on a grails project and i need a plugin to extract an email attachment from a Gmail account.
My colleague said something about Java Mail API but i am not actually sure about how to integrate the api with grails.
Is there any other plugin or workaround to extract an email attachment from a gmail account?
Thanks.
While not specific to extracting attachments from GMail, the Grails Routing plugin would definitely be worth evaluating. It integrates Apache Camel into your Grails services and controllers and provides a very easy way to create routes. You can then add the following dependency to your grails-app/BuildConfig.groovy file:
// replace x.x.x with version used by the Grails Routing plugin
runtime("org.apache.camel:camel-mail:x.x.x")
In the documentation for the Mail component you will an example of grabbing attachments from GMail and there is also this blog entry by Mr Haki that shows an example using the older Grails Camel plugin (Routing plugin supercedes it).
While I haven't used Camel for this purpose, I have used it on a few projects and would recommend it as a possible solution. It is a very powerful integration tool and can really make it very easy to do some pretty complicated things.

Resources