I have a grails project which uses jax-rs plugin with jersey and I would like use #JsonView described by http://wiki.fasterxml.com/JacksonJsonViews.
Actually, resources works but jsonview is not interpreted.
How I can do that ?
Related
We are trying to move our existing grails 2.5 application to newer versions of grails. For that adopting strategy to first upgrade to grails 3.3.11 (latest in 3.x releases) and then move to grails 4.
For one of the feature from grails 2.5.6 application, I found that there is nothing documented anywhere or may be I've missed that part on the document! It is about Plugin descriptor's doWithWebDescriptor. With this closure we can able to update web.xml dynamically based on some rules.
After upgrading to grails 3, I found that doWithWebDescriptor is not working. It is not initializing task which it supposed to (as far as grails 2.5 concerned). Later I found that there is nothing documented after grails 3.0 documentation.
If doWithWebDescriptor is removed then what is the best suitable replacement with grails 3 or latest grails 4 edition? If it still working fine and there is some configuration related changes required with grails 3 then kindly point me to that part.
Update:
Reason why we need doWithWebDescriptor is that, we are trying to add servlet based on the plugin. Actually we have several plugins for different modules in the application. Not all plugins included in the project. Based on modules selected we are adding plugin to the application. So if a plugin is included then we need to add servlet and a filter to web.xml.
Thank you.
Reason why we need doWithWebDescriptor is that, we are trying to add
servlet based on the plugin.
You can add a servlet by registering a ServletRegistrationBean in the application context. You can do that in the plugin's doWithSpring method or in the app's resources.groovy. Example:
Closure doWithSpring() {{->
myServlet(ServletRegistrationBean, new MyServlet(), "/myServlet/*") {
loadOnStartup = 2
}
}}
We have documented this in the 18.5 Hooking into Runtime Configuration section at http://docs.grails.org/3.3.11/guide/plugins.html#hookingIntoRuntimeConfiguration.
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).
I have been handed a .WSDL file which I need to test within a Grails Framework.
Any suggestions how to go about this.
Take a look at the http://grails.org/plugin/cxf and http://grails.org/plugin/cxf-client plugins. They're easy to use and backed by Apache CXF - https://cxf.apache.org/
The client plugin has a wsdl2java script that will generate code that you can use in your Grails app.
You could start with documentation itself: http://grails.org/Calling+External+WebServices
Publishing contract first web services in Grails using cxf is not working with the following.
http://docs.codehaus.org/pages/viewpage.action?pageId=85983334. I could not find any other useful resources on this problem. Using spring-ws may not be a good idea because I don't want to create end points for each element.
Please share some resources if anybody succeeded in publishing web service using cxf in Grails?
Setup:
Grails 2.0.0
cxf - 2.4.1
Grails-cxf - 0.5.1 (Latest is not working)
Groovy - 1.7.6
I've used http://grails.org/plugin/cxf in several projects. It works great for me. What exactly goes wrong when you try?
I really like plone as a CMS, but its base is in Python. I would like to know if there is a CMS that has Grails as a base.
You might want to take a look at Weceem CMS, which is open-source and uses Grails as the foundation.
http://www.weceem.org/weceem/
Wrong comparison. Python is a language. Grails is a framwork.
Plone (app) --> Zope (framework) --> Python (language)
? (app) --> Grails (framework) --> Groovy (language)
Don't know too much about Grails but maybe this is what you're looking for...
http://sourceforge.net/projects/gocms/
Probably not in the same league as Plone, but then few CMS's are.
There is also Codice ( http: //github.com/neodevelop/codice/tree/master ) and Countour-CMS (http: //www.seo-web-services.co.uk/a/contour-cms ) But none of these are production ready.
You can always integrate PHP packages like Wordpress and Plone into grails via the PHP plugin, which uses Quercus.