Comments (6)
Hey there, are you talking about right here?
solana-program-library/token/client/src/token.rs
Lines 383 to 386 in ce0389b
And could you maybe elaborate on what the motivation would be to add this change? It's not immediately clear from the description.
Thanks!
from solana-program-library.
hey @buffalojoec, I was talking about the type below. From what I can see from the fields, it seems like the type was made in order to be Send + Sync
? Otherwise why use Arc
for client
, payer
,... ? I think we could make Token
thread-safe by adding Send + Sync
as a bounds for client
, payer
and nonce_authority
.
solana-program-library/token/client/src/token.rs
Lines 331 to 342 in ce0389b
from solana-program-library.
@greged93 Sorry I'm just getting back here!
Yeah I think making Token
thread-safe makes sense. If you think it's important go for it!
from solana-program-library.
Great! Can you assign the issue?
from solana-program-library.
Why can't we directly send Token between threads? I think this is necessary to fully utilize multithreading
from solana-program-library.
If ProgramClient cannot be sent or synchronized directly between threads, how should it be handled in concurrent scenarios? I believe it needs to be implemented with the Send and Sync traits to address multithreading concurrency issues.
from solana-program-library.
Related Issues (20)
- Customized token gas fee
- `2.0.0` `solana-program` release causing issues due to `<=2.0.0` on patch upgrades. HOT 26
- Question/Bug: Solana 1.18.17 crates don't build | Spl-pod 0.1.0 needed for older version of solana HOT 6
- Question (Bug?): Upgrade of @solana/spl-token from 0.4.6->0.4.7 throws ERR_REQUIRE_ESM error HOT 4
- createMint Throwing TypeError: Cannot read properties of null (reading 'toBuffer') HOT 2
- Feature: Allow permanent delegate to close ata's for mint HOT 2
- @solana/[email protected] causing ESM import errors HOT 1
- Issue: `invoke_transfer_checked` failed with out of memory for 2 transfers with hook HOT 7
- getOrCreateAssociatedTokenAccount throws error despite payer has enough SOL and account exists already. HOT 1
- token-cli: `set-transfer-fee` has different granularity than `create-token` HOT 5
- token-cli: withdraw-withheld-tokens silently fails HOT 6
- Install spl-token-cli v4.0.0 failed HOT 7
- token-cli: Unable to use the token cli to transfer tokens that have the transfer-fee and transfer-hook extensions. HOT 2
- Feature Request: Use `u64` for Token-Group Interface `max_size` HOT 3
- Issue: Cannot Figure Out SDK Instruction HOT 1
- `?` couldn't convert the error to `solana_program::program_error::ProgramError` HOT 3
- Token Swap Error: The provided token program does not match the expected token program for the swap. HOT 1
- Suggestion: use default prettier settings HOT 1
- Feature request: add optional media to the TokenMetadata type HOT 1
- Unable to get a tokens metadata for token 2022 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from solana-program-library.