7 Replies Latest reply on Jul 11, 2018 7:17 PM by jamesa53173240

    Launch config not updated in AEM

    jamesa53173240 Level 1

      Hello,

       

      I have integrated Adobe Launch with AEM 6.4 and I am having issues with updated Launch config to be shown on AEM.

       

      Pre-requisite:

      AEM and Launch integration has been setup

       

      Steps to produce issue:

      1. Make any changes in Adobe Launch (e.g. create a rule to rename the page title)
      2. Publish the change in Adobe Launch
      3. AEM downloads the changes (via pre-configured cron scheduler polling or by launching the Adobe Launch Library Download workflow)

       

      After performing steps above, I can see the following changes in AEM:

      • AEM error log shows that the new Launch library files were downloaded into /var/cq/dtm-reactor/clientlibs
      • libraryEntries and libraryEntriesPrev were updated in /conf/{your-site}/settings/cloudconfigs/dtm-reactor/jcr:content/{env}
      • libraryUri is NOT updated and still points to the old path

       

      As a result, the site that was configured to use Adobe Launch did not get the latest changes.

       

      Is this a bug or is there something else needs to be done to prevent this?

       

      Thanks,

      James

        • 1. Re: Launch config not updated in AEM
          jamesa53173240 Level 1

          Ok, after playing around a bit more, I can observe that this is a "normal" behaviour.

           

          So after a library update is published / build in Launch, it seems like it requires to launch the Adobe Launch Library Download workflow twice on AEM before the libraryUrl correct itself.

           

          The only thing pending is that the rule using the Core library to run Custom Code is not running on the page.

          • 2. Re: Launch config not updated in AEM
            Jantzen.Belliston Adobe Employee

            kautuksahni do you have anything to add here? I know you done some work with the AEM/Launch integration.

            • 3. Re: Launch config not updated in AEM
              kautuksahni Adobe Employee

              Can you please let us know how are you trying to run custom code?

              I have added an alert message in this example [1] and it is working fine for me.

              [1] https://helpx.adobe.com/experience-manager/using/aem_launch_adobeio_integration.html#Adobe LaunchCreateaproperty

               

              -Kautuk

              • 4. Re: Launch config not updated in AEM
                jamesa53173240 Level 1

                Hi kautuksahni

                 

                I tried running the following custom code:

                document.title="Loaded from Launch"

                 

                Using the Core extension:

                Screen Shot 2018-07-10 at 3.46.47 PM.png

                 

                And the rule is just simply:

                Screen Shot 2018-07-10 at 3.48.06 PM.png

                 

                When I look at the source of the Launch script, I can see the Rule that I have setup above and it references another JS file with the following code:

                _satellite.__registerScript('http://<AEM>:<PORT>/etc/clientlibs/dtm-reactor/<ENV-hash>/BLa1ad5f860f084972a62d7c090679951b/RC26 15a6f895d94e3e9e7d367a74d3c621-source.min.js', "document.title=\"Loaded from Launch\";");

                 

                However, the page is not executing the script as I cannot see the page title change.

                 

                Thanks,

                James

                • 5. Re: Launch config not updated in AEM
                  kautuksahni Adobe Employee

                  Hi,

                   

                  For me, basic alert function did worked. I am not very sure about how Launch let JS work inside the web page.

                  But, Changing the page title would totally defeat the purpose of SEO. Most crawlers aren't going to support javascript in the first place, so they will take whatever is in the element as the page title.

                   

                  Adobe Launch is to insert Tags into to web pages and retrieve the values the web-page. I am not very sure if using Launch for setting would be best practice. If you aim is to save some edited/appended value to the existing page title then that you can easily so by using Data Elements in Adobe Launch.

                   

                  Jantzen.Belliston Adobe Launch expert need to intervene here to clear some more doubts here.

                  -Kautuk

                  • 6. Re: Launch config not updated in AEM
                    Jantzen.Belliston Adobe Employee

                    I agree with Kautuk's answer. Launch isn't meant to be a CMS its more for deploying marketing pixels and tags. Changing items on the site like meta keywords, page titles, etc should be done by a system prior to the page code being generated. As Kautuk pointed out, many crawlers used for SEO don't support Javascript or will index the page before the script even has time to run and render the page as desired.

                    • 7. Re: Launch config not updated in AEM
                      jamesa53173240 Level 1

                      Hi guys,

                       

                      Thank you all for your input. The purpose of creating the rule that overwrites the document title was more to do with testing the capability and understand the limitation of using Launch than a business purpose - from my point of view, the custom code is just a piece of javascript to be run on the page and it should be executed.

                       

                      I've tried kautuksahni's alert and it did work as expected (by the way, awesome documentation, it helped me a lot  ) - so I guess there are some sort of mechanism that prevents certain javascript to be executed using Core extension then?

                       

                      Also, for the initial issue:

                      The libraryUri path was not referencing the latest version (points to libraryEntriesPrev rather than libraryEntries) in AEM after triggering the workflow to download from Launch until a 2nd workflow was triggered.

                      - Is this the normal behaviour?

                       

                      Thanks,

                      James