- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2024 11:49 AM
Hello All,
I have to requirement that to retrive all the stories from one instance and create / modify them in other instance.
Create : If stories does not exist
Modify : if stories does exist
Can you please help me how to create this ?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2024 02:17 PM
Hi David,
What you are looking to do is not a simple exercise. You may be able to find some help in the Integration Hub. Regardless, you are going into the world of REST messaging. Setting those transfers requires scripting on both instances. There are two scenarios that I can envision:
- The first is that when a story on the source instance is created or updated, a REST message gets sent to the destination instance. When that is received, the endpoint on the destination instance handles insertion or update.
- The other version is that on some schedule, the destination instance sends a message to the source instance basically saying send me everything that has been created or changed since "the last retrieval". When the source instance receives that request, it runs a query and structures the reply for a REST message. When that message arrives, the destination instance then iterates through the reply data to insert or update the data. as part of the process, a property "last time I asked" gets updated to the current date time so that you know what the start of the next request is.
One thing that you will need to capture on the destination side is the sys_id of the story on the source side since you have no control over the assignment of sys_ids and you definitely don't want to try using the same sys_id in both instances since you have no guarantee that the sys_id on the destination instance is not already in use. The source side sys_id lets you have a way to find existing data on the destination side.
Setting this up can take a good bit of coding. If you are not familiar with setting up these conversations, I'd suggest working with a support partner. That's what I did for my first one and it made all the difference. You can also look at the Javascript course that Chuck Tomasi set up a few years back as it has at least one module about this.
:{)
Helpful and Correct tags are appreciated and help others to find information faster
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2024 02:17 PM
Hi David,
What you are looking to do is not a simple exercise. You may be able to find some help in the Integration Hub. Regardless, you are going into the world of REST messaging. Setting those transfers requires scripting on both instances. There are two scenarios that I can envision:
- The first is that when a story on the source instance is created or updated, a REST message gets sent to the destination instance. When that is received, the endpoint on the destination instance handles insertion or update.
- The other version is that on some schedule, the destination instance sends a message to the source instance basically saying send me everything that has been created or changed since "the last retrieval". When the source instance receives that request, it runs a query and structures the reply for a REST message. When that message arrives, the destination instance then iterates through the reply data to insert or update the data. as part of the process, a property "last time I asked" gets updated to the current date time so that you know what the start of the next request is.
One thing that you will need to capture on the destination side is the sys_id of the story on the source side since you have no control over the assignment of sys_ids and you definitely don't want to try using the same sys_id in both instances since you have no guarantee that the sys_id on the destination instance is not already in use. The source side sys_id lets you have a way to find existing data on the destination side.
Setting this up can take a good bit of coding. If you are not familiar with setting up these conversations, I'd suggest working with a support partner. That's what I did for my first one and it made all the difference. You can also look at the Javascript course that Chuck Tomasi set up a few years back as it has at least one module about this.
:{)
Helpful and Correct tags are appreciated and help others to find information faster