Skip to content

Commit

Permalink
Merge pull request #93 from Adamant-im/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
bludnic authored Sep 25, 2024
2 parents 42ad601 + 8176572 commit d1c7acd
Show file tree
Hide file tree
Showing 21 changed files with 368 additions and 162 deletions.
58 changes: 43 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ Coin/token info stored in `\general\${token_name}` folders. Specific blockchain
"alt_ip": "0.0.0.1:36666" // Alternative way to connect if the domain of a node is censored
}
],
// Node health сheck information
// Node health check information
"healthCheck": {
"normalUpdateInterval": 210000, // Regular node status update interval in ms
"crucialUpdateInterval": 30000, // Node status update interval when there are no active nodes, in ms
Expand All @@ -91,22 +91,32 @@ Coin/token info stored in `\general\${token_name}` folders. Specific blockchain

// Optional. Services related to a project
"services": {
"list": {
"infoService": [
{ "url": "https://info.example.com" },
"service1": {
"description": {
"software": "example-service",
"github": "https://github.com/--example",
"docs": "https://docs.example.com" // API docs
},
"list": [
{
"url": "https://info.example.com",
},
{
"url": "https://second-service.example.com",
"alt_ip": "0.0.0.1:80" // Alternative way to connect if the domain of a service is censored
}
]
},
// Optional: Service health сheck information (If not filled here, information is retrieved from nodes.healthCheck)
"healthCheck": {
"normalUpdateInterval": 210000, // Regular service status update interval in ms
"crucialUpdateInterval": 30000, // Service status update interval when there are no active services, in ms
"onScreenUpdateInterval": 10000 // On the node screen, the status update interval in ms
],
// Optional: Service health check information (If not filled here, information is retrieved from nodes.healthCheck)
"healthCheck": {
"normalUpdateInterval": 210000, // Regular service status update interval in ms
"crucialUpdateInterval": 30000, // Service status update interval when there are no active services, in ms
"onScreenUpdateInterval": 10000 // On the node screen, the status update interval in ms
},
"minVersion": "1.0.0", // Optional. Minimal supported service API version
},
"minVersion": "1.0.0", // Optional. Minimal supported service API version
"service2": {
/*...*/
}
},

// Optional. Additional project links
Expand All @@ -119,7 +129,7 @@ Coin/token info stored in `\general\${token_name}` folders. Specific blockchain
"name": "whitepaper",
"url": "https://example.com/whitepaper.pdf"
}
]
],

// Optional. Tor configuration if a project uses Tor
// It follows the same structure as the root properties
Expand All @@ -144,9 +154,9 @@ The total cost of a transaction is the product of the gas limit and gas price:
Tx \, fee = gas \, limit \times gas \, price
```

ADAMANT apps estimate gas limit and gas price using [web3](https://github.com/web3/web3.js) library. To make sure the Ethereum blockchain will include the tx, these estimates must be multiplied by `reliabilityGasLimitPercent` and `reliabilityGasPricePercent`.
ADAMANT apps estimate gas limit and gas price using [web3](https://github.com/web3/web3.js) library. To ensure the Ethereum blockchain will accept the tx, apps multiply these estimates by `reliabilityGasLimitPercent` and `reliabilityGasPricePercent`. Additionally, an app may offer the "Increase fee" option to use the `increasedGasPricePercent` koef.

If it’s not possible to get estimates, apps will use `defaultGasLimit` and `defaultGasPriceGwei`. When gas price is higher than `warningGasPriceGwei`, apps will show a note/warning.
If it’s not possible to get estimates, apps will use `defaultGasLimit` and `defaultGasPriceGwei`. When the gas price exceeds `warningGasPriceGwei`, apps show a note/warning.

These parameters are set inside `general\ethereum\info.json` and may be overridden by `blockchains\ethereum\info.json` and specific tokens.

Expand Down Expand Up @@ -188,6 +198,24 @@ const isNew = (admTransferTimestamp) =>
newPendingTxFetchAttempts * newPendingTxFetchInterval;
```

### Message sending

Users can request to send messages even when they are offline. An app will attempt to send a message for a specific timeout period, allowing time for the Internet connection to restore. If the message still cannot be sent, the status will change from “Pending” to “Failed”. Users can then manually retry sending the message or choose to cancel it.

For in-chat coin transfers, there is no timeout. An app will continuously retry sending these messages until successful. However, before sending cryptocurrency in chats, the app checks the availability of all nodes, ensuring both the nodes and the UI process the transaction correctly.

To assist apps in setting message sending parameters, additional fields are introduced:

```jsonc
{
// ...
"timeout": {
"message": 300000, // Timeout for regular messages (in milliseconds)
"attachment": 100000, // Timeout for file transfers (in milliseconds)
},
}
```

## Icons

Coin icons/images files are stored `\general\${token_name}\images` folders.
Expand Down
95 changes: 81 additions & 14 deletions assets/general/adamant/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@
"oldPendingInterval": 4000,
"registeredInterval": 4000
},
"timeout": {
"message": 300000,
"attachment": 300000
},
"nodes": {
"list": [
{ "url": "https://clown.adamant.im" },
Expand Down Expand Up @@ -70,18 +74,53 @@
"minVersion": "0.8.0"
},
"services": {
"list": {
"infoService": [
"infoService": {
"description": {
"software": "adamant-currencyinfo-services",
"github": "https://github.com/Adamant-im/adamant-currencyinfo-services",
"docs": "https://github.com/Adamant-im/adamant-currencyinfo-services/wiki/InfoServices-API-documentation"
},
"list": [
{
"url": "https://info.adamant.im",
"alt_ip": "http://88.198.156.44:44099"
},
{
"url": "https://info2.adm.im",
"alt_ip": "http://207.180.210.95:33088"
}
]
],
"healthCheck": {
"normalUpdateInterval": 300000,
"crucialUpdateInterval": 30000,
"onScreenUpdateInterval": 10000
}
},
"healthCheck": {
"normalUpdateInterval": 300000,
"crucialUpdateInterval": 300000,
"onScreenUpdateInterval": 300000
"ipfsNode": {
"description": {
"software": "ipfs-node",
"github": "https://github.com/Adamant-im/ipfs-node",
"docs": "https://github.com/Adamant-im/ipfs-node/blob/master/README.md"
},
"list": [
{
"url": "https://ipfs4.adm.im",
"alt_ip": "http://95.216.45.88:44099"
},
{
"url": "https://ipfs5.adamant.im",
"alt_ip": "http://62.72.43.99:44099"
},
{
"url": "https://ipfs6.adamant.business",
"alt_ip": "http://75.119.138.235:44099"
}
],
"healthCheck": {
"normalUpdateInterval": 300000,
"crucialUpdateInterval": 30000,
"onScreenUpdateInterval": 10000
}
}
},
"links": [
Expand Down Expand Up @@ -136,17 +175,45 @@
"minVersion": "0.8.0"
},
"services": {
"list": {
"infoService": [
"infoService": {
"description": {
"software": "adamant-currencyinfo-services",
"github": "https://github.com/Adamant-im/adamant-currencyinfo-services",
"docs": "https://github.com/Adamant-im/adamant-currencyinfo-services/wiki/InfoServices-API-documentation"
},
"list": [
{
"url": "http://czjsawp2crjmnkliw2h2kpk7wwd3a36zvvnvqgvzmi4t4vc2yzm7j2qd.onion"
}
]
],
"healthCheck": {
"normalUpdateInterval": 300000,
"crucialUpdateInterval": 30000,
"onScreenUpdateInterval": 10000
}
},
"healthCheck": {
"normalUpdateInterval": 300000,
"crucialUpdateInterval": 300000,
"onScreenUpdateInterval": 300000
"ipfsNode": {
"description": {
"software": "ipfs-node",
"github": "https://github.com/Adamant-im/ipfs-node",
"docs": "https://github.com/Adamant-im/ipfs-node/blob/master/README.md"
},
"list": [
{
"url": "http://z455rax4mwcseyc7efog7czrbwdvphwocatl5sjcc6htcoj2k2vz7dad.onion"
},
{
"url": "http://cds45bjd7ynxkffxpzfifnm55r6vmhgocvpvonjmry3mrskuhda6z7qd.onion"
},
{
"url": "http://3ytwoe62bqw264v4rkaqpn5iovdg3oxly5tx2uc5qijkrdqixm6tmdyd.onion"
}
],
"healthCheck": {
"normalUpdateInterval": 300000,
"crucialUpdateInterval": 30000,
"onScreenUpdateInterval": 10000
}
}
}
}
Expand Down
56 changes: 51 additions & 5 deletions assets/general/bitcoin/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@
"nodes": {
"list": [
{
"url": "https://btcnode1.adamant.im",
"alt_ip": "http://176.9.38.204:44099"
"url": "https://btcnode1.adamant.im/bitcoind",
"alt_ip": "http://176.9.38.204:44099/bitcoind"
},
{
"url": "https://btcnode3.adamant.im",
"alt_ip": "http://195.201.242.108:44099"
"url": "https://btcnode3.adamant.im/bitcoind",
"alt_ip": "http://195.201.242.108:44099/bitcoind"
}
],
"healthCheck": {
Expand All @@ -46,6 +46,30 @@
"threshold": 2
}
},
"services": {
"btcIndexer": {
"description": {
"software": "Esplora/Electrs",
"github": "https://github.com/blockstream/electrs",
"docs": "https://github.com/blockstream/esplora/blob/master/API.md"
},
"list": [
{
"url": "https://btcnode1.adamant.im",
"alt_ip": "http://176.9.38.204:44099"
},
{
"url": "https://btcnode3.adamant.im",
"alt_ip": "http://195.201.242.108:44099"
}
],
"healthCheck": {
"normalUpdateInterval": 330000,
"crucialUpdateInterval": 30000,
"onScreenUpdateInterval": 10000
}
}
},
"links": [
{
"name": "github",
Expand All @@ -68,7 +92,7 @@
"nodes": {
"list": [
{
"url": "http://cc6ibzkfeseuwnmtjc6hlsd44bzg2sr3shbv7n35nj2rk2vm6dmtlnqd.onion"
"url": "http://cc6ibzkfeseuwnmtjc6hlsd44bzg2sr3shbv7n35nj2rk2vm6dmtlnqd.onion/bitcoind"
},
{
"url": "http://grnpvgtlrfws3424l726td5lctsod3hq2at4lhiasmedpxygbo5u2bqd.onion"
Expand All @@ -80,6 +104,28 @@
"onScreenUpdateInterval": 10000,
"threshold": 2
}
},
"services": {
"btcIndexer": {
"description": {
"software": "Esplora/Electrs",
"github": "https://github.com/blockstream/electrs",
"docs": "https://github.com/blockstream/esplora/blob/master/API.md"
},
"list": [
{
"url": "http://cc6ibzkfeseuwnmtjc6hlsd44bzg2sr3shbv7n35nj2rk2vm6dmtlnqd.onion"
},
{
"url": "http://grnpvgtlrfws3424l726td5lctsod3hq2at4lhiasmedpxygbo5u2bqd.onion"
}
],
"healthCheck": {
"normalUpdateInterval": 330000,
"crucialUpdateInterval": 30000,
"onScreenUpdateInterval": 10000
}
}
}
}
}
Binary file modified assets/general/doge/images/doge_wallet.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/general/doge/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/general/doge/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
52 changes: 24 additions & 28 deletions assets/general/doge/images/icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 10 additions & 12 deletions assets/general/doge/images/icon.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
<template>
<g>
<g id="path3759">
<path
d="m245.999176,474.609467c-24.72522,0 -50.352844,-1.353577 -76.521866,-2.616882c-7.760468,-0.451202 -15.611191,-0.812164 -23.461884,-1.173126l-40.426643,-1.894989l0,-425.11145l41.238777,-1.173092c99.622803,-2.797379 202.494186,-5.684998 267.736282,58.384014c38.351166,37.629272 56.669495,91.411148 56.037842,164.413742l0,1.804749c-3.699768,73.453766 -24.003326,125.88208 -61.993561,160.082306c-42.953308,38.712128 -99.803253,47.284729 -162.608948,47.284729zm-55.586624,-86.5383c70.295456,3.519287 130.123245,4.421661 161.345596,-23.732574c20.303589,-18.318359 31.402863,-51.165009 34.019775,-100.525208c0.360931,-48.367599 -9.655457,-81.845901 -30.590698,-102.329941c-33.02713,-32.395462 -97.09613,-36.09523 -164.864929,-35.102608l0,261.690331l0.090256,0z"
/>
</g>
<g id="rect2987">
<rect height="78.326625" width="224.15131" y="219.506499" x="45.4" />
</g>
</g>
</template>
<template>
<g>
<path
d="M261.76 174.16H227.469V241.766H281.418V270.071H227.469V337.672H263.44C272.682 337.672 339.318 338.716 339.215 259.019C339.112 179.322 274.586 174.16 261.76 174.16Z"
/>
<path
d="M256 16C123.45 16 16 123.45 16 256C16 388.55 123.45 496 256 496C388.55 496 496 388.55 496 256C496 123.45 388.55 16 256 16ZM265.43 385.624H178.514V270.074H147.875V241.768H178.511V126.21H253.108C270.755 126.21 387.642 122.546 387.642 258.086C387.642 395.867 265.432 385.624 265.432 385.624H265.43Z"
/>
</g>
</template>
Loading

0 comments on commit d1c7acd

Please sign in to comment.