Component purl vs purlCoordinates #2330
-
I was looking in the code to maybe fix some issues connected to the ALL-operator in policies, which led me to (among others) #1925. I though this was maybe a good starting point, but now I do have some questions regarding the fields Now, my first question would be: is this correct, or are there cases where this is not valid? If so, then #1925 is indeed a valid issue and can be easily fixed. If not, then the question remains, if there is some valid point to #1925 and if and when 2 Viollations should actually be added to the list. My second question arose when looking in the class I'm hoping to get some answers, preferably after a little discussion, so I can 'get my hands dirty' and dive in. Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 9 replies
-
Purl does two things. It can identify a component, and it can locate a component. Location, if not the default, is handled with qualifiers. This is the equivalent of a URL querystring. purlCordinates if the first part of the purl containing the ecosystem, optional namespace, name, and version. It does not include any qualifiers. The purpose for having both is to speed up database queries. If I was querying the db using a components purl identity, I can perform an exact match on purlCoordinates which is an indexed field. If I only had a single purl field, DT would have to perform a full table scan when performing the same query, which would negatively impact performance in a big way. |
Beta Was this translation helpful? Give feedback.
Purl does two things. It can identify a component, and it can locate a component. Location, if not the default, is handled with qualifiers. This is the equivalent of a URL querystring. purlCordinates if the first part of the purl containing the ecosystem, optional namespace, name, and version. It does not include any qualifiers. The purpose for having both is to speed up database queries. If I was querying the db using a components purl identity, I can perform an exact match on purlCoordinates which is an indexed field. If I only had a single purl field, DT would have to perform a full table scan when performing the same query, which would negatively impact performance in a big way.