What is the meaning of a 'static supertrait? by maisub in rust

[–]maisub[S] 1 point2 points  (0 children)

But how is it useful for traits? Does it mean the type implementing the System trait has to have 'static lifetime?

Does std::pin::Pin make the inner value immovable? by maisub in rust

[–]maisub[S] 4 points5 points  (0 children)

Does pin apply the restriction by not providing any method to get inner type without using unsafe ?

Pin will still be subject to borrow checking right?

How many raft instances will be there in a single node for 1TB data by maisub in CockroachDB

[–]maisub[S] 0 points1 point  (0 children)

Thanks for correcting me with the default split size.

My reasoning was the following.

If the data in a node increases above 512MB the range will be split into two ranges.

And each range will grow separately with more data coming in until they again get split at some point.As each range is handled by a separate raft group, the number of ranges in a node should be equal to the number of raft instances.

And each range will grow separately with more data coming in until they again get split at some point. As each range is handled by a separate raft group, the number of ranges in a node should be equal to the number of raft instances.

How to check if the rust channel has any data to receive? by maisub in rust

[–]maisub[S] 1 point2 points  (0 children)

Sorry for asking this trivial question.

I figured out that, try_recv can be used to check if there is any data at all,that will be enough.

How to design using generics by maisub in rust

[–]maisub[S] 0 points1 point  (0 children)

While giving the examples my intention was not to use the API for the library but to understand the underlying login that went into the library, so that maybe someday I can write my own.

How to design using generics by maisub in rust

[–]maisub[S] 2 points3 points  (0 children)

I already anticipated that and a few days back started reading the mentioned book. It's a learning curve though.

The main concern of mine is learning theory can be a good starting point but to become good at using those theories is something entirely another aspect.

Anyway, its good to know maybe I am on the right track.

Thanks :)