Ebay, how do they end their auctions over time?

How does eBay end its auctions and mark the winner? Suppose that the database has an auction end date, as soon as the current time has passed, the auction should be closed, mark the winner, etc. How does this happen in sql 2005? Do they ask every second to find expired auctions? Obviously, they should mark this as closed as soon as the auction ends. By no means do they create sql jobs for each auction, or are they? Any ideas? I have an integration that follows a similar process of thinking and needs help.

+5
source share
6 answers

Obviously, they need to mark this as closing as soon as the auction ends.

Yes, but not necessarily in real time.

How does it work in sql 2005?

Not at all. A database is a database. To calculate the price / auction in real time, you must use the program. Basically, upgrade the database, but don't run the logic from the database.

Do they ask every second to find expired auctions?

One of the methods. Another is a list of lists sorted by expiration in memory, and just check where they expire.

In no case do they create sql jobs for each individual auction, or are they?

Probably not.

What I would do is keep the list of auctions in mind. Scalability with X auctions per server.

+1
source

. , , , , .

, , , . ( ) . ; .

+1

, EndDate. . Now EndDate. , DB Auction.EndDate Now().

, auction.status="Closed" . , , , , "" . , , .

+1

SQL, . .

Update [Auctions] SET AuctionStatus = 'CLOSED' WHERE CloseDate <= CURRENT_TIMESTAMP;

, where.

, .

0

, , - javascript, , , 0. ajax- script, , , .

0

- /, . , , . "", poiint . , .

0
source

All Articles