Package org.apache.derby.iapi.store.raw

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


      return null;
    }

    // RESOLVE: no translation!

    PageKey pageSearch = new PageKey(identity, pageNumber);
    BasePage page = (BasePage)pageCache.find(pageSearch);

    if (page == null)
    {
      return page;
View Full Code Here


    synchronized(allocCache)
    {
      allocCache.invalidate();
    }
   
    PageKey pageSearch = new PageKey(identity, pageNumber);
    BasePage page = (BasePage) pageCache.find(pageSearch);

    return page;
  }
View Full Code Here

    // RESOLVE: first need to verify that the page is really NOT in the
    // container!

    // no address translation necessary
    PageKey pkey = new PageKey(identity, pageNumber);

    PageCreationArgs reCreatePageArgs;

    if (pageFormat == StoredPage.FORMAT_NUMBER)
    {
View Full Code Here

  protected BasePage getAllocPage(long pageNumber) throws StandardException
  {
    if (getCommittedDropState()) // committed and dropped, cannot get a page
      return null;

    PageKey pageSearch = new PageKey(identity, pageNumber);
    BasePage page = (BasePage) pageCache.find(pageSearch);

    if (SanityManager.DEBUG)
    {
      if (page == null)
View Full Code Here

   */
  protected BasePage getLatchedPage(BaseContainerHandle handle,
                                        long pageNumber)
    throws StandardException
  {
    PageKey pageKey = new PageKey(identity, pageNumber);
    BasePage page = (BasePage) pageCache.find(pageKey);
       
    if (SanityManager.DEBUG){
      SanityManager.ASSERT(page != null, "page is not found :" + pageKey);
    }
View Full Code Here

    boolean error = false;
    int count = 0;

    while(count < preAllocSize)
    {
      PageKey pkey = new PageKey(identity,
                     lastPreallocPagenum+count+1);
      try
      {
        // create Identity will do a writePage
        page.createIdentity(pkey, createArgs);
View Full Code Here

    RawTransaction t = owner.getTransaction();

    // lock the records to be purged
    int[] recordIds = new int[numpurges];

    PageKey pageId = getPageId(); // RESOLVE: MT problem ?

    for (int i = 0; i < numpurges; i++)
    {
      recordIds[i] = getHeaderAtSlot(slot + i).getId();
View Full Code Here

    BasePage dpage = (BasePage)destPage;

    // make sure they are from the same container - this means they are of
    // the same size and have the same page and record format.

    PageKey pageId = getPageId(); // RESOLVE: MT problem ?

    if (!pageId.getContainerId().equals(dpage.getPageId().getContainerId()))
        {
      throw StandardException.newException(
                    SQLState.DATA_DIFFERENT_CONTAINER,
                    pageId.getContainerId(),
                    dpage.getPageId().getContainerId());
        }

    int[] recordIds = new int[num_rows];
View Full Code Here

    // get num_rows row locks, need to predict what those recordIds will be

    int[] recordIds = new int[num_rows];

    PageKey pageId = getPageId(); // RESOLVE - MT problem ?

    // get new recordIds for the rows from this page
    // RESOLVE: we should also record the amount of reserved space

    for (int i = 0; i < num_rows; i++)
View Full Code Here

    checksum.reset();
    checksum.update(a, 0, CONTAINER_INFO_SIZE - CHECKSUM_SIZE);

    if (onDiskChecksum != checksum.getValue())
    {
      PageKey pk = new PageKey(identity, FIRST_ALLOC_PAGE_NUMBER);

      throw dataFactory.markCorrupt
        (StandardException.newException(
                    SQLState.FILE_BAD_CHECKSUM,
                    pk,
View Full Code Here

TOP

Related Classes of org.apache.derby.iapi.store.raw.PageKey

Copyright © 2018 www.massapicom. 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.