Tabnine Logo
ConcurrencyFailureException.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
org.springframework.dao.ConcurrencyFailureException
constructor

Best Java code snippets using org.springframework.dao.ConcurrencyFailureException.<init> (Showing top 20 results out of 315)

origin: spring-projects/spring-framework

return new ConcurrencyFailureException(buildMessage(task, sql, ex), ex);
origin: spring-projects/spring-framework

return new ConcurrencyFailureException(buildMessage(task, sql, ex), ex);
origin: alibaba/cobarclient

private void fillResultListWithFutureResults(List<Future<Object>> futures,
                       List<Object> resultList) {
  for (Future<Object> future : futures) {
    try {
      resultList.add(future.get());
    } catch (InterruptedException e) {
      throw new ConcurrencyFailureException(
          "interrupted when processing data access request in concurrency", e);
    } catch (ExecutionException e) {
      throw new ConcurrencyFailureException("something goes wrong in processing", e);
    }
  }
}
origin: org.alfresco/alfresco-repository

@Override
public void updateAclChangeSet(Long aclChangeSetEntityId, long commitTimeMs)
{
  int updated = updateChangeSetEntity(aclChangeSetEntityId, commitTimeMs);
  if (updated != 1)
  {
    throw new ConcurrencyFailureException("Update by ID should delete exactly 1: " + aclChangeSetEntityId);
  }
}
origin: org.alfresco/alfresco-repository

@Override
protected ReadableByteChannel getDirectReadableChannel() throws ContentIOException
{
  // ALF-17708: If we got the contentdata from the transactional cache, there's a chance that eager cleaning can
  // remove the content from under our feet
  throw new ConcurrencyFailureException(getContentUrl() + " no longer exists");
}
origin: Alfresco/alfresco-repository

@Override
protected ReadableByteChannel getDirectReadableChannel() throws ContentIOException
{
  // ALF-17708: If we got the contentdata from the transactional cache, there's a chance that eager cleaning can
  // remove the content from under our feet
  throw new ConcurrencyFailureException(getContentUrl() + " no longer exists");
}
origin: Alfresco/alfresco-repository

@Override
public void updateAclChangeSet(Long aclChangeSetEntityId, long commitTimeMs)
{
  int updated = updateChangeSetEntity(aclChangeSetEntityId, commitTimeMs);
  if (updated != 1)
  {
    throw new ConcurrencyFailureException("Update by ID should delete exactly 1: " + aclChangeSetEntityId);
  }
}
origin: org.alfresco/alfresco-repository

@Override
public void setNodeAssocIndex(Long id, int assocIndex)
{
  int updated = updateNodeAssoc(id, assocIndex);
  if (updated != 1)
  {
    throw new ConcurrencyFailureException("Expected to update exactly one row: " + id);
  }
}
origin: Alfresco/alfresco-repository

@Override
public void setNodeAssocIndex(Long id, int assocIndex)
{
  int updated = updateNodeAssoc(id, assocIndex);
  if (updated != 1)
  {
    throw new ConcurrencyFailureException("Expected to update exactly one row: " + id);
  }
}
origin: org.alfresco/alfresco-repository

@Override
public void deleteTenant(String tenantDomain)
{
  ParameterCheck.mandatoryString("tenantDomain", tenantDomain);
  
  // force lower-case on delete
  tenantDomain = tenantDomain.toLowerCase();
  
  int deleted = tenantEntityCache.deleteByKey(tenantDomain);
  if (deleted < 1)
  {
    throw new ConcurrencyFailureException("TenantEntity " + tenantDomain + " no longer exists");
  }
}
 
origin: Alfresco/alfresco-repository

@Override
public void deleteTenant(String tenantDomain)
{
  ParameterCheck.mandatoryString("tenantDomain", tenantDomain);
  
  // force lower-case on delete
  tenantDomain = tenantDomain.toLowerCase();
  
  int deleted = tenantEntityCache.deleteByKey(tenantDomain);
  if (deleted < 1)
  {
    throw new ConcurrencyFailureException("TenantEntity " + tenantDomain + " no longer exists");
  }
}
 
origin: org.alfresco/alfresco-repository

@Override
protected PropertyRootEntity updatePropertyRoot(PropertyRootEntity entity)
{
  entity.incrementVersion();
  int updated = template.update(UPDATE_PROPERTY_ROOT, entity);
  if (updated != 1)
  {
    // unexpected number of rows affected
    throw new ConcurrencyFailureException("Incorrect number of rows affected for updatePropertyRoot: " + entity + ": expected 1, actual " + updated);
  }
  return entity;
}
origin: org.alfresco/alfresco-repository

public void deleteAclChangeSet(Long changeSetId)
{
  int deleted = deleteAclChangeSetEntity(changeSetId);
  if (deleted != 1)
  {
    aclEntityCache.removeByKey(changeSetId);
    throw new ConcurrencyFailureException("Deleted by ID should delete exactly 1: " + changeSetId);
  }
}
 
origin: org.alfresco/alfresco-repository

@Override
public Pair<Long, ChildAssociationRef> getChildAssoc(Long assocId)
{
  ChildAssocEntity assoc = selectChildAssoc(assocId);
  if (assoc == null)
  {
    throw new ConcurrencyFailureException("Child association not found: " + assocId);
  }
  return assoc.getPair(qnameDAO);
}
origin: org.alfresco/alfresco-repository

@Override
protected PropertyUniqueContextEntity updatePropertyUniqueContext(PropertyUniqueContextEntity entity)
{
  entity.incrementVersion();
  int updated = template.update(UPDATE_PROPERTY_UNIQUE_CTX, entity);
  if (updated != 1)
  {
    // unexpected number of rows affected
    throw new ConcurrencyFailureException("Incorrect number of rows affected for updatePropertyUniqueContext: " + entity + ": expected 1, actual " + updated);
  }
  return entity;
}
origin: Alfresco/alfresco-repository

@Override
protected PropertyUniqueContextEntity updatePropertyUniqueContext(PropertyUniqueContextEntity entity)
{
  entity.incrementVersion();
  int updated = template.update(UPDATE_PROPERTY_UNIQUE_CTX, entity);
  if (updated != 1)
  {
    // unexpected number of rows affected
    throw new ConcurrencyFailureException("Incorrect number of rows affected for updatePropertyUniqueContext: " + entity + ": expected 1, actual " + updated);
  }
  return entity;
}
origin: Alfresco/alfresco-repository

@Override
public Pair<Long, ChildAssociationRef> getChildAssoc(Long assocId)
{
  ChildAssocEntity assoc = selectChildAssoc(assocId);
  if (assoc == null)
  {
    throw new ConcurrencyFailureException("Child association not found: " + assocId);
  }
  return assoc.getPair(qnameDAO);
}
origin: Alfresco/alfresco-repository

@Override
protected PropertyRootEntity updatePropertyRoot(PropertyRootEntity entity)
{
  entity.incrementVersion();
  int updated = template.update(UPDATE_PROPERTY_ROOT, entity);
  if (updated != 1)
  {
    // unexpected number of rows affected
    throw new ConcurrencyFailureException("Incorrect number of rows affected for updatePropertyRoot: " + entity + ": expected 1, actual " + updated);
  }
  return entity;
}
origin: Alfresco/alfresco-repository

@Override
public void updateTenant(TenantUpdateEntity entity)
{
  ParameterCheck.mandatory("entity", entity);
  ParameterCheck.mandatory("entity.version", entity.getVersion());
  ParameterCheck.mandatoryString("entity.tenantDomain", entity.getTenantDomain());
  
  int updated = tenantEntityCache.updateValue(entity.getTenantDomain(), entity);
  if (updated < 1)
  {
    throw new ConcurrencyFailureException("TenantEntity " + entity.getTenantDomain() + " no longer exists or has been updated concurrently");
  }
}
 
origin: org.alfresco/alfresco-repository

@Override
public void updateTenant(TenantUpdateEntity entity)
{
  ParameterCheck.mandatory("entity", entity);
  ParameterCheck.mandatory("entity.version", entity.getVersion());
  ParameterCheck.mandatoryString("entity.tenantDomain", entity.getTenantDomain());
  
  int updated = tenantEntityCache.updateValue(entity.getTenantDomain(), entity);
  if (updated < 1)
  {
    throw new ConcurrencyFailureException("TenantEntity " + entity.getTenantDomain() + " no longer exists or has been updated concurrently");
  }
}
 
org.springframework.daoConcurrencyFailureException<init>

Javadoc

Constructor for ConcurrencyFailureException.

Popular methods of ConcurrencyFailureException

  • getCause
  • getMessage

Popular in Java

  • Updating database using SQL prepared statement
  • getSystemService (Context)
  • notifyDataSetChanged (ArrayAdapter)
  • onRequestPermissionsResult (Fragment)
  • EOFException (java.io)
    Thrown when a program encounters the end of a file or stream during an input operation.
  • String (java.lang)
  • Timestamp (java.sql)
    A Java representation of the SQL TIMESTAMP type. It provides the capability of representing the SQL
  • Dictionary (java.util)
    Note: Do not use this class since it is obsolete. Please use the Map interface for new implementatio
  • CountDownLatch (java.util.concurrent)
    A synchronization aid that allows one or more threads to wait until a set of operations being perfor
  • ReentrantLock (java.util.concurrent.locks)
    A reentrant mutual exclusion Lock with the same basic behavior and semantics as the implicit monitor
  • Top plugins for WebStorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now