cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X

Source Control keeps deleted Things

ehalvordsson
12-Amethyst

Source Control keeps deleted Things

We have set up a source control repository in Thingworx and have a service+scheduler which exports the complete solution on a regular basis. Our intention is to use GIT to backup this directory.

 

However, when we delete a Thing in Thingworx, the corresponding XML file remains in the file repository. So if we need to recover the solution, Thingworx will re-import the complete solution, including deleted Things.

 

How is the source control functionality supposed to work? GIT will keep track of the deleted objects anyway so we would like the backup to contain the current entities only.

 

Did anyone find a work-around or are we using the functionality in the wrong way?

 

Many thanks

Best regards Erik

 

 

2 REPLIES 2

Hi @ehalvordsson may be you have already checked but just to reconfirm re-importing the entities from the Source Control Entities you can check/uncheck the entities that you are looking to import back by checking the difference , like so : 

 

02-07-2018 10-10-23.jpg

 

For the entities that I have deleted from the ThingWorx but still exist in the ThingWorx Source Control Repository shows like this, i.e. as "New" to ignore this entity from import it need to be unchecked.

 

Does this not help in your use case?

02-07-2018 10-10-23.jpg

Hi @supandey

Thanks for the reply, that´s a very useful feature, specially when migrating between development and production servers.

 

We are planning this as a kind of disaster recovery option so everything will be "new" when we try to import into an empty Thingworx server. Basically we want GIT to keep track of changes and the problem is that since the export function does not delete deleted Things, GIT will not see any change on those objects. Ideally I think the export service should remove deleted Things on the export location.

Top Tags