BusinessObjects Board

Custom elements NODEJS NPM War file

Hopefully this is the right place to post my question which would be aimed at those of you whom are Java and/or Javascript experts.

I myself have played around with each and not that good at it, I can look at a piece of code in a file and adapt it to suit my needs. It is a bit like knowing how to drive a car, fill it will petrol, top up water and oil but no idea on how to take apart the engine and put it back together again.

What I have done is create my own custom element visualisations which is using Leaflet maps, it works really well, I have done both heatmap and markers, and can place upto 2500 markers on the map and for heatmap total is not yet known, have not managed to break it yet. Needs a bit more work on cosmetics and making it more user freindly. Exciting for me as I am now able to enhance our customers experience within BI Launchpad.

Problem I have is the single JS file is executed and processed with nodejs, I enter pm2 start “myfile.js” and it runs on my local machine, The js file was the sample provided for Google visualisations such as Google guage in which I removed all the parts I did not need and re-coded most of it. http://locahost:8090 is entered as the custom element URL in Web Intelligence application and I am good to go.

What I would like to do is somehow extract all required bits and bobs out of nodejs and create either a WAR file or create a folder structure so I can place it within our existing BI Tomcat server under webapps folder or place on another server our team can access in a tomcat\webapps folder. I cannot install nodejs on these servers and our IT team will not allow me another server or virtual machine where I can install nodejs and npm etc.

Is it going to be possible to somehow translate/convert what is happening with my single js file processed/run within nodejs over to tomcat\webapps[i]mycustomelements[/i]\ folder and have it working just as it is within nodejs.

Hopefully if possible the method to do this is simple, remember I can drive the car but have no idea how to take the engine apart and re-build.

Many thanks


Update : I have successfully created Markers and a Heatmap selection within the same file, working really well, once I upped the max Mb within my file I can add upto 30,000 map points, rendering is really quick, quicker than say Galigeo. Once I become more familiar with the Javascript I will do what any programmer should do and add comments in the code, write supporting documentation and place in here for FREE so anyone can use it in there environment. Whoohoo I now have ability to write custom elements, just the issue listed above to deal with, I may bite the bullet and install NodeJS on a spare server at work, if I can find one.

Macroman :uk: (BOB member since 2002-11-13)

node.js relies on its own built-in webserver.

You either need a server to run node.js, or you need to rewrite your extension to run as a java jsp webapp.

There are on-line programming services that will do contract work. It may not cost that much to convert it.

Hayden_Gill :australia: (BOB member since 2002-08-15)

Just checking to see if you’ve posted this for download yet. I am quite curious…

Seagrass (BOB member since 2014-11-18)

This is my first upload and hopefully approved by administrators and consumed by those out there that have a need and to understand custom elements design and implementation within the BI world. Here I am sharing my experience with you and an end product that I have managed to get working. I am by no means an expert in certain areas required to get this working, and for want of a better word, I dabble and as an Administrator of our own BI environment at work I have certain powers technically to undertake project testing. Creation of a custom element to consume leaflet maps is one such project which after a certain time I got working. I am not an expert in Javascript and I am not a technical expert in any of the SAP application designs (such as all the code and scripts that exist in a SAP BI deployment) so I may not be able to answer any high level technical questions. There are 3 files in the attachment, the CE_Maps.js file to be consumed within a NodeJS setup and as best I could instructions for those whom are technical to install NodeJS and configuration, plus an instruction for your customer on how to consume the CE_Maps. I am treating this as open source and my appreciation goes out firstly to this magnificent forum in which over the years has guided me in many areas of BI and secondly to all those that exist on the internet under the name of “open source” whom not only provide us with samples to test but also with there high level technical expertise and even guidance. As mentioned I am not an expert in certain fields and I welcome a version 2 or even version 10000 of the attachment to be re-coded by someone more qualified in certain fields than I am and uploaded here to share with others as I am doing now. (964.0 KB)

Macroman :uk: (BOB member since 2002-11-13)