Skip to end of metadata
Go to start of metadata

Your Rating: Results: PatheticBadOKGoodOutstanding! 113 rates

Official Documentation Available
This topic is now covered in Blossom module.
Magnolia Blossom is the Spring integration module for Magnolia. If you're familiar with Spring you'll find the programming model offered by Blossom intuitive and easy to use. In a way its Spring Web MVC with content. It lets you write reusable templates and components with a high level of dynamic behavior that editors can compose to create truly interactive web pages. Using the proven application stack of Spring Framework makes it easier to develop integrations with for instance business systems to fetch information you want to present in your pages. If you already know Spring you'll appreciate that Blossom gets you faster up to speed and lets you work in an environment that you're already familiar with.

Key functionality

  • Annotation based API that builds on Spring Web MVC, it automatically detects annotated classes and registers them for use in Magnolia. Simply add @Template to your controllers and they're ready to be used as building blocks by editors.
  • Exposes controllers as templates and components, allowing you to use the controller for building a model. Useful if you need to call a web service to get information to present or if you need to read it from a database.
  • Having your templates, areas and components backed by an MVC framework has the benefit of a natural way of developing business logic also for the web.
  • Allows you to reuse controllers that you've already developed when you take the leap onto using a CMS.
  • Allows you to create dialogs with code instead of configuration. This has many benefits: you can populate the dialog at runtime with options detected at runtime, you get your dialogs out of the repository and into your source control (CVS, SVN, GIT).
  • Dialog validation callbacks for custom validation of input.
  • Execution of a components in front of Magnolia CMS so that it can choose to do a redirect and skip page rendering. Very useful for instance if you have a form that on post should either present an error message or do a redirect.

The latest version is 3.0.4.

Documentation
http://documentation.magnolia-cms.com/modules/blossom.html

Download
SourceForge Magnolia Maven repository

Maven
Instructions for setting up maven with the Magnolia maven repository here.

Issue tracker
http://jira.magnolia-cms.com/browse/BLOSSOM

Tutorials and Guides

Resources
Tobias Mattsson's Blog

Spring Framework and Magnolia CMS: Creating Complex Java-based Websites
Article from www.developer.com takes you step by step from setting up a project to writing templates and paragraphs.

Integrating Magnolia with Spring Framework using Blossom
This presentation by Tobias Mattsson from Magnolia Conference 2010 covers the features provided by Blossom and goes through examples of how they're used. Tobias also explains the benefits with using Spring Framework.

US Navy Integrates Spring Applications with Flying Colors Thanks to Web CMS
In this webinar Matt Dertinger, Solutions Architect at Campbell Ewald, shows how they used Magnolia and Blossom to deliver Navy.com and the integrations they needed. The webinar recording is available online.

Blossom 2.0 Feature Video
This video shows the new features and the updated API in Blossom 2.0

Blossom 2.0 Slide deck
Presentation slides updated for 2.0

Videos & other resources about Blossom

Javadoc Version 3.0.4
Javadoc Version 3.0.3
Javadoc Version 3.0.2
Javadoc Version 3.0.1
Javadoc Version 3.0
Javadoc Version 2.0.4
Javadoc Version 2.0.3
Javadoc Version 2.0.2
Javadoc Version 2.0.1
Javadoc Version 2.0
Javadoc Version 1.2.4
Javadoc Version 1.2.3
Javadoc Version 1.2.2
Javadoc Version 1.2.1
Javadoc Version 1.2
Javadoc Version 1.1.1

  1. Nov 05, 2009

    Great to have some Spring integration!

    It would be nice to have a maven artifact as well. I couldn't find any.

    Something to consider might be the use of the ContextLoaderServlet. As far as I now this is no longer available in Spring 3.

    See the 2.5 apidoc:

    "Note that this class has been deprecated for containers implementing Servlet API 2.4 or higher, in favor of ContextLoaderListener.
    According to Servlet 2.4, listeners must be initialized before load-on-startup servlets. Many Servlet 2.3 containers already enforce this behavior. If you use such a container, this servlet can be replaced with ContextLoaderListener."

  2. Mar 26, 2010

    I am planning on using Blossom in a project and so far it looks pretty good. Two remarks:

    • we used Magnolia 4.2.3 CE and are now looking into using 4.3.1 CE - Blossom seems to work fine with both.
    • above you have the "to do": FreeMarker ViewResolver that hooks into Magnolia's free marker rendering

    We configured the org.springframework.web.servlet.view.freemarker.FreeMarkerViewResolver as the view resolver in paragraphs-servlet.xml, and it seems to work fine? Is there a reason why it should not?

    Anyway, very interesting module, I'm looking forward to using it and it thinks it will allow us a nice, clean architecture.

  3. Mar 26, 2010

    That should work fine, however you'll want to have the directives setup in freemarker the way they are with magnolia. This can be done by having a viewresolver that returns a view that renders using magnolia's FreemarkerHelper.

    There's alot of activity in trunk right now. The 1.0 release will be ready next month. Among the features are:

    • Templates backed by controllers. They're detected and bootstrapped into the repository. No configuration is required to add a new template. Just add @Template on a controller and you're done.
    • Dialogs for templates can be created by callbacks in the template, the same way paragraph dialogs are created now. No configuration is required. Just add @DialogFactory on a method.
    • Rendering can be performed using magnolia's built in rendering for JSP's and freemarker templates.

    It's very exciting to see all this come together. The stuff in trunk is subject to change right now but if you have the time you're welcome to check it out. We would love to hear what you have to say.

    The upcoming version will be compatible with 0.5 produced content. There will be some changes to the API but nothing that you can't fix with a few search-replace operations.

  4. Jul 15, 2010

    Is it possible to associate a SaveHandler with a Blossom configured Dialog?  On standard dialogs you can add a "saveHandler" attribute with a class name as the value and it will be executed when the user saves the dialog.

    This is sort of like validation but there are parameters available to the SaveHandler that are not available in just the request.  For example, a SaveHandler has access to the MultipartForm which allows you to do things with files that have been uploaded.

    1. Aug 09, 2010

      There's no direct way to configure this on your blossom dialog. But you can easily extend DefaultBlossomDialogRegistry and write the saveHandler attribute to the repository on your own.

    2. Dec 23, 2010

      As of version 1.2 you can use the @InitSaveHandler annotation on a method that should be responsible for creating and configuring the SaveHandler to be used. Its available in dialog factories and of course in paragraphs that act as a dialog factories for their own dialog.