fluo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ktur...@apache.org
Subject [4/5] incubator-fluo-website git commit: Code review updates
Date Mon, 10 Oct 2016 19:13:30 GMT
Code review updates


Project: http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/commit/ef3b2b76
Tree: http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/tree/ef3b2b76
Diff: http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/diff/ef3b2b76

Branch: refs/heads/gh-pages
Commit: ef3b2b760c0450b79f1cfa949d6483d012e128eb
Parents: e3415fd
Author: Mike Walch <mwalch@apache.org>
Authored: Mon Oct 3 14:40:50 2016 -0400
Committer: Keith Turner <keith@deenlo.com>
Committed: Mon Oct 10 19:10:01 2016 -0400

----------------------------------------------------------------------
 tour/application-configuration.md |  4 ++--
 tour/basic-read-write.md          |  8 ++++----
 tour/data-model.md                |  6 +++---
 tour/data-pojos.md                |  8 ++++----
 tour/exercise-1.md                | 18 ++++++++----------
 tour/loader-executer.md           |  4 ++--
 tour/observers.md                 | 10 +++++-----
 tour/scanning.md                  |  6 +++---
 tour/tx-logging.md                |  4 ++--
 tour/weak-notifications.md        |  6 +++---
 tour/write-skew.md                |  4 ++--
 11 files changed, 38 insertions(+), 40 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/application-configuration.md
----------------------------------------------------------------------
diff --git a/tour/application-configuration.md b/tour/application-configuration.md
index 2b39281..143171f 100644
--- a/tour/application-configuration.md
+++ b/tour/application-configuration.md
@@ -48,13 +48,13 @@ table5
 
 If you want instances of an Observer to behave differently and share code, one way to accomplish
 this is with per observer configuration.  When setting up an observer call one of the
-[ObserverSpecification][ospec] methods that takes configuration.  When an observer is initalized
it
+[ObserverSpecification][ospec] methods that takes configuration.  When an observer is initialized
it
 can access this configuration by calling [Observer.Context.getObserverConfiguration()][ocgp].
 
 The code below shows an example of setting configuration for an Observer.  This example simulates
an
 observer that can export rows to a mysql table. The example configures two instances of an
observer
 using the same class with different configuration.  Even though the observers use the same
class, the
-two instances must observe different columns.  Thats why the code derives the observed column
based
+two instances must observe different columns.  That is why the code derives the observed
column based
 on the observer configuration.  Notice the mysql database is obtained from application configuration
by
 the observer and the table is obtained from observer configuration.
 

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/basic-read-write.md
----------------------------------------------------------------------
diff --git a/tour/basic-read-write.md b/tour/basic-read-write.md
index c476e1d..f244aec 100644
--- a/tour/basic-read-write.md
+++ b/tour/basic-read-write.md
@@ -3,8 +3,8 @@ title: Read and Write Data
 ---
 
 The following example shows basic code for writing data using Fluo and then reading it back
out.  To
-run this code modify `src/main/java/ft/Main.java` in the [Fluo Tour git repository][1] and
run it
-following the instructions on the repository.
+run this code, modify `src/main/java/ft/Main.java` in the [Fluo Tour git repository][1] and
run it by
+following the instructions in the repository.
 
 
 ```java
@@ -26,11 +26,11 @@ following the instructions on the repository.
   }
 ```
 
-In the example above a Transaction is created in a try-with-resources block.  A Transaction
can read
+In the example above, a **Transaction** is created in a try-with-resources block.  A Transaction
can read
 and write data.  It can only read data that was committed before it started.  Data set on
a
 transaction will only be written when `commit()` is called.
 
-A Snapshot is created to read the data previously written by the Transaction.  Snapshots
only see
+A **Snapshot** is created to read the data previously written by the Transaction.  Snapshots
only see
 data committed before the snapshot was created.  The code calls [gets(CharSequence, Column)][gets]
which
 is a convenience method that works with strings.  Internally Fluo only deals with bytes and
its
 [get(Bytes, Column)][get] method returns [Bytes].   The Fluo methods that take and return
Strings

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/data-model.md
----------------------------------------------------------------------
diff --git a/tour/data-model.md b/tour/data-model.md
index 2425230..6f49d1b 100644
--- a/tour/data-model.md
+++ b/tour/data-model.md
@@ -21,9 +21,9 @@ column qualifier, and column visibility.
  * **Column Visibility** : In Accumulo this portion of the key is used to
    control access to data.
 
-This data model is schema-less, there is no need to predefine columns.  One
-thing that's defined in the Accumulo data modes that's not available in Fluo is
-timestamps.  When using Fluo the timestamp portion of the key is not available.
+This data model is schema-less so there is no need to predefine columns.  One
+thing that is defined in the Accumulo data model but is not available in Fluo is
+timestamps.  When using Fluo, the timestamp portion of the key is not available.
 
 In the subsequent pages of the tour the shorthand *\<row\>:\<family\>:\<qualifier\>*
 will be used.  For example, the following ...

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/data-pojos.md
----------------------------------------------------------------------
diff --git a/tour/data-pojos.md b/tour/data-pojos.md
index 12720a3..355355d 100644
--- a/tour/data-pojos.md
+++ b/tour/data-pojos.md
@@ -3,15 +3,15 @@ title: Basic Data Types
 ---
 
 Fluo has a few simple POJOs that are used throughout the API.  These classes
-are found in [org.apache.fluo.api.data][data-pkg].  All of these type are
-immutable. Except for Span, all of the types are Comparable and have good hash
-code and equals implementations.  These types work with [Bytes] and java
+are found in [org.apache.fluo.api.data][data-pkg].  All of these types are
+immutable. Except for Span, all of the types are Comparable and have hash
+code and equals implementations.  These types work with [Bytes] and Java
 Strings.  Internally, Fluo only works with bytes.  All API methods that deal
 with String will convert back and forth to and from bytes using UTF-8.
 
 [Bytes] is modeled after Java String.  Its an immutable wrapper around `byte[]`
 like String is an immutable wrapper around `char[]`.  To make building [Bytes]
-more efficient and easier, there is a reusable [BytesBuilder] thats modeled
+more efficient and easier, there is a reusable [BytesBuilder] that is modeled
 after StringBuilder.  Call [Bytes.builder()][nb] to create a new [BytesBuilder].
 
 [data-pkg]: /apidocs/fluo/{{ site.latest_fluo_release }}/org/apache/fluo/api/data/package-summary.html

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/exercise-1.md
----------------------------------------------------------------------
diff --git a/tour/exercise-1.md b/tour/exercise-1.md
index 3ec2a05..2c29aba 100644
--- a/tour/exercise-1.md
+++ b/tour/exercise-1.md
@@ -2,8 +2,8 @@
 title: Word count Exercise
 ---
 
-This Exercise will show you how to create a simple system that computes word
-counts for unique documents.   This system should do the following.
+This exercise will show you how to create a simple system that computes word counts for unique
+documents. This system should do the following.
 
  * Deduplicate content based on hash
  * Count how many URIs reference content
@@ -206,9 +206,9 @@ Make sure you handle the following scenario correctly.
  * content A becomes unreferenced
  * an observer runs on content A
 
-In this situation word counts were never incremented for content A, so there is
-no need to decrement the word counts.  One way to handle this is to have a
-column that tracks if word counts were incremented.
+In this situation, word counts were never incremented for content A so there is no need to
decrement
+the word counts.  One way to handle this is to have a column that tracks if word counts were
+incremented.
 
 Below is a skeleton for an observer to compute word counts.
 
@@ -396,10 +396,8 @@ After implementing the Observer, the output of the program should look
like the
 **** end table dump ****
 ```
 
-
 ## Part 3 : Using Fluo Recipes
 
-The way to compute word counts above is very prone to transactional collisions.  One way
to avoid
-these collisions would be use the CollisionFreeMap provided in Fluo Recipes.   Currently
Fluo
-Recipes is not released, this sections will be updated with more information once it is.
-
+The way to compute word counts above is very prone to transactional collisions. One way to
avoid
+these collisions is to use the CollisionFreeMap provided in Fluo Recipes. Currently Fluo
Recipes is
+not released, this section will be updated with more information once it is.
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/loader-executer.md
----------------------------------------------------------------------
diff --git a/tour/loader-executer.md b/tour/loader-executer.md
index 2e5ffb0..154c28d 100644
--- a/tour/loader-executer.md
+++ b/tour/loader-executer.md
@@ -3,7 +3,7 @@ title: Loader Executor
 ---
 
 Fluo provides a simple mechanism to help load data called the [LoaderExecutor][le].  Loading
data
-into Fluo requires a transaction.  The LoaderExecutor manages creating , commiting, and retrying
+into Fluo requires a transaction.  The LoaderExecutor manages creating, committing, and retrying
 transactions when collisions occur.  It also runs transactions in multiple threads and batches
 commit processing of separate transactions for efficiency.  FluoConfiguration provides two
methods
 for configuring LoaderExecutors [setLoaderQueueSize()][fcqs] and [setLoaderThreads()][fcst].
@@ -13,7 +13,7 @@ eventually be called on these objects at which point the passed in transactions
 data.  When `close()` is called on a LoaderExecutor, it waits for all running and queued
work to
 finish.
 
-There is no stand alone excercise for the LoaderExecutor.  Hands on experience with it can
be
+There is no stand alone exercise for the LoaderExecutor.  Hands on experience with it can
be
 obtained by completing the [word count exercise](/tour/exercise-1/) that is a few pages later
in
 the tour.
 

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/observers.md
----------------------------------------------------------------------
diff --git a/tour/observers.md b/tour/observers.md
index d6ae2c2..0f98629 100644
--- a/tour/observers.md
+++ b/tour/observers.md
@@ -2,14 +2,14 @@
 title: Observer Concepts
 ---
 
-Fluo supports complex processing by running user provided Observers which are triggered by
-notifications.   An Observer request that the system run it when a certain column is modified.
 When
+Fluo supports complex processing by running user provided code in Observers. Observers are
triggered
+by notifications. An Observer requests that the system run it when a certain column is modified.
When
 another transaction modifies an observed column, it will persist a notification that later
causes
-the Observer to run.  When an Observers is run, its provided with the row and column that
caused it
-to run along with a transaction.  Fluo worker processes running across a cluster will execute
+the Observer to run.  When an Observer is run, its provided with the row and column that
caused it
+to run along with a transaction. Fluo worker processes running across a cluster will execute
 Observers.
 
-Since all transactions need to know which columns trigger observers, observer must be registered
+Since all transactions need to know which columns trigger observers, observers must be registered
 with Fluo at initialization time.
 
 Fluo supports two type of notifications :

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/scanning.md
----------------------------------------------------------------------
diff --git a/tour/scanning.md b/tour/scanning.md
index 6cd39f6..7001268 100644
--- a/tour/scanning.md
+++ b/tour/scanning.md
@@ -2,8 +2,8 @@
 title: Scanning
 ---
 
-In some situations you may want to read a range of data instead of specific rows and columns.
 For
-this case Fluo supports [creating scanners][scanner] over ranges.   These scanners implement
Java Iterable and
+In some situations, you may want to read a range of data instead of specific rows and columns.
 For
+this case, Fluo supports [creating scanners][scanner] over ranges.   These scanners implement
Java Iterable and
 can be used with foreach loops.  Scanners also support reading a subset of columns within
a range.
 
 To specify a range, Fluo has a simple POJO called [Span].  The name was chosen so it would
not
@@ -29,7 +29,7 @@ ranges, like a range over all rows with a given prefix.  Try the following
exerc
  * **Using** *s1* **scan and print row** *kerbalnaut0002* **and column family** *name*
  * **Using** *s1* **scan rows with prefix** *kerbalnaut* **with columns** *name:first* **and**
*attr:bravery*
 
-Scanners also read data using snapshot isolation.  To show this try modifying the exercise
above to
+Scanners also read data using snapshot isolation.  To show this, try modifying the exercise
above to
 change data after *s1* is created but before the scans happen.
 
 [Span]: /apidocs/fluo/{{ site.latest_fluo_release }}/org/apache/fluo/api/data/Span.html

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/tx-logging.md
----------------------------------------------------------------------
diff --git a/tour/tx-logging.md b/tour/tx-logging.md
index cfecdb1..a16b548 100644
--- a/tour/tx-logging.md
+++ b/tour/tx-logging.md
@@ -3,8 +3,8 @@ title: Transaction Logging
 ---
 
 Fluo can produce detailed logs about transactions if configured to do so.
-This can be useful debugging.  Modify `./src/main/resources/log4j.properties`
-and remove `#` on the line `#log4j.logger.fluo.tx=TRACE`.  After doing this
+This can be useful for debugging.  Modify `./src/main/resources/log4j.properties`
+and remove `#` on the line `#log4j.logger.fluo.tx=TRACE`.  After doing this,
 rerun the collision exercise on the previous page.
 
 With this configuration change, you should see output like the following.

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/weak-notifications.md
----------------------------------------------------------------------
diff --git a/tour/weak-notifications.md b/tour/weak-notifications.md
index 9476de1..99c3b59 100644
--- a/tour/weak-notifications.md
+++ b/tour/weak-notifications.md
@@ -2,8 +2,8 @@
 title: Weak Notification Exercise
 ---
 
-This exercise will use weak notification to update a shared counter.   The way the example
works,
-many threads will concurrently try to update the counter.  However collisions will be avoided.
+This exercise will use weak notification to update a shared counter. In the example, many
threads
+will concurrently try to update the counter but collisions will be avoided.
 
 Create an observer that observes column *ntfy:sum* and make it do the following.
 
@@ -14,7 +14,7 @@ Create an observer that observes column *ntfy:sum* and make it do the following.
 
 Create a loader that does the following and run it 5000 times :
 
- * Generate a random number in the range [0,10^7-1].  This will be refered to as *\<rand\>*.
+ * Generate a random number in the range [0,10^7-1].  This will be referred to as *\<rand\>*.
  * Add one to *counter001/\<rand\>:sum:update*
  * Weakly notify *counter001:nfty:sum*
 

http://git-wip-us.apache.org/repos/asf/incubator-fluo-website/blob/ef3b2b76/tour/write-skew.md
----------------------------------------------------------------------
diff --git a/tour/write-skew.md b/tour/write-skew.md
index b14d6fd..731961b 100644
--- a/tour/write-skew.md
+++ b/tour/write-skew.md
@@ -6,8 +6,8 @@ The page on collisions showed that if two transactions overlap and write the
sam
 fail.  However, in the case where two transactions overlap and one reads data that another
is writing
 then both can succeed.  This behavior is called write skew.
 
-The example below shows write skew.  In the example *n0* is a node in a tree with two children
*n01*
-and *n02*.  In *tx2* the sum of *n0* is set to the sum of its children.  However *tx2* misses
the
+The example below shows write skew.  In the example, *n0* is a node in a tree with two children
*n01*
+and *n02*.  In *tx2*, the sum of *n0* is set to the sum of its children.  However, *tx2*
misses the
 concurrent update from *tx3*.  Both *tx2* and *tx3* will commit successfully since they write
to
 different keys.
 


Mime
View raw message