Question
375008155608
US
Last activity: 22 Nov 2021 16:07 EST
GenerateID Changed And Not Always Unique
At some point in 8.x, the behavior of GenerateID was changed. I am seeing somewhat random behavior. For a period of time, I was getting truly unique incremented values (ex: 1, 2, 3, 4). Later, I was seeing incremented values as follows (1001, 2001, 3001, 4001). Now, we are again seeing values starting as 1, 2, 3, 4. I don't know the reason for the change in behavior, and more concerning is that these are not generating as unique. The 1, 2, 3, 4 values that I am getting generated for my prefix today are causing work objects created today to be overwritten because the id is being reused. I have looked at the https://community.pega.com/knowledgebase/articles/whats-new-pega-platform/increase-performance-work-id-generation-83 article, and that does not explain this behaior.

I've also noticed that if I manually run the Work-.GenerateID activity, that if I pass it a brand new prefix (ex: "JR-") that creates a data instance in Data-UniqueID, and it is always setting the pyLastReservedID to a value of 1000. Meanwhile, as I call the activity over and over, I'm getting values of 1, 2, 3, 4 returned. I would like to understand where the returned value is coming from, as it no longer seems to be from pyLastReservedID. Maybe the new GenerateID activity/getUniqueID(string,string) function writes to a different table?