Friday, July 11, 2008

OLAP component: Mondrian+JPivot or Flex OLAPDataGrid ?

Recently I've been spending a few hours digging into OLAP cube components (a special table to analyse large and multi-dimmentionnal data in Business Intelligence). I wanted to produce a nice demo with an OLAP cube plugged to the OpenERP (by far the best open source ERP) database.

I actually saw a guy demoing such an OLAP Flex component along with Openbravo ERP (looking nice but the details were provided): http://opensourceerpguru.com/
Anyway I just wanted to achieve the same but using OpenERP (I feel much more comfortable with it's elegant and efficient architecture, not to tell about the features nor the business model) this time and eventually JRuby on Rails, my best Swiss knife to pull the data to the OLAP viewer.

So at first I've been stunned by the OLAP Flex component (called OLAPDataGrid) . It looks really nicer than the old fashion Mondrian JPivot. So I decided to give it a try. First time with Flex and back to the half open source crapp since long ago. So I had to follow all the Adobe crapp flow: create a fucking account, read all their commercial crapp, agree with their whatever license and finally download the stuff and start playing with it. Then I remarked that all my FlexBuilder nice OLAP samples were coming with a "Flex Data Vizualisation Trial" watermark. OK, time to remeber, FlexBuilder is not open source yet, so let's go with the Flex SDK, back to the Adobe legacy crapp, download again and try again (I heard that the SDK was open source, or sort of).

Then I tried to compile my mxml component with the following command line:

flex_sdk_3/bin$ ./mxmlc /home/rvalyi/DEV/olap_test/src/olap.mxml
Loading configuration file /home/rvalyi/Desktop/flex_sdk_3/frameworks/flex-config.xml
/home/rvalyi/DEV/olap_test/src/olap.mxml(162): Error: Could not resolve to a component implementation.

id="myMXMLCube"

/home/rvalyi/DEV/olap_test/src/olap.mxml(195): Error: Could not resolve to a component implementation.


WTF ???

Googled the error message and got the official answer from an Adobe employee on a forum here: http://www.codeverge.net/item.aspx?item=101509

The OLAPDatagrid component is available only in the Flex Builder Professional
version. For the first problem, the one where you are building a Flex + LCDS
2.5.1 project, the answer is that the LCDS 2.5.1 doesn't include the
OLAPDatagrid component and that is way you are getting the errors on runtime.


You f****** b*st*rds! you got me! So that how I lost a few hours trapped by the Adobe half open source policy, go hell!

Mondrian or Flex OLAPDataGrid?
Well, back to Mondrian and JPivot...

OK, for sure Mondrian and JPivot aren't really something optimal and I feel more like it's a bloated non HTTP compliant piece of code, but hey it's free and it just works. So until Tiny.be release their awesome open source "TinyBI framework" (for October?) I'll stick with it. I'll hardly try Flex and Flash again, I promise.

Finally I should say that I really don't know anyway how that Flex component would deal with a large database as it seems it's an in memory client side OLAP solution only. Even if it were to change, I'm not sure I would feel comfortable in feeding the right data pieces as the OLAP component requires them and finally all the existing samples don't come with drill down, slicer and rotation widgets, so I'm not sure how easily one can interact with the cube.

May this post save your time.

21 comments:

Cosma said...

Hi Raphael,

just a note: the Adobe OLAP solution, bundled with the non-free FlexBuilder professional, is made up of different pieces:

1) an olap engine that runs in the Flash virtual machine, that allows you to define measures (facts) and dimension and create a in-memory aggregated cube.

2) a query API that allows you to query this cube in a programmatic way (non-mdx).

3) a visualization component, the OLAPDataGrid, that you can use to display the result of an olap query.

The component are designed to be interchangeable pieces, so you can use your server-side implementation of the olap engine, wrap the results in objects that implements the flex olap API and feed it to the OLAPDataGrid for visualization, or you can use the provided engine but design your own visualization component.

This said, I must admit that performance won't allow you to create cubes using datasets larger then some thousands rows with the built-in engine (number of dimensions and measures will also affect this limit), and the display component (OLAPDataGrid) suffers very much when you put too much elements "ON COLUMNS", while it performs pretty well with high row count - probably because it extends directly from a plain data grid component, and is very optimized just for "vertical" sets.

Anyway, I think Flex as a whole is a great product and a joy to work with :)

Regards,
Cosma

Craig Petty said...

Yes, JPivot is ugly. The Flex component looks better, but it does the aggregation in the client.

My jaw dropped a couple of weeks ago when I ran across openi. After watching their demo, I was so excited about that I installed Mondrian and openi. Pretty painless (if anything involving Mondrian could be called painless).

In any case, google openi and try the demo at their site. Its open source.

Prashant said...

Is there any way to call Mondrian in Flex . In one sample I have seen fc:XMLAService and fc:ASCUBE , do you any idea about it .Please help me

Unknown said...

Hey Raphael,
I have somehow missed your post and lost considerable amount of my time and hardwork on what you rightly called as "half open source" Adobe stuff. I too promise never look at that glaring stuff unless somebody ready to shell out license costs upfront :-)
Appreciations for your efforts,
Thanks,
Vijay Thatte

Anonymous said...

That’s Too nice, when it comes in india hope it can make a Rocking place for youngster.. hope that come true.

Anonymous said...

Good post and this enter helped me alot in my college assignement. Thank you as your information.

Tani said...

OLAP cube components are plugged to OpenERP. OLAP samples come with a Flex Data Vizualisation Trial watermark.
sap upgrades

Anonymous said...

If a natuгal diѕаster ѕtrіkeѕ, arе уou preparеԁ foг іt?
If thе answer іs no, tаκe a looκ аt thіѕ free guide оn
ѕuгvіval at http://ѕuгѵivе.
toр-informatіоn.net/
My blog - HCG DIET - effects of dieting during pregnancy

Anonymous said...

If a natural disaster striκes, are you prepаred for it?
If thе answer is no, take a look at this freе guide on survival at
http://survive.top-infoгmation.net/
Also visit my weblog :: heartdata.net

Anonymous said...

If a naturаl dіsaster ѕtгiκеs, агe уou preparеԁ for it?
If thе answer is nο, take а look at this frеe guiԁе on survival
at http://surviѵe.top-information.net/
Here is my web-site ... Buy 3D Glasses

Anonymous said...

Getting a gooԁ HD TV hаs never beеn eаsier.
Diѕcoνеr the rіght mоdel
fоr you anԁ yοur pocκet with оuг rеviеω аt http:
//гeνiеwѕ.tοp-informatіon.
net/samsung-un40eh6000-review/
My web page :: Framing Nailer Reviews

Anonymous said...

Ӏf a natural ԁisаѕter ѕtгiκes,
aгe you prepared for it? If the answeг is no, take a look аt this free
guide on surѵival at http://surѵive.top-informatiοn.
net/
my page :: Symptoms of Anxiety in Men

Anonymous said...

Need hosting? Get thе top deals at http://hostіng.
tοp-informаtіon.net/
My web-site :: best way To clean laminate floors

Anonymous said...

A tablet аnd a laρtop comе
together at http://www.squiԁoo.cоm/samѕung-atіѵ-smaгt-pc-рro-700t-reviеw
Also visit my weblog - babybeachtent.net

Anonymous said...

Α high quаlity camега for a verу attractіve pгice
οr just а bаd quality piсture?
Discover on the full review at http://reviews.tоp-information.
net/canon-poωeгshоt-sx50-hs-геview/
Also visit my blog : Stage 4 Kidney Cancer

Anonymous said...

Rаnκ yоur Youtube Vidеos at http://yοutubeгanking.
tоp-information.net/ -> Just $5 a Viԁеo!
my page :: rv checklist

Anonymous said...

Ever wondered how to lucid dream? We have the ѕolutіοn аt httρ:
//luciddreаming.tοp-infοгmation.
net
my webpage - Modern Fish Tanks

Anonymous said...

Having trouble losing ωеight? Ηow about takіng a look at what is considеred tο be a fаt burner in a bottle?
Check our guide on hοw to use Rapberry Ketones and get them
for the best pгice at http://raѕpberryketones.
hеaгtԁаta.net/
Check out my web site ... HP Pavilion dv7-7030us

Anonymous said...

Just submit your emaіl at http://www.freeipad3.

allthebestproductѕ.net and sign up to test Apρle's products! You get to keep them afterwards!
Also visit my homepage Car Subwoofers for Sale

Anonymous said...

Іf a naturаl dіsaster strikes,
aгe уou ρrepared for it? If the ansωeг is no,
take a looκ at this frеe guide on survival at httρ:
//suгvive.top-іnformаtion.net/
Feel free to surf my website :: Propane Heater

Anonymous said...

hermes bag
kobe byrant shoes
air jordan
birkin bag
golden goose us outlet