Deployment of K2 Process with SmartObjects to different environments

  • 15 September 2015
  • 5 replies
  • 0 views

Badge +1

We have a process we've developed in our Development environment. This process includes SmartObjects created by the SmartObject Service Tester using Oracle Service Instances instantiated in the Development environment.

 

In our Test environment, we instantiated the same Service Instances, and made sure the GUIDs matched between the service instances in the Development and Test environments.

 

We then (and here is where I think we went wrong) created the SmartObjects in the Test Environment using the Service Tester.

 

We then deployed the process to the Test environment. Deployment went fine... but when we try to run the process, we get "SmartObject with GUID ... not found" errors.

 

Should we have instead exported the Smartobjects in Dev, then imported those same SmartObjects in Test?

 

The Service Instance GUIDs match between Dev and Test, but the SmartObject GUIDs do not... but I thought having the Service Instance GUIDS match would be enough.


5 replies

Userlevel 1
Badge +8

Hi MAltarriba

 

Yes, the easiest path would have been to package all the smartobjects (as part of your solution) in dev and deploy them to test. You did the right thing in giving your ServiceInstance the same GUID in dev and test - this will mean that P&D will pick up the correct service instance automatically. However by creating the SmartObjects in test using the SmartObject tester it has given them different GUIDS (although you could have copied the dev guid when creating).

 

If its not too late I suggest deleting all of the smartobjects you created in test and re-deploying from dev.

Badge +1

Thanks!

 

Am I correct in assuming I can export the smartobjects from dev using the service tester, then import them to the Test environment?

Userlevel 5
Badge +18

Yes, you should be able to use the Smartobject Service Tester Tool to Export Smartobjects/Imports Smartobjects between environment.


 


It will save the smartobject definition in a .publish file and maintain the Smartobject GUID.


 


Alternative if you had created K2 Studio/K2 for Visual Studio Smartobject (.sodx files), you can also point the designer/environment library to the destination environment and deploy it that way; that would also maintain the Smartobject GUID.

Badge +2

Hi MAltarriba,

 

You may want to check the K2 Package and Deployment for your deployment. It will be easier for you to deploy from dev, staging to production.

 

John

Badge +4

Hi Maltarriba,

From what I read one mistake you also made was on the SMO GUID.

There is a way to "hack" this to work but that would mean altering the K2 database(Only 2 tables) but this will be not supported.

So as per previous suggestions, rather use P&D to accomplish the movement of the solution between environments, P&D was designed specifrically for SmartForms but it works great with non SmartForm solutions as well, it is also straight forward and simple to use.

Note - On Deployment to another environment always(if the service exists as in your case) select to use existing instance(Right click on the service instance)

Regards
Pieter

Reply