4 Replies Latest reply: May 24, 2016 4:41 AM by Karl Fredberg RSS

    Best practise to persist data/config in mashup?

      I've been thinking about how to store user settings in a mashup, and I don't know where to start.

      For example if I create a mashup like the Qonnections 2015 on Qlik Branch and want the users to store their tab config as a preset that is available for the user over different sessions. How would you best go about and do that? Both with published and unpublished mashups

      Here are some of my ideas

      • write to a json file in the same directory as the mashup?
      • Store data in an app that is published and save the app?
      • Run a load script that store data in file or database?
        • Re: Best practise to persist data/config in mashup?
          Alexander Karlsson

          Hmm, I would careful around assigning to much application logic into the QVF.


          For example, for branch.qlik.com we use MongoDB to store user profiles, user preferences and then we use Qlik to search and filter data from MongoDB.


          Now with that said, if you do want to persist those kinds settings into the QVF you can of course. I would probably persist a GenericObject with default settings and then create a GenericObject per user and store that. You can then leverage the standard Qlik apis to interact and fetch those objects and you don't need to introduce any additional server side components.


          Luckily our Generic Objects are truly generic, you can store whatever full dynamic properties you want it them. Heck you could even decode a mp4/avi into a array buffer and store that in your generic object if you wanted to (Don't tell our IT)

          • Re: Best practise to persist data/config in mashup?
            Erik Wetterberg

            Another option is to use local storage. Easy to implement, but the settings will be stored client side, so if the user uses another device he wont get the same settings (like if you open your mashup on a tablet you will not have the same settings as on the desktop).