boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Java版 - Concurrent update of highly contended resources现在都有啥好办法
相关主题
MongoDB for Java Developers Starts Today
现在到底工作有多少需要Java的多线程呢?
distributed
web app 用Cassandra当distributed cach
synchronization for counters
菜鸟问关于Java Programming的问题
学java concurrent看哪个open source源码好? (转载)
Twitter Search is Now 3x Faster using Java server
怎么可以练习多线程编程呢?
大牛能不能简单谈谈multi threading在spring里是长什么样的?
相关话题的讨论汇总
话题: concurrent话题: contended话题: counter话题: resources
进入Java版参与讨论
1 (共1页)
F****n
发帖数: 3271
1
比如以前有人提到过的订票系统,假设一张票一个记录数量为100个,如果有1000个访
问订票对这个记录会产生大量write lock request, 让系统变慢。一个解决办法是把这
个记录分成多个放在不同的分区,但这个显然麻烦而且不太clean,不知道现在有啥
best practice?
g*****g
发帖数: 34805
2
Distributed counter is one choice. But it may not meet high ACID requirement
when you need to write other data to DB in one transaction.
Async process is another. Google checkout will not tell you at the spot wh
ether a purchase is successful on high demand, it will send you an email
later
instead.

【在 F****n 的大作中提到】
: 比如以前有人提到过的订票系统,假设一张票一个记录数量为100个,如果有1000个访
: 问订票对这个记录会产生大量write lock request, 让系统变慢。一个解决办法是把这
: 个记录分成多个放在不同的分区,但这个显然麻烦而且不太clean,不知道现在有啥
: best practice?

F****n
发帖数: 3271
3
Thanks.
Distributed counter is similar to what we are doing.
Does Cassandra has transparent support for distributed counters,
i.e., can it declare a column as "counter" type and then increment/decrement
of that column can utilize a distributed counter?

requirement

【在 g*****g 的大作中提到】
: Distributed counter is one choice. But it may not meet high ACID requirement
: when you need to write other data to DB in one transaction.
: Async process is another. Google checkout will not tell you at the spot wh
: ether a purchase is successful on high demand, it will send you an email
: later
: instead.

g*****g
发帖数: 34805
4
That's correct. Keep in mind due to its nature, the counter isn't always
accurate. If your app is very sensitive on that, don't use it.

decrement

【在 F****n 的大作中提到】
: Thanks.
: Distributed counter is similar to what we are doing.
: Does Cassandra has transparent support for distributed counters,
: i.e., can it declare a column as "counter" type and then increment/decrement
: of that column can utilize a distributed counter?
:
: requirement

w**z
发帖数: 8232
5
Cassandra counter has a lot of issues. it claims that it is fixed in 2.0.x,
research it before using it.

decrement

【在 F****n 的大作中提到】
: Thanks.
: Distributed counter is similar to what we are doing.
: Does Cassandra has transparent support for distributed counters,
: i.e., can it declare a column as "counter" type and then increment/decrement
: of that column can utilize a distributed counter?
:
: requirement

1 (共1页)
进入Java版参与讨论
相关主题
大牛能不能简单谈谈multi threading在spring里是长什么样的?
向能人请教
java http request能做到打开一次多次发送http request吗
java SOAP比restful难学吗?
java8的default出来之后
Netflix用什么Java Framework (转载)
very weird problem
anybody working on Cassandra?
云计算如何应用到传统的web server应用
多少个thread 就算不正常?
相关话题的讨论汇总
话题: concurrent话题: contended话题: counter话题: resources