Examples of ContainerKey


Examples of org.apache.derby.iapi.store.raw.ContainerKey

      if (!(plainLock instanceof RecordHandle)) {
        // only interested in rows locks
        continue;
      }

      ContainerKey ckey = ((RecordHandle) plainLock).getContainerId();
     
      LockCount lc = (LockCount) containers.get(ckey);
      if (lc == null) {
        lc = new LockCount();
        containers.put(ckey, lc);
      }
      lc.count++;
    }

    // Determine the threshold for lock escalation
    // based upon our own limit, not the current count
    int threshold = limit / (containers.size() + 1);
    if (threshold < (limit / 4))
      threshold = limit / 4;

    // try to table lock all tables that are above
    // this threshold

    boolean didEscalate = false;
    for (Enumeration e = containers.keys(); e.hasMoreElements(); ) {
      ContainerKey ckey = (ContainerKey) e.nextElement();

      LockCount lc = (LockCount) containers.get(ckey);

      if (lc.count < threshold) {
        continue;
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

                // If not in cache - ask the factory for it and insert it.

                conglom =
                    getFactoryFromConglomId(conglomid).readConglomerate(
                        xact_mgr, new ContainerKey(0, conglomid));

                if (conglom != null)
                {
                    // on cache miss, put the missing conglom in the cache.
                    cache_entry = (CacheableConglomerate)
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

        {
            if (input_containerid != ContainerHandle.DEFAULT_ASSIGN_ID)
                SanityManager.ASSERT(containerid == input_containerid);
        }

    id = new ContainerKey(segmentId, containerid);
  }
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

    maintainParentLinks = in.readBoolean();

        // read in the array of format id's
        format_ids = ConglomerateUtil.readFormatIdArray(this.nKeyFields, in);

    id = new ContainerKey(segmentid, containerid);
  }
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

    maintainParentLinks = in.readBoolean();

        // read in the array of format id's
        format_ids = ConglomerateUtil.readFormatIdArray(this.nKeyFields, in);

    id = new ContainerKey(segmentid, containerid);
  }
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

            throw StandardException.newException(
                    SQLState.HEAP_CANT_CREATE_CONTAINER);
        }

    // Keep track of what segment the container's in.
    id = new ContainerKey(segmentId, containerid);

    // Heap requires a template representing every column in the table.
        if ((template == null) || (template.length == 0))
        {
            throw StandardException.newException(
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

     **/
    public void boot_create(
    long                    containerid,
    DataValueDescriptor[]   template)
    {
    id = new ContainerKey(0, containerid);
        this.format_ids = ConglomerateUtil.createFormatIds(template);
    }
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

        FormatIdUtil.readFormatIdInteger(in);

    int segmentid = in.readInt();
        long containerid = in.readLong();

    id = new ContainerKey(segmentid, containerid);

        // read the number of columns in the heap.
        int num_columns = in.readInt();

        // read the array of format ids.
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

        FormatIdUtil.readFormatIdInteger(in);

    int segmentid = in.readInt();
        long containerid = in.readLong();

    id = new ContainerKey(segmentid, containerid);

        // read the number of columns in the heap.
        int num_columns = in.readInt();

        // read the array of format ids.
View Full Code Here

Examples of org.apache.derby.iapi.store.raw.ContainerKey

        // internally generated one from getNextId().
        long containerId =
            ((input_containerid != ContainerHandle.DEFAULT_ASSIGN_ID) ?
                 input_containerid : getNextId());

    ContainerKey identity = new ContainerKey(segmentId, containerId);

    boolean tmpContainer = (segmentId == ContainerHandle.TEMPORARY_SEGMENT);

    ContainerHandle ch = null;
    LockingPolicy   cl = null;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.