Migrating the Scoped Application to another PDI for developemnt.

NehaSNOW
Tera Guru

Hi Members,

 

I have to instance say PDI 1 and PDI 2. I have developed an Scoped Application in PDI 1 which I want to migrate to PDI 2 so that the development can be continued on both the instances. 

Please share the step by step process to fulfill this requirement.

 

Release - Xanadu.

 

Thanks,

Neha

6 REPLIES 6

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @NehaSNOW 

 

https://www.servicenow.com/community/developer-forum/scoped-app-transfer-from-one-pdi-to-another/m-p...

https://www.servicenow.com/community/developer-forum/what-is-best-practice-to-move-a-scoped-applicat...

 

These 2 links will be heplful.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

@Dr Atul G- LNG Thanks for sharing the links but I have already gone through these links. I couldn't find any answer fulfilling my requirement. Also, since I am new to ServiceNow so looking for step by step process to fulfill my requirement i.e. Migrating the Scoped Application on the another instance say PDI 2 and continuing the development on both the instances i.e. PDI 1 and PDI 2.

Hi @NehaSNOW 

 

Greetings!!

 

Please don't take me wrong, if you say need step-by-step, I can / you can find out on ChatGPT and get the steps that are one way. 2nd, you start and let us know where you are stuck, and what error you are getting so that the community can support you.  Ld you start with 1 step, the community will help you in the next steps.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Dr Atul G- LNG
Tera Patron
Tera Patron

I never worked practically on this, but here are some ChatGPT steps.. again it might be 100% correct or 50 -50.

 

Migrating a scoped application from one instance to another (like from PDI 1 to PDI 2) while continuing development on both instances is a bit tricky, but it can be managed effectively with a structured approach.

Here’s a general process you can follow:

1. Prepare the Scoped Application for Migration

  • Export the Application from PDI 1: You can export your scoped application using Application Export from the ServiceNow platform. Make sure to export it with the necessary dependencies.
    • Go to System Applications > Studio in PDI 1.
    • From the Studio interface, use the Export option to create a scoped application export package (.xml file).
    • Make sure you’re exporting the entire application along with all its records, such as tables, scripts, UI actions, business rules, and other components.
  • Identify Dependencies: Identify and document any dependencies your scoped app may have on other applications or configurations in the source instance. This helps ensure the application functions correctly in the new environment.

2. Import the Application into PDI 2

  • Import the Exported Package to PDI 2: In PDI 2, you can import the .xml package you exported from PDI 1.
    • Navigate to System Applications > Studio.
    • Click Create Application and choose Import.
    • Select the .xml file to import the scoped application.
  • Verify and Test: Once the application is imported, you should test the application thoroughly to ensure everything migrated correctly and that the functionality is the same as in PDI 1. You may need to adjust some configurations due to environmental differences between the instances.

3. Continue Development on Both Instances

To continue developing on both instances (PDI 1 and PDI 2), you can implement one of these strategies:

  • Work in Parallel: Make sure that you're keeping track of changes made in both instances. You might need to have a version control process to track the changes in both environments. This can be manual or facilitated by tools like Git if you’re using it in your development workflow.

  • Synchronize Changes: If changes are made in PDI 1 after the migration, you would need to export the updated scoped app and import it into PDI 2 again. Similarly, any new development in PDI 2 should be exported and brought back to PDI 1 if needed.

  • Version Control: If possible, using an external version control system like Git to track changes might be beneficial, as it allows you to keep track of which version of the scoped app exists in both instances and helps synchronize changes across instances.

4. Managing Environment-Specific Configurations

Both instances may have different configurations, such as data in tables, integrations, or external connections. Ensure that environment-specific configurations are updated when deploying between PDI 1 and PDI 2, especially if those configurations differ between the two.

  • Adjust Configuration: If your scoped application relies on specific data or configurations, consider exporting and importing configuration records (like system properties, integration endpoints, etc.) from PDI 1 to PDI 2 to maintain consistency.

  • Avoid Conflicts: Ensure that no conflicting changes are made simultaneously to critical components, like scripts or data models, that could break your application’s functionality when syncing.

5. Handle Ongoing Changes

  • As you make changes in both instances, you may want to consider a workflow for pushing changes back and forth. This could be done manually by exporting and importing, or, if feasible, use ServiceNow's Application Repository or Source Control for better version management.

  • Collaboration Tools: Consider using Git integration in ServiceNow for easier collaboration between instances. This can help reduce the complexity of managing changes across multiple instances.

6. Final Deployment

After all changes and testing are done, you can deploy the scoped application from PDI 2 back to your production environment, or vice versa, depending on your use case.


Key Considerations:

  • Version Control: If you're frequently working between instances, consider integrating Git for better tracking of changes.
  • Environment-Specific Changes: Ensure you handle environment-specific data and configuration differences carefully.
  • Testing: Thoroughly test the migrated application in PDI 2 to ensure no functionality is broken.

By following these steps, you should be able to continue development on both instances (PDI 1 and PDI 2) without too much disruption, ensuring both environments stay in sync.

 

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************