jerimorris / force-dot-com-esapi

Automatically exported from code.google.com/p/force-dot-com-esapi
0 stars 0 forks source link

insertAsUser/updateAsUser may hit governor limits #3

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Due to the use of the "fields" member variable in insertAsUser and 
updateAsUser we limit the usage of these functions to 10 calls in a single 
execution call.

Adding the insertAsUser and updateAsUser array functions, probably solved 
this problem partially, because for array operations the library will only 
call fields once. This means that only if you call these functions over 
ten times it will hit the governor limit.

In addition we are going to introduce insertAsUser and updateAsUser 
functions that will accept Schema.SObjectField[]. For these functions we 
will not use the fields member variable at all. If you have an issue with 
the limits you will be able to use these functions instead.

If anyone is still having issues with limit because of these functions, 
please add a comment with a use case and we can reconsider the priority 
for this issue.

Original issue reported on code.google.com by apex.es...@gmail.com on 2 Jun 2010 at 12:05

GoogleCodeExporter commented 8 years ago
Added insertAsUser and updateAsUser functions that accept a list of fields to
set/update as Schema.SObjectField instead of as strings. This also avoids using
the sObject.fields member variable and thus helps to further avoid hiting the 
fields 
limit.

Original comment by apex.es...@gmail.com on 3 Jun 2010 at 2:22

GoogleCodeExporter commented 8 years ago
This issue was closed by revision r47.

Original comment by apex.es...@gmail.com on 10 Nov 2011 at 1:27