You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by GitBox <gi...@apache.org> on 2021/12/28 08:41:08 UTC

[GitHub] [ignite] ibessonov opened a new pull request #9702: IGNITE-16024 B+Tree-related javadocs.

ibessonov opened a new pull request #9702:
URL: https://github.com/apache/ignite/pull/9702


   Thank you for submitting the pull request to the Apache Ignite.
   
   In order to streamline the review of the contribution 
   we ask you to ensure the following steps have been taken:
   
   ### The Contribution Checklist
   - [ ] There is a single JIRA ticket related to the pull request. 
   - [ ] The web-link to the pull request is attached to the JIRA ticket.
   - [ ] The JIRA ticket has the _Patch Available_ state.
   - [ ] The pull request body describes changes that have been made. 
   The description explains _WHAT_ and _WHY_ was made instead of _HOW_.
   - [ ] The pull request title is treated as the final commit message. 
   The following pattern must be used: `IGNITE-XXXX Change summary` where `XXXX` - number of JIRA issue.
   - [ ] A reviewer has been mentioned through the JIRA comments 
   (see [the Maintainers list](https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute#HowtoContribute-ReviewProcessandMaintainers)) 
   - [ ] The pull request has been checked by the Teamcity Bot and 
   the `green visa` attached to the JIRA ticket (see [TC.Bot: Check PR](https://mtcga.gridgain.com/prs.html))
   
   ### Notes
   - [How to Contribute](https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute)
   - [Coding abbreviation rules](https://cwiki.apache.org/confluence/display/IGNITE/Abbreviation+Rules)
   - [Coding Guidelines](https://cwiki.apache.org/confluence/display/IGNITE/Coding+Guidelines)
   - [Apache Ignite Teamcity Bot](https://cwiki.apache.org/confluence/display/IGNITE/Apache+Ignite+Teamcity+Bot)
   
   If you need any help, please email dev@ignite.apache.org or ask anу advice on http://asf.slack.com _#ignite_ channel.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] SammyVimes commented on a change in pull request #9702: IGNITE-16024 B+Tree-related javadocs.

Posted by GitBox <gi...@apache.org>.
SammyVimes commented on a change in pull request #9702:
URL: https://github.com/apache/ignite/pull/9702#discussion_r786168204



##########
File path: modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/tree/BPlusTree.java
##########
@@ -94,7 +94,69 @@
 import static org.apache.ignite.internal.processors.cache.persistence.tree.io.PageIoResolver.DEFAULT_PAGE_IO_RESOLVER;
 
 /**
- * Abstract B+Tree.
+ * <h3>Abstract B+Tree.</h3>
+ *
+ * B+Tree is a block-based tree structure. Each block is represented with the page ({@link PageIO}) and contains a
+ * single tree node. There are two types of pages/nodes: {@link BPlusInnerIO} and {@link BPlusLeafIO}.
+ * <p/>
+ * Every page in the tree contains a list of <i>items</i>. Item is just a fixed-size binary payload.
+ * Inner nodes and leaves may have different item sizes. There's a limit on how many items each page can hold.
+ * It is described by a {@link BPlusIO#getMaxCount(long, int)} method is the corresponding IO. There should be no empty
+ * pages in trees, so it's expected to have from {@code 1} to {@code max} items in every page.
+ * <p/>
+ * Items might have different meaning depending on the type of the page. In case of leaves, every item must describe a
+ * key and a value. In case of inner nodes, items describe only keys if {@link #canGetRowFromInner} is {@code false},
+ * or a key and a value otherwise. Items in every page are sorted according to the order dscribed by
+ * {@link #compare(BPlusIO, long, int, Object)} method. Specifics of the data stored in items are defined in the
+ * implementation and generally don't matter.
+ * <p/>
+ * All pages in the tree are devided into levels. Leaves are always at the level {@code 0}. Levels of inner pages are

Review comment:
       ```suggestion
    * All pages in the tree are divided into levels. Leaves are always at the level {@code 0}. Levels of inner pages are
   ```

##########
File path: modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/tree/BPlusTree.java
##########
@@ -94,7 +94,69 @@
 import static org.apache.ignite.internal.processors.cache.persistence.tree.io.PageIoResolver.DEFAULT_PAGE_IO_RESOLVER;
 
 /**
- * Abstract B+Tree.
+ * <h3>Abstract B+Tree.</h3>
+ *
+ * B+Tree is a block-based tree structure. Each block is represented with the page ({@link PageIO}) and contains a
+ * single tree node. There are two types of pages/nodes: {@link BPlusInnerIO} and {@link BPlusLeafIO}.
+ * <p/>
+ * Every page in the tree contains a list of <i>items</i>. Item is just a fixed-size binary payload.
+ * Inner nodes and leaves may have different item sizes. There's a limit on how many items each page can hold.
+ * It is described by a {@link BPlusIO#getMaxCount(long, int)} method is the corresponding IO. There should be no empty

Review comment:
       ```suggestion
    * It is defined by a {@link BPlusIO#getMaxCount(long, int)} method of the corresponding IO. There should be no empty
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] ibessonov merged pull request #9702: IGNITE-16024 B+Tree-related javadocs.

Posted by GitBox <gi...@apache.org>.
ibessonov merged pull request #9702:
URL: https://github.com/apache/ignite/pull/9702


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org