Version control software
- kilianvp
- Posts:443
- Joined: Fri Jan 16, 2015 10:29 am
Re: Version control software
thank you for the keywords hint!
- RudiKreiner
- Posts:198
- Joined: Mon May 16, 2011 2:10 pm
Re: Version control software
If alll developer have their own project environment (Win CC Project, and maybe PLCs or other equipment) where they work, then merge their results into the master repository, then that will work OK with GIT.
But during the startup of our machines, every developer needs to appy his changes to the same WinCC database and the same set of PLCs which are running our machine that is worth several million Euros.
Without a file locking mechanism the risk of conflicts is imminent, with potentially fatal effects on the machine.
Here a simple example:
Datapoint X contains the elements A and B.
Developer 1 adds element C to X then updates the datapoint type in the WinCC database.
Developer 2 adds element D to X then updates the datapoint type in the WinCC database.
Then developer 1 suddenly sees that X contains A, B and D, but his element C is gone!
Does anyone see any way to avoid that situation?
But during the startup of our machines, every developer needs to appy his changes to the same WinCC database and the same set of PLCs which are running our machine that is worth several million Euros.
Without a file locking mechanism the risk of conflicts is imminent, with potentially fatal effects on the machine.
Here a simple example:
Datapoint X contains the elements A and B.
Developer 1 adds element C to X then updates the datapoint type in the WinCC database.
Developer 2 adds element D to X then updates the datapoint type in the WinCC database.
Then developer 1 suddenly sees that X contains A, B and D, but his element C is gone!
Does anyone see any way to avoid that situation?
- kilianvp
- Posts:443
- Joined: Fri Jan 16, 2015 10:29 am
Re: Version control software
run data on a extra server and everybody use this data
for panels there is no good solution
for panels there is no good solution
- flindecke
- Posts:69
- Joined: Wed Jun 24, 2015 1:54 pm
Re: Version control software
Perhaps the following idea would prevent the problem modifying binary database and i also hope, that i understood your problem.
The idea is using ASCII Import, Export mechanism of WINCC OA. Every developer has to modify the ASCII Export file, when a new datapoint and type has to be added (or an existing one has to be modified).
On startup this file is imported and the relevant changes will be executed by WINCC OA ASCII Manager.
There exists only this single ASCII file.
Perhaps it makes sense to create a single ASCII file for every module or feature. The problem arises on ASCII files where several responsible developers. Solution: They have to communicate with each other!
Proposal for working with each other using branches:
Developer 1 is working on Branch Devel1, Developer 2 is working on Branch Devel2
A Stage branch is used for merging Devel1 and Devel2 branches and to be used for testing.
When Stage branch is accepted, all changes will be pushed to Production branch.
Machine always uses Production branch code.
When i - as Developer 2 - am working on a new feature i will merge any changes from stage to my branch Devel2 or better Devel2_FeatureXY branch. So i will have every changes of current Stage branch.
Before pushing my Devel2_FeatureXY branch to Stage, i have to merge any changes from stage into my branch and i am responsible that everything is still working.
There exists a minimal gap when Developer 1 removes my datapoints, but these failure can be found in stage branch.
Importing the ASCII files can be automated by a control script. E.g. it imports all scripts found in a specific directory using the file name order.
Note, that there exists a problem when data points or types have to be deleted. There exists no protocol for defining "these datatype or datapoint has to be deleted" by ASCII Manager. But nevertheless this is another problem.
Also i - as Developer 2 - are always a little bit behind of stage branch. But whenever Developer 1 pushes her changes into stage i will be able to pull theses changes and merge them into my working branch. So this is only a problem of "communication".
Conclusion:
- Every developer is using it's own WINCC OA database
- Use WINCC OA ASCII Manager Import and Export files
- Automate import of these files
- Changes in database have to be reflected in ASCII files (which are under version control)
- Datapoints and datatypes belonging to a story, feature, module or whatever software organization structure you are using and there exists a person (or a team) which is responsible for these ASCII files.
The idea is using ASCII Import, Export mechanism of WINCC OA. Every developer has to modify the ASCII Export file, when a new datapoint and type has to be added (or an existing one has to be modified).
On startup this file is imported and the relevant changes will be executed by WINCC OA ASCII Manager.
There exists only this single ASCII file.
Perhaps it makes sense to create a single ASCII file for every module or feature. The problem arises on ASCII files where several responsible developers. Solution: They have to communicate with each other!
Proposal for working with each other using branches:
Developer 1 is working on Branch Devel1, Developer 2 is working on Branch Devel2
A Stage branch is used for merging Devel1 and Devel2 branches and to be used for testing.
When Stage branch is accepted, all changes will be pushed to Production branch.
Machine always uses Production branch code.
When i - as Developer 2 - am working on a new feature i will merge any changes from stage to my branch Devel2 or better Devel2_FeatureXY branch. So i will have every changes of current Stage branch.
Before pushing my Devel2_FeatureXY branch to Stage, i have to merge any changes from stage into my branch and i am responsible that everything is still working.
There exists a minimal gap when Developer 1 removes my datapoints, but these failure can be found in stage branch.
Code: Select all
Devel1 --->
|---> Stage --> Production
Devel_FeatureXY ---> Devel2 --->
Note, that there exists a problem when data points or types have to be deleted. There exists no protocol for defining "these datatype or datapoint has to be deleted" by ASCII Manager. But nevertheless this is another problem.
Also i - as Developer 2 - are always a little bit behind of stage branch. But whenever Developer 1 pushes her changes into stage i will be able to pull theses changes and merge them into my working branch. So this is only a problem of "communication".
Conclusion:
- Every developer is using it's own WINCC OA database
- Use WINCC OA ASCII Manager Import and Export files
- Automate import of these files
- Changes in database have to be reflected in ASCII files (which are under version control)
- Datapoints and datatypes belonging to a story, feature, module or whatever software organization structure you are using and there exists a person (or a team) which is responsible for these ASCII files.
- RudiKreiner
- Posts:198
- Joined: Mon May 16, 2011 2:10 pm
Re: Version control software
Thanks for your comments.
As long as each developer has his own database, the procedure described by Frank will work well.
But when we are starting up our machines, they are run by only one WinCC project and one set of PLCs. From this point on at the lastest, parallel development is a no-no but without a repository locking mechanism I see no safe way to prevent it.
As long as each developer has his own database, the procedure described by Frank will work well.
But when we are starting up our machines, they are run by only one WinCC project and one set of PLCs. From this point on at the lastest, parallel development is a no-no but without a repository locking mechanism I see no safe way to prevent it.
- leoknipp
- Posts:2928
- Joined: Tue Aug 24, 2010 7:28 pm
Re: Version control software
Hello,
if several people should modify the data model for one project the easiest solution is to define server and client machines.
At the server machine the data/event-manager is started. On the client machines only a UI is running.
Changes to the database can be made online and every other use connected to the same server will see the changes immediately.
At the repository you can store an ASCII file or the database itself. To get the current state of the database or to create the ASCII files the WinCC OA online backup can be used.
If panel/script is changed the file is stored at the client compuiter. There it can be tested and it the changes are okay an update of the repository is made.
Best Regards
Leopold Knipp
Senior Support Specialist
if several people should modify the data model for one project the easiest solution is to define server and client machines.
At the server machine the data/event-manager is started. On the client machines only a UI is running.
Changes to the database can be made online and every other use connected to the same server will see the changes immediately.
At the repository you can store an ASCII file or the database itself. To get the current state of the database or to create the ASCII files the WinCC OA online backup can be used.
If panel/script is changed the file is stored at the client compuiter. There it can be tested and it the changes are okay an update of the repository is made.
Best Regards
Leopold Knipp
Senior Support Specialist