1. Vipin Dwivedi
  2. PowerBuilder
  3. Monday, 15 October 2018 21:43 PM UTC

Hello Appeon Team,

Is there any change in Incremental build process in PB2017R3. I am trying to run the Incremental build by putting some objects into PBL. After build, It is crashing the application. Is it ok to build PBD using Incremental build option?

 

Regards,

Vipin

Accepted Answer
mike S Accepted Answer Pending Moderation
  1. Thursday, 16 June 2022 23:18 PM UTC
  2. PowerBuilder
  3. # Permalink
agreed. do an incremental build for 1 or small group of pbds, using orcascript or powergen, and usually only for patch type changes. i never use the IDE incremental build in the IDE.
Comment
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Thursday, 17 June 2021 14:18 PM UTC
  2. PowerBuilder
  3. # 1

IMHO, incremental builds have never been 100% and I've been always doing Full Builds. I've even noticed that sometimes Full builds are faster than Incremental ones, so I really don't see the point of doing incremental builds. (unless you want to generate a single PBD).

 

Comment
There are no comments made yet.
Vipin Dwivedi Accepted Answer Pending Moderation
  1. Wednesday, 10 March 2021 16:36 PM UTC
  2. PowerBuilder
  3. # 2

Hey Mike,

Do you have any link of video for that discussion?

 

Regards... Vipin

Comment
  1. mike S
  2. Wednesday, 10 March 2021 18:23 PM UTC
there weren't any recordings of those sessions at that conference, it was prior to elevate.
  1. Helpful
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Tuesday, 16 October 2018 15:40 PM UTC
  2. PowerBuilder
  3. # 3

also, i disagree with chris about the patch builds even with ancestor objects. 

There are things to know and be careful of, but you can definitely do patches the way you are talking about.   I had a session a few years ago at an elevate event were we talked about this in a forum type of session.  Most of the attendees at the session did this same process and many of us got some great pointers from other attendees.  Just that 20 minutes of that one session made that whole elevate worth while.

Comment
  1. Vipin Dwivedi
  2. Thursday, 17 June 2021 18:21 PM UTC
For #1, do you have any document. Let me tell you the process we follow in our company.

On all the dealers we release application every quarterly or bi quarterly depends on schedule. In this release give provide full build PBDS files.... through orca and pbccompiler (pbc170.exe).

After release, if we get any defects from dealers, we fix and release the patch to all or some dealers depends on the behavior of the defect(Mostly on all dealers). In the patch process, we copy all the objects during that patch fix to one library called patch.pbl, run the incremental build from PB IDE make patch.pbd and deploy it to the dealers. Here we keep patch.pbd on top in the library list so that patch fix can take effect.

Now let me know if we need to change this process and you have any better idea for patch delivery.



FYI - Last week we release one patch where one process is failing with error Null object reference at line ###. when we checked that line number there it is written

long ll_row

Datastore lds_data

lds_data = Create using n_ds //Inherited from PFC

lds_data.Dataobject = d_emp_list

lds_data.SettransObject(SQLCA)

ll_row = lds_data.InsertRow()

lds_data.Object.Emp_no[ll_row] = ll_emp_no //lds_data is datastore. //Failing on this line with Null Object Reference...



We added log to verify the lds_data object if it is valid or not which is returning true.

We checked the value of ll_row which is coming 1. log gives ll_emp_no value as well so don't know why it is failing. This datasource being used other places as well and they are running fine.



Thanks,

Vipin
  1. Helpful
  1. mike S
  2. Thursday, 17 June 2021 18:48 PM UTC
missing quotes: lds_data.Dataobject = 'd_emp_list'

-----------------

I 100% recommend using orcascript to build your patch over incremental. you create an orcascript file, something like this:

build.dat:



start session

file copy "patch.pbl" "build\patch.pbl"

set liblist "build\patch.pbl; <C:\yourlibrary1.pbl; C:\yourlibrary2.pbl>"

set application "C:\yourmain.pbl" "yourappname"

build library "build\patch.pbl" "" pbd

end session



if that file is named BUILD.dat then write a batch file that does this:

build.bat:



OrcaScr170 build.dat >build.log

copy "build\patch.pbd" "patch.pbd"



note that I copy the patch.pbd in the batch file rather than in the orcascript. I do this because i use dropbox/box type of application as a fileserver and orcascript copy tries to use a full lock during the copy.







  1. Helpful
  1. Vipin Dwivedi
  2. Friday, 18 June 2021 21:54 PM UTC
It was type for dataobject. I have quote in code when assigning dataobject.
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Tuesday, 16 October 2018 14:17 PM UTC
  2. PowerBuilder
  3. # 4

Hi Vipin;

   This has always been a "risky" approach when rebuilding one PBD on one library. Even in older PB releases from SAP, Sybase or even PowerSoft. Its not too bad when rebuilding a library with only "concrete" (working) level objects. However, its almost a "death sentence" (as you might be finding out) when rebuilding one PBD that contains either "Base" or "Extension" level ancestor object classes.

   The problem starts or gets really accentuated when you add or remove instance variables. Internally in PB's P-Code a variable is referenced via a base address plus its offset into the object's data section. When you change that by changing the instance pool, you can inadvertently change the offset addresses of many other instance variables at the same time.

   If you do not perform a "Full Build" and then redeploy your app with all your PBD's, there will be various "Concrete" level classes that have the wrong base address + offset. This will certainly lead into a GPF. So my suggestion would be to never trust one only PBD generation and instead, always perform an incremental build on all PBD's - and if in doubt - a full build (especially before a production release).

HTH

Regards ... Chris

Comment
  1. Chris Pollach @Appeon
  2. Tuesday, 16 October 2018 16:20 PM UTC
Yes, I had that happen with one of my government clients just last year. They had been doing this technique for almost 10 years and it finally caught up with them. Of course, they hardly ever patched - they mainly did a full maintenance release. So it took a long time for them to get into this situation. the odd patch was of course a simple DWO, concrete class, etc - not a high level ancestor.



I knew right away as soon as they said their App was GPF'ing after releasing the PBD that this was the issue. Normally, they were using full automated testing tools to do regression testing even on a patched App's PBD. So any instability was caught that way many times and a full rebuild would automatically have been done. This last time though, they created the patched PBD and did not do any automated regression testing and just slapped it into production "as is" - and that my friends, is when the whole instability started. A full build / release and they were back in business.

  1. Helpful
  1. Vipin Dwivedi
  2. Wednesday, 17 October 2018 16:32 PM UTC
Hi Chris,

One thing I found strange is that after incremental build of upatch library, when I deployed this pbd file with 12.5 runtime dlls (I had one folder with all the latest pbds and exe along with 12.5 runtime dlls), it ran without any issue. Very strange.

Do you have any idea what would be the reason? I know I am asking stupid question but I am not sure why this is happening.

Regards... Vipin
  1. Helpful
  1. Chris Pollach @Appeon
  2. Wednesday, 17 October 2018 16:35 PM UTC
That is weird IMHO ... I have no idea why! :-(
  1. Helpful
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Tuesday, 16 October 2018 14:08 PM UTC
  2. PowerBuilder
  3. # 5

if an object that was changed and is being rebuilt is called as by another object then you may need to recompile that other object as well.  that typically happens when you add a function/event, change parameters, or add instance variables to the rebuilt object.

 

Comment
  1. Chris Pollach @Appeon
  2. Tuesday, 16 October 2018 15:45 PM UTC
Hi Vipin;

There were NO Changes to the incremental build process in any Appeon PB release thus far. Since this process was built upon the PB12.6 code-line that SAP handed over to Appeon. I would say PB 12.x used the same process. as well.

HTH

Regards ... Chris
  1. Helpful
  1. Vipin Dwivedi
  2. Tuesday, 16 October 2018 15:48 PM UTC
Hi Mike,



Can you tell me the steps you use in ORCA script? That would be a great help. Meanwhile, I will try to go with full build one time and then will try to run incremental build then will see if that resolve the problem or not.



Vipin
  1. Helpful
  1. Vipin Dwivedi
  2. Tuesday, 16 October 2018 16:43 PM UTC
One thing I have noticed which may not be related to this thread but thought to share and get the knowledge/approach is

In 2017R3 when we add any new objects in any pbl, it does not update the PBG as now R3 does not support PBG so new objects will not be listed in that PBG file. So when we go to another machine and try to refresh the workspace, will I get the new objects in that machine's PBL as I don't see those objects in the PBL? What would be the approach to get the new objects in that PBL.

One thing I would like to mention that in our Github repository, we are not storing the PBLs. Every developer has his own PBLs and the same we are doing on our dedicated build server( We have one dedicated Development server where we build our project)



Let me know if I am not clear.



Regards,

Vipin
  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.