This is an automated email from the ASF dual-hosted git repository.

toulmean pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-tuweni.git


The following commit(s) were added to refs/heads/main by this push:
     new e3d0b479d more readmes
     new 6b1a86f9c Merge pull request #514 from atoulme/readmes
e3d0b479d is described below

commit e3d0b479dda36d713f4705f9a72499d4877d3885
Author: Antoine Toulme <[email protected]>
AuthorDate: Sat Feb 4 14:56:37 2023 -0800

    more readmes
---
 merkle-trie/README.md                              | 20 ++++++++++++++++++++
 stratum/proxy/README.md                            | 22 ++++++++++++++++++----
 stratum/server/README.md                           |  6 ++++++
 .../apache/tuweni/stratum/server/StratumServer.kt  |  7 +++++++
 wallet/README.md                                   |  6 ++++++
 5 files changed, 57 insertions(+), 4 deletions(-)

diff --git a/merkle-trie/README.md b/merkle-trie/README.md
index 4bcafd28d..f97634499 100644
--- a/merkle-trie/README.md
+++ b/merkle-trie/README.md
@@ -17,5 +17,25 @@ specific language governing permissions and limitations 
under the License.
 | Stability      | [stable]  |
 | Component Type | [library] |
 
+This library introduces a [Patricia Merkle 
tree](https://en.wikipedia.org/wiki/Merkle_tree) 
[implementation](https://tuweni.apache.org/docs/org.apache.tuweni.trie/-merkle-patricia-trie/index.html).
+
+It can be backed in memory or using a [key-value 
store](https://tuweni.apache.org/docs/org.apache.tuweni.kv/index.html).
+
+The library offers a few methods to define a trie in memory quickly:
+
+* 
[`MerklePatriaTrie.storingStrings()`](https://tuweni.apache.org/docs/org.apache.tuweni.trie/-merkle-patricia-trie/storing-strings.html)
 defines a trie using keys and values as Strings.
+* 
[`MerklePatriaTrie.storingBytes()`](https://tuweni.apache.org/docs/org.apache.tuweni.trie/-merkle-patricia-trie/storing-bytes.html)
 defines a trie using keys and values as Bytes.
+
+The same approach works with a stored trie:
+
+* [`StoredMerklePatriciaTrie.storingStrings(storage: 
MerkleStorage)`](https://tuweni.apache.org/docs/org.apache.tuweni.trie/-stored-merkle-patricia-trie/storing-strings.html)
+* [`StoredMerklePatriciaTrie.storingBytes(storage: 
MerkleStorage)`](https://tuweni.apache.org/docs/org.apache.tuweni.trie/-stored-merkle-patricia-trie/storing-bytes.html)
+
+You will need to provide a storage in this case, which you will define by 
implementing 
[`MerkleStorage`](https://tuweni.apache.org/docs/org.apache.tuweni.trie/-merkle-storage/index.html).
+
+Note in Java, you should use 
[`AsyncMerkleStorage`](https://tuweni.apache.org/docs/org.apache.tuweni.trie/-async-merkle-storage/index.html)
 instead to avoid dealing with coroutines.
+
+An easy way to provide storage is to rely on a key-value store as defined in 
the [kv](https://tuweni.apache.org/docs/org.apache.tuweni.kv/index.html) 
library.
+
 
[stable]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#stable
 
[library]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#library
\ No newline at end of file
diff --git a/stratum/proxy/README.md b/stratum/proxy/README.md
index a19d39b28..f77d0c1f0 100644
--- a/stratum/proxy/README.md
+++ b/stratum/proxy/README.md
@@ -12,10 +12,24 @@ specific language governing permissions and limitations 
under the License.
  --->
 # Stratum Proxy
 
-| Status         |           |
-|----------------|-----------|
-| Stability      | [beta]    |
-| Component Type | [library] |
+| Status         |               |
+|----------------|---------------|
+| Stability      | [beta]        |
+| Component Type | [application] |
+
+This application acts as a proxy between an Ethereum client and miners.
+
+It connects to the client over JSON-RPC (using http://localhost:8545), polling 
for new work periodically, and submitting work sent by clients.
+
+It runs a [Stratum 
server](https://tuweni.apache.org/docs/org.apache.tuweni.stratum.server/-stratum-server/index.html)
 to which miners can connect to over Stratum.
+
+Usage:
+* Expose a Stratum server on 0.0.0.0:16000:
+```bash
+$> stratum-proxy 16000
+```
+
+
 
 [beta]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#beta
 
[library]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#library
\ No newline at end of file
diff --git a/stratum/server/README.md b/stratum/server/README.md
index 1be4c7167..8c1bbdcf1 100644
--- a/stratum/server/README.md
+++ b/stratum/server/README.md
@@ -17,5 +17,11 @@ specific language governing permissions and limitations 
under the License.
 | Stability      | [beta]    |
 | Component Type | [library] |
 
+This library introduces a [Stratum 
server](https://tuweni.apache.org/docs/org.apache.tuweni.stratum.server/-stratum-server/index.html)
 which listens on a TCP port for connections from stratum clients.
+
+The server is compatible with the eth-proxy and Stratum1 protocols.
+
+The server accepts new work with the `setNewWork(powInput: PoWInput)` method, 
with a parameter of type 
[PowInput](https://tuweni.apache.org/docs/org.apache.tuweni.stratum.server/-po-w-input/index.html).
+
 [beta]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#beta
 
[library]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#library
\ No newline at end of file
diff --git 
a/stratum/server/src/main/kotlin/org/apache/tuweni/stratum/server/StratumServer.kt
 
b/stratum/server/src/main/kotlin/org/apache/tuweni/stratum/server/StratumServer.kt
index 944ae700b..792c7690f 100644
--- 
a/stratum/server/src/main/kotlin/org/apache/tuweni/stratum/server/StratumServer.kt
+++ 
b/stratum/server/src/main/kotlin/org/apache/tuweni/stratum/server/StratumServer.kt
@@ -92,6 +92,13 @@ class StratumServer(
   private var tcpServer: NetServer? = null
   private val denyList = ExpiringSet<String>(denyTimeout)
 
+  /**
+   * Accepts new work. sending it to all connected clients. New clients will 
also be notified of this work.
+   *
+   * This method returns immediately, all messages are sent asynchronously.
+   *
+   * @param powInput the new work
+   */
   fun setNewWork(powInput: PoWInput) {
     for (protocol in protocols) {
       launch {
diff --git a/wallet/README.md b/wallet/README.md
index 1b703f30a..b9da7baae 100644
--- a/wallet/README.md
+++ b/wallet/README.md
@@ -17,5 +17,11 @@ specific language governing permissions and limitations 
under the License.
 | Stability      | [alpha]   |
 | Component Type | [library] |
 
+This library defines a wallet you can use to sign transactions using a private 
key on the SECP256K1 curve.
+
+The library handles storing the private key of the wallet using symmetric 
encryption via an AES256 key.
+
+The library holds the private key in memory, and therefore is susceptible to 
memory dumps.
+
 
[alpha]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#alpha
 
[library]:https://github.com/apache/incubator-tuweni/tree/main/docs/index.md#library
\ No newline at end of file


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to