 commerce.info                                      |  3 +
 includes/commerce.controller.inc                   | 18 ++++-
 .../handlers/commerce_handler_field_field.inc      | 88 ++++++++++++++++++++++
 ...commerce_price_handler_field_commerce_price.inc |  2 +-
 4 files changed, 109 insertions(+), 2 deletions(-)

diff --git a/commerce.info b/commerce.info
index a9282bf..070fdc1 100644
--- a/commerce.info
+++ b/commerce.info
@@ -11,3 +11,6 @@ files[] = tests/commerce_base.test
 
 ; Central Entity Controller.
 files[] = includes/commerce.controller.inc
+
+; Views handlers
+files[] = includes/views/handlers/commerce_handler_field_field.inc
diff --git a/includes/commerce.controller.inc b/includes/commerce.controller.inc
index 4e6249c..26a80e3 100644
--- a/includes/commerce.controller.inc
+++ b/includes/commerce.controller.inc
@@ -21,6 +21,22 @@ class DrupalCommerceEntityController extends DrupalDefaultEntityController imple
   protected $lockedEntities = array();
 
   /**
+   * Enable this controller to lock entities that have 'pessimistic' locking
+   * mode set in self::entityInfo['locking mode'].
+   *
+   * @see self::buildQuery()
+   */
+  protected $pessimisticLocking = TRUE;
+
+  /**
+   * Prevent this controller from locking the entities that it loads.
+   */
+  public function preventLocking() {
+    $this->pessimisticLocking = FALSE;
+    return $this;
+  }
+
+  /**
    * Override of DrupalDefaultEntityController::buildQuery().
    *
    * Handle pessimistic locking.
@@ -28,7 +44,7 @@ class DrupalCommerceEntityController extends DrupalDefaultEntityController imple
   protected function buildQuery($ids, $conditions = array(), $revision_id = FALSE) {
     $query = parent::buildQuery($ids, $conditions, $revision_id);
 
-    if (isset($this->entityInfo['locking mode']) && $this->entityInfo['locking mode'] == 'pessimistic') {
+    if ($this->pessimisticLocking && isset($this->entityInfo['locking mode']) && $this->entityInfo['locking mode'] == 'pessimistic') {
       // In pessimistic locking mode, we issue the load query with a FOR UPDATE
       // clause. This will block all other load queries to the loaded objects
       // but requires us to start a transaction.
diff --git a/includes/views/handlers/commerce_handler_field_field.inc b/includes/views/handlers/commerce_handler_field_field.inc
new file mode 100644
index 0000000..cfb9327
--- /dev/null
+++ b/includes/views/handlers/commerce_handler_field_field.inc
@@ -0,0 +1,88 @@
+<?php
+
+/**
+ * @file
+ * Contains the base Field API field handler of the Commerce's entities.
+ */
+
+/**
+ * An extension of the default Views field handler that prevents locking
+ * entities with pessimistic locking.
+ */
+class commerce_handler_field_field extends views_handler_field_field {
+  /**
+   * Overrides views_handler_field_field::post_execute().
+   *
+   * Load commerce entities without locking them.
+   */
+  function post_execute(&$values) {
+    // Borrowed from views_handler_field_field::post_execute(), with the slight
+    // difference that we prevent locking here.
+
+    if (!empty($values)) {
+      // Divide the entity ids by entity type, so they can be loaded in bulk.
+      $entities_by_type = array();
+      $revisions_by_type = array();
+      foreach ($values as $key => $object) {
+        if (isset($this->aliases['entity_type']) && isset($object->{$this->aliases['entity_type']}) && isset($object->{$this->field_alias}) && !isset($values[$key]->_field_data[$this->field_alias])) {
+          $entity_type = $object->{$this->aliases['entity_type']};
+          if (empty($this->definition['is revision'])) {
+            $entity_id = $object->{$this->field_alias};
+            $entities_by_type[$entity_type][$key] = $entity_id;
+          }
+          else {
+            $revision_id = $object->{$this->field_alias};
+            $entity_id = $object->{$this->aliases['entity_id']};
+            $entities_by_type[$entity_type][$key] = array($entity_id, $revision_id);
+          }
+        }
+      }
+
+      // Load the entities.
+      foreach ($entities_by_type as $entity_type => $entity_ids) {
+        $entity_info = entity_get_info($entity_type);
+        if (empty($this->definition['is revision'])) {
+          $controller = entity_get_controller($entity_type);
+          if (method_exists($controller, 'preventLocking')) {
+            $controller->preventLocking();
+          }
+          $entities = $controller->load($entity_ids);
+          $keys = $entity_ids;
+        }
+        else {
+          // Revisions can't be loaded multiple, so we have to load them
+          // one by one.
+          $entities = array();
+          $keys = array();
+          foreach ($entity_ids as $key => $combined) {
+            list($entity_id, $revision_id) = $combined;
+            $controller = entity_get_controller($entity_type);
+            if (method_exists($controller, 'preventLocking')) {
+              $controller->preventLocking();
+            }
+            $entity = $controller->load(array($entity_id), array($entity_info['entity keys']['revision'] => $revision_id));
+            if ($entity) {
+              $entities[$revision_id] = array_shift($entity);
+              $keys[$key] = $revision_id;
+            }
+          }
+        }
+
+        foreach ($keys as $key => $entity_id) {
+          // If this is a revision, load the revision instead.
+          if (isset($entities[$entity_id])) {
+            $values[$key]->_field_data[$this->field_alias] = array(
+              'entity_type' => $entity_type,
+              'entity' => $entities[$entity_id],
+            );
+          }
+        }
+      }
+
+      // Now, transfer the data back into the resultset so it can be easily used.
+      foreach ($values as $row_id => &$value) {
+        $value->{'field_' . $this->options['id']} = $this->set_items($value, $row_id);
+      }
+    }
+  }
+}
diff --git a/modules/price/includes/views/handlers/commerce_price_handler_field_commerce_price.inc b/modules/price/includes/views/handlers/commerce_price_handler_field_commerce_price.inc
index 919b655..27fb176 100644
--- a/modules/price/includes/views/handlers/commerce_price_handler_field_commerce_price.inc
+++ b/modules/price/includes/views/handlers/commerce_price_handler_field_commerce_price.inc
@@ -4,7 +4,7 @@
  * An extension of the default Views field handler that supports aggregating
  * price fields.
  */
-class commerce_price_handler_field_commerce_price extends views_handler_field_field {
+class commerce_price_handler_field_commerce_price extends commerce_handler_field_field {
   function get_value($values, $field = NULL) {
     // If this field has aggregation enabled...
     if (!empty($this->group_fields)) {
