g-commerce computational economies for resource allocation in computational grid settings...

42
G-commerce G-commerce Computational economies for resource allocation in Computational economies for resource allocation in computational Grid settings computational Grid settings Fundamentals Fundamentals Resources are not free Resources are not free For convincing resource owners to federate their For convincing resource owners to federate their resources for the Grid resources for the Grid The relative worth of a resource is determined by its The relative worth of a resource is determined by its supply and demand for it. supply and demand for it. 2 economic models 2 economic models Commodities markets – natural since applications treat Commodities markets – natural since applications treat resources as commodities resources as commodities Auctions – easy to implement Auctions – easy to implement Evaluation criteria Evaluation criteria Price stability – i.e. fluctuations of price – price Price stability – i.e. fluctuations of price – price stability for scheduling stability stability for scheduling stability Equilibrium – degree to which prices are fair – Equilibrium – degree to which prices are fair – trustworthiness trustworthiness Application efficiency Application efficiency Resource efficiency Resource efficiency

Upload: scot-franklin

Post on 24-Dec-2015

214 views

Category:

Documents


1 download

TRANSCRIPT

G-commerceG-commerce

Computational economies for resource allocation in computational Grid Computational economies for resource allocation in computational Grid settingssettingsFundamentalsFundamentals

Resources are not freeResources are not free For convincing resource owners to federate their resources for the GridFor convincing resource owners to federate their resources for the Grid The relative worth of a resource is determined by its supply and demand for it.The relative worth of a resource is determined by its supply and demand for it.

2 economic models2 economic models Commodities markets – natural since applications treat resources as Commodities markets – natural since applications treat resources as

commoditiescommodities Auctions – easy to implementAuctions – easy to implement

Evaluation criteriaEvaluation criteria Price stability – i.e. fluctuations of price – price stability for scheduling stabilityPrice stability – i.e. fluctuations of price – price stability for scheduling stability Equilibrium – degree to which prices are fair – trustworthinessEquilibrium – degree to which prices are fair – trustworthiness Application efficiencyApplication efficiency Resource efficiencyResource efficiency

Commodity Markets and AuctionsCommodity Markets and Auctions

Commodity MarketsCommodity Markets A third-party (market) sets a price for resources and asks A third-party (market) sets a price for resources and asks

producers and consumers willing to agree to that priceproducers and consumers willing to agree to that price The participants engage in transactionsThe participants engage in transactions Based on unsatisfied demands and supplies, new prices are setBased on unsatisfied demands and supplies, new prices are set Consumers don’t ask for specific commodity but chooses one Consumers don’t ask for specific commodity but chooses one

out of many equivalentsout of many equivalents An attempt is made to satisfy all bidders and sellers at a given An attempt is made to satisfy all bidders and sellers at a given

priceprice

AuctionsAuctions A third-party (auctioneer) collects resources and bidsA third-party (auctioneer) collects resources and bids Highest bidder gets a resource per auction roundHighest bidder gets a resource per auction round Prices are set based on bidsPrices are set based on bids Process repeated for other resourcesProcess repeated for other resources Consumers ask for specific commoditiesConsumers ask for specific commodities One bidder and one seller satisfied at a given priceOne bidder and one seller satisfied at a given price

Producer and Consumer ModelsProducer and Consumer Models

Producer modelProducer model CPUCPU DiskDisk Producer will sell all of its remaining capacities at a given Producer will sell all of its remaining capacities at a given

price point if it will turn a profit with respect to average profit price point if it will turn a profit with respect to average profit over timeover time

Consumers and jobsConsumers and jobs Consumers are given initial budget and periodic allowancesConsumers are given initial budget and periodic allowances Budgets are refreshed at periodic intervalsBudgets are refreshed at periodic intervals Consumers and producers agree on a price and during each Consumers and producers agree on a price and during each

simulated minute, the producer’s revenue is incremented and simulated minute, the producer’s revenue is incremented and consumer’s budget is decrementedconsumer’s budget is decremented

Consumers will place demand only if the capable_rate is >= Consumers will place demand only if the capable_rate is >= avg_rateavg_rate

Producer and Consumer ModelsProducer and Consumer Models

SummarySummary Producers consider long term profit and past Producers consider long term profit and past

performance when deciding to sellperformance when deciding to sell Consumers are given periodic budget Consumers are given periodic budget

replenishments and spend opportunisticallyreplenishments and spend opportunistically Consumers introduce work load in bulk at the Consumers introduce work load in bulk at the

beginning of each simulated day, and randomly beginning of each simulated day, and randomly throughout the daythroughout the day

Commodities market and dynamic Commodities market and dynamic pricingpricing

Pricing methodology for market economyPricing methodology for market economyPricing methodology should produce a system of Pricing methodology should produce a system of price adjustments which bring about market price adjustments which bring about market equilibriumequilibriumMarket economy is a system involving Market economy is a system involving producers, consumers, several commodities, producers, consumers, several commodities, supply and demand functions for each supply and demand functions for each commodity determined by the set of market commodity determined by the set of market prices for various commoditiesprices for various commoditiesA unique equilibrium price is guaranteed to exist A unique equilibrium price is guaranteed to exist in this frameworkin this framework

CommoditiesCommodities

Commodity prices represented by price Commodity prices represented by price vector, p.vector, p.

zzjj - Excess demand for the j - Excess demand for the jthth commodity, commodity,

i.e. demand minus supplyi.e. demand minus supply

Each zEach zj j is a function of all prices pis a function of all prices pii

Smale’s theorem: an equilibrium point with Smale’s theorem: an equilibrium point with p* such that excess demand vector z(p*) = p* such that excess demand vector z(p*) = 0 exists0 exists

Commodities Market FormulationCommodities Market Formulation

A nxn matrix of partial derivatives A nxn matrix of partial derivatives

Smale’s method: With Smale’s method: With λλ same sign as determinant of D same sign as determinant of Dzz(p), economic (p), economic equilibrium can be obtained by - equilibrium can be obtained by -

Lamda = 1 ; Euler discretization at positive values of t; reduces the Lamda = 1 ; Euler discretization at positive values of t; reduces the process toNewton Raphson method for solving z(p) = 0process toNewton Raphson method for solving z(p) = 0

Approximate each excess demand function zApproximate each excess demand function zi by a polynomial in by a polynomial in p1,p2,…pnp1,p2,…pnUse partial derivates of the polynomialsUse partial derivates of the polynomialsHigh polynomial of degree 17 was usedHigh polynomial of degree 17 was usedThis procedure is called first bank of G methodThis procedure is called first bank of G method

AuctionsAuctions

When an application desires multiple When an application desires multiple commodities, it places multiple bids on commodities, it places multiple bids on multiple auctions and obtains some of the multiple auctions and obtains some of the resourcesresourcesIt expends currency on the obtained It expends currency on the obtained resources while it waits for other resourcesresources while it waits for other resourcesAuctions are highly unreliable in terms of Auctions are highly unreliable in terms of pricing and ability to obtain resource – pricing and ability to obtain resource – leads to poor scheduling decisionsleads to poor scheduling decisions

Simulations of auctionsSimulations of auctions

At each time step, CPU and disk producers At each time step, CPU and disk producers submit their unused slots, minimum selling price submit their unused slots, minimum selling price (average profit / slot) to auctioneers(average profit / slot) to auctioneersConsumers define bid prices based on demand Consumers define bid prices based on demand functions and bid on each commodity needed by functions and bid on each commodity needed by their jobstheir jobsHighest bidding customer gets commodityHighest bidding customer gets commodityPrice of the commodity – average of Price of the commodity – average of commodity’s minimum selling price and commodity’s minimum selling price and consumer’s bid priceconsumer’s bid price

Simulation experimentsSimulation experiments2 scenarios2 scenarios

Under-demand – producers can Under-demand – producers can adequately support consumersadequately support consumers

Over-demand – consumers wish to Over-demand – consumers wish to buy more resources than availablebuy more resources than available

Simulation settingSimulation setting Under-demandUnder-demand

100 consumers to use 100 CPUs 100 consumers to use 100 CPUs and disksand disksEach consumer submitted random Each consumer submitted random number of jobs (between 1 to 100) number of jobs (between 1 to 100) at every simulated day breakat every simulated day break10% chance of submitting new job 10% chance of submitting new job every time unitevery time unit

Over-demandOver-demand500 of the same consumers500 of the same consumers

Market equilibrium – commodity Market equilibrium – commodity markets: Illustration of equilibrium markets: Illustration of equilibrium

by Smale’s methodby Smale’s method

Market equilibrium - auctionsMarket equilibrium - auctions

Variance in prices due to Variance in prices due to different prices paid by different prices paid by different bidders increase different bidders increase over time – i.e. price over time – i.e. price becomes less stable over becomes less stable over timetimeSpikes in workload are Spikes in workload are not reflected in price.not reflected in price.Disk prices are identical Disk prices are identical even though they are even though they are plentiful in number – plentiful in number – should be low-priced.should be low-priced.

Market equilibrium - SummaryMarket equilibrium - Summary

Smale’s method is appropriate for modeling hypothetical Smale’s method is appropriate for modeling hypothetical Grid marketGrid marketFirst bank of G reasonable and implementable First bank of G reasonable and implementable approximationapproximationAuctioneering attractive from implementation standpointAuctioneering attractive from implementation standpointBut does not produce stable pricing or market But does not produce stable pricing or market equilibriumequilibriumGrid resource allocation decisions based on Grid resource allocation decisions based on auctioneering lack fairnessauctioneering lack fairnessCommodities market formulation perform better from the Commodities market formulation perform better from the standpoint of Grid as a wholestandpoint of Grid as a wholeOver-demand case performed similar to under-demandOver-demand case performed similar to under-demand

Efficiency resultsEfficiency results

Utilization of Utilization of resources from resources from supplier standpointsupplier standpoint

Number of jobs Number of jobs completed / time unit completed / time unit from consumer from consumer standpointstandpoint

Other Pricing ModelsOther Pricing Models

Posted Price ModelPosted Price Model Special offers to motivate users to utilize unused slotsSpecial offers to motivate users to utilize unused slots

Bargaining ModelBargaining ModelTender/contract-net modelTender/contract-net modelBid-based proportional resource sharing modelBid-based proportional resource sharing model Used in cooperative resource sharing environmentsUsed in cooperative resource sharing environments

Share-holders modelShare-holders model When users are both service providers and When users are both service providers and

consumersconsumers

MonopolyMonopoly

An Incentive-based Grid An Incentive-based Grid SchedulingScheduling

Resource ConsumersResource Consumers Job length, job deadlineJob length, job deadline

Resource ProvidersResource Providers Capability, unit price and job queueCapability, unit price and job queue

Scheduling objectiveScheduling objective Provide QoS to consumers. Highly successful Provide QoS to consumers. Highly successful

(without missing deadline) execution rate of job(without missing deadline) execution rate of job Reasonable profit for providers. Fair allocation of Reasonable profit for providers. Fair allocation of

benefits, i.e. the profit of every provider is proportional benefits, i.e. the profit of every provider is proportional to its investment or costto its investment or cost

Overall DesignOverall Design

Peer-2-peer gridPeer-2-peer gridStep 1 – a consumer submits job Step 1 – a consumer submits job announcement, broadcast to all providersannouncement, broadcast to all providersStep 2 - Provider estimates whether it is able to Step 2 - Provider estimates whether it is able to meet deadline. Yes- provider sends a bid meet deadline. Yes- provider sends a bid containing the charge for the jobcontaining the charge for the jobStep 3 - Consumer processes all the bids and Step 3 - Consumer processes all the bids and chooses the provider with the least charge. chooses the provider with the least charge. Sends jobSends jobStep 4 - Provider queues it, executes and sends Step 4 - Provider queues it, executes and sends resultsresults

Job Competing Algorithm for Step 2Job Competing Algorithm for Step 2

How a provider bids. Job competing algorithmHow a provider bids. Job competing algorithmAfter a provider has sent its bid to previous job After a provider has sent its bid to previous job (unconfirmed job), when a job announcement comes for (unconfirmed job), when a job announcement comes for a new job, should it consider the previous job for a new job, should it consider the previous job for deciding on whether to bid for the new job?deciding on whether to bid for the new job?Parameter Parameter αα, conservation degree, conservation degreeαα = 0, aggressive. Don’t consider unconfirmed jobs when = 0, aggressive. Don’t consider unconfirmed jobs when estimating whether it will meet a new job deadlineestimating whether it will meet a new job deadlineαα = 1, conservative. Consider unconfirmed jobs when = 1, conservative. Consider unconfirmed jobs when estimating whether it will meet a new job deadlineestimating whether it will meet a new job deadline

Job competing algorithmJob competing algorithm

Invoked when a producer receives a bidInvoked when a producer receives a bidStep 1 – provider estimates whether it is able to meet the Step 1 – provider estimates whether it is able to meet the job deadlinejob deadline

placeplace00 to place to placenn – n+1 possible places for inserting a new – n+1 possible places for inserting a new job Jjob Jn+1n+1

Available time – when all jobs in queue will be completedAvailable time – when all jobs in queue will be completedT = (deadline – execution time) latest time by which job T = (deadline – execution time) latest time by which job has to start to meet deadlinehas to start to meet deadline

AlgorithmAlgorithm

If can_meet = true; go to step 2If can_meet = true; go to step 2

Job Competent AlgorithmJob Competent Algorithm

Step 2 – provider fixes a price for the jobStep 2 – provider fixes a price for the job

Step 3Step 3 provider sends the price as the bidprovider sends the price as the bid Inserts in insert_place with a probability CDInserts in insert_place with a probability CD If job offer doesn’t come after some time, If job offer doesn’t come after some time,

deletes it from the queuedeletes it from the queue

Heuristic Local Scheduling Heuristic Local Scheduling Algorithm for step 3Algorithm for step 3

If CD is not 1 (conservative), jobs may miss deadlineIf CD is not 1 (conservative), jobs may miss deadlineHence, need for a punishment mechanism to producers Hence, need for a punishment mechanism to producers for missing deadlinesfor missing deadlines

Hence providers need mechanisms to minimize lossHence providers need mechanisms to minimize lossOne way – try all permutations of job ordering and One way – try all permutations of job ordering and choose the one with minimum penalty – NP completechoose the one with minimum penalty – NP completeA heuristic algorithm that is invoked every time a A heuristic algorithm that is invoked every time a producer is offered a job that it has not kept in the queueproducer is offered a job that it has not kept in the queue

AlgorithmAlgorithm

Price AdjustmentsPrice Adjustments

Initially, a market price for a commodity is Initially, a market price for a commodity is fixedfixed

When a provider enters the grid, gets this When a provider enters the grid, gets this market price and uses it as initial unit pricemarket price and uses it as initial unit price

Every time a provider is offered a job or Every time a provider is offered a job or deletes an unconfirmed job, invokes the deletes an unconfirmed job, invokes the price adjustment algorithmprice adjustment algorithm

AlgorithmAlgorithm

Offered_job_length – aggregated length of jobs offered Offered_job_length – aggregated length of jobs offered to the providerto the providerTotal_job_length – aggregated length of jobs whose Total_job_length – aggregated length of jobs whose announcements have been received by the producerannouncements have been received by the producer

Simulation SetupSimulation Setup

20 consumers, 80 producers20 consumers, 80 producers

Fixed values forFixed values for Average lengths of jobsAverage lengths of jobs Average of capabilities of providersAverage of capabilities of providers λλ,,αα,,ββ Market priceMarket price Different system loadsDifferent system loads CD – 0, 0.5, 1CD – 0, 0.5, 1

Incentive of ConsumersIncentive of Consumers

Based on 2 metricsBased on 2 metrics

A job fails because all providers decide not to A job fails because all providers decide not to bidbid

ResultsResults

Failure rate increases with higher system Failure rate increases with higher system load and when the producers are more load and when the producers are more conservativeconservative

Deadline missing rate increases with Deadline missing rate increases with higher system and when the producers are higher system and when the producers are more aggressivemore aggressive

ResultsResults

Deadline missing rate hasDeadline missing rate has

much lesser impact. Hencemuch lesser impact. Hence

conservative is not goodconservative is not good

Incentive for ProvidersIncentive for Providers

Penalty of providers increases as CD Penalty of providers increases as CD decreasesdecreases

For total profit, tradeoff CD of 0.5 is goodFor total profit, tradeoff CD of 0.5 is good

FairnessFairness

Should be close to 1.Should be close to 1.

Intuitively, aggressiveIntuitively, aggressive

competing ensurescompeting ensures

fairness; items are mostlyfairness; items are mostly

sold at low base pricesold at low base price

Game-Theory Based Pricing StrategyGame-Theory Based Pricing Strategy

Pricing strategy implemented between job Pricing strategy implemented between job allocator and nodes using game theoretic allocator and nodes using game theoretic frameworkframeworkThe 2 players are job allocator and nodesThe 2 players are job allocator and nodesThey play incomplete information, alternating-They play incomplete information, alternating-offers, noncooperative, bargaining game to offers, noncooperative, bargaining game to decide ondecide on Price per unit resourcePrice per unit resource Percentage of bandwidth that can be used on the link Percentage of bandwidth that can be used on the link

between job allocator and nodesbetween job allocator and nodes

If there are n nodes, a JA plays a game with If there are n nodes, a JA plays a game with each of the n nodes to form vectors of price and each of the n nodes to form vectors of price and percentage bandwidthpercentage bandwidth

Incomplete InformationIncomplete Information

Two players have no idea of each other’s Two players have no idea of each other’s reserved valuationsreserved valuationsJAJA Maximum offered priceMaximum offered price Minimum bandwidth percentageMinimum bandwidth percentage

NodeNode Minimum expected priceMinimum expected price Maximum bandwidth percentageMaximum bandwidth percentage

Both can make surplus or profit and try to reach Both can make surplus or profit and try to reach a mutually beneficial arrangementa mutually beneficial arrangement

Rules for JARules for JA

Rule 1 – at each step of the game, both Rule 1 – at each step of the game, both players choose the alternative earning players choose the alternative earning them highest expected pricethem highest expected priceExpected utility = [(reserved valuation of JA – offered price) + Expected utility = [(reserved valuation of JA – offered price) + (offered percentage of bandwidth – minimum percentage)] x (offered percentage of bandwidth – minimum percentage)] x probability(offered price, percentage of bandwidth offered)probability(offered price, percentage of bandwidth offered)

Probability – that the tuple will be accepted Probability – that the tuple will be accepted by the opponentby the opponent

Rules for JARules for JA

Rule 2 – on rejection of an offer, JA and the Rule 2 – on rejection of an offer, JA and the node reduce the probabilitynode reduce the probability Reduction decreases as alternatives come closer to Reduction decreases as alternatives come closer to

their reserved valuationstheir reserved valuations

Rule 3 – demands of JA and the node are Rule 3 – demands of JA and the node are decreased over timedecreased over time

ee-z-z{w,m}{w,m}

tt denotes discount rates of JA and node. denotes discount rates of JA and node.

ThusThusExpected utility = [(reserved valuation of JA – offered price) + (offered Expected utility = [(reserved valuation of JA – offered price) + (offered percentage of bandwidth – minimum percentage)] x probability(offered percentage of bandwidth – minimum percentage)] x probability(offered price, percentage of bandwidth offered) x eprice, percentage of bandwidth offered) x e-z-z

wwtt

Attributes of JAAttributes of JA

Utility Functions for Pricing Strategy Utility Functions for Pricing Strategy for JAfor JA

If JA accepts the current offer, its expected If JA accepts the current offer, its expected utility is:utility is:

Utility Functions for Pricing Strategy Utility Functions for Pricing Strategy for JAfor JA

If JA rejects the opponent’s offer and If JA rejects the opponent’s offer and breaks down from the game:breaks down from the game:

Utility Functions for Pricing Strategy Utility Functions for Pricing Strategy for JAfor JA

In case of counteroffer:In case of counteroffer:

References / Sources / CreditsReferences / Sources / Credits

Wolski, R., Plank, J., Brevik, J, and Bryan, T., G-Wolski, R., Plank, J., Brevik, J, and Bryan, T., G-Commerce: Market Formulations Controlling Resource Commerce: Market Formulations Controlling Resource Allocation on the Computational Grid (PDF), IPDPS 01, Allocation on the Computational Grid (PDF), IPDPS 01, March, 2001.March, 2001.Buyya et. al. Economic Models for Resource Buyya et. al. Economic Models for Resource Management and Scheduling in Grid Computing. Management and Scheduling in Grid Computing. Concurrency and Computation. Practice and Experience. Concurrency and Computation. Practice and Experience. 2002. 14: 1507-1542.2002. 14: 1507-1542.GridIS: An Incentive Based Grid Scheduling. Xiao et. al. GridIS: An Incentive Based Grid Scheduling. Xiao et. al. IPDPS 2005IPDPS 2005A Game Theory-Based Pricing Strategy to Support A Game Theory-Based Pricing Strategy to Support Single/Multiclass Job Allocation Schemes for Bandwidth-Single/Multiclass Job Allocation Schemes for Bandwidth-Constrained Distributed Computing Systems. Ghosh et. Constrained Distributed Computing Systems. Ghosh et. al. TPDS 2007.al. TPDS 2007.

JUNK!JUNK!

DifferencesDifferences

In commodity markets, an attempt is made In commodity markets, an attempt is made to satisfy all bidders and sellers at a given to satisfy all bidders and sellers at a given priceprice

In auctions, one bidder and seller is In auctions, one bidder and seller is satisfied at a given pricesatisfied at a given price