0

I am analyzing TFS to review code for a project built in Powerbuilder. Below is how things are set up:

We connect to TFS repository from Powerbuilder using MSSCCI plugin. fyi, Powerbuilder bundles the objects and stores in pbl file(powerbuilder library). Everything is kind of encrypted in pbl. Perhaps TFS is unable to recognize the pbl so objects like windows, datawindows, structure are placed in TFS server repository.

Say we have a library name project.pbl which have window1, window2 etc. Now in TFS, we have folder same as library name - project and in that folder we have the objects window1 and window2. When we get the source from TFS, we have the folder copied to our local folder along with the objects.

Now my question is:

1.When we make change to any object in Powerbuilder and check in, how does TFS knows the changes since it does not have information about the library?

2.If I check out an object and make a change, the changes are not visible in object in TFS. It would be visible only after code is checked in. In this case, how can I submit the code for code review prior to check-in?

Is there any other approach which I can take for code review?

Thanks, Ashish

2 Answers2

0

1) via the PBG file. From a quick Google search:

When you add a target or an object (in a target that is not under source control) to source control, PowerBuilder creates a PBG file. A PBG file maps objects in a target to a particular PBL in a PowerScript or .NET target. One PBG file is created per PBL , so there can be multiple PBG files for these types of target.

2) Not sure what 'submit the code for code review' is but if you are using TFS to track the defects / work via workitems you can link any changed objects to the workitem during check in. In my experience you should have (at least) a Development branch and a Production branch. All changes are made to the Development branch. If the code review or testing reveals a problem with code, it goes back to the developer. If everything is okay, the changes are then merged into the production branch.

Matt Balent
  • 2,337
  • 2
  • 20
  • 23
  • "Code Review" is a process for when after a developer has completed the code feature in their private code branch, but needs the code to be reviewed by a team leader before it is merged into the main code branch (different branching methodologies have different names for this). Those code is reviewed for consistency, quality, or any other metric the team has put in place. It is a process built into TFS when using the Git repository. And since PBLs are a single binary file instead of several text files that cannot be parsed for review this makes it difficult or impossible to review. – Antebios Feb 11 '19 at 18:25
  • You review the methods added or changed by the developer from the object exports using the 'show differences' within the source code viewer. – Matt Balent Feb 11 '19 at 18:29
  • Thank you for reply. For code review, we check-in the code to the development branch which ultimately merges to Main Branch. The review is done after check-in. In case there are changes, again the developer needs to check out and make the changes. I wanted to use the Code Shelve technique which TFS provdes(see Code Review Process here https://blogs.msdn.microsoft.com/ivo_manolov/2010/11/29/performing-code-reviews-in-tfs-2010/) to avoid multiple check-in...Is it possible? – Ashish Ghildiyal Feb 13 '19 at 11:32
0

With TFS if you use the Git repository instead of TFVC and if you upgrade to PowerBuilder 2017 R3 then PowerBuilder will save the non-binary (text) version of your objects (e.g. SRD, SRW, etc.).