Reference no: EM132387166
Question 1 -
You work for ACME products, a retail company that sells 3 sizes of bags of dog food from its warehouse: small bag for $5, medium size bag for $10, and large bags for $15. You have 5 small bags, 3 medium size bags, and 2 large bags in your warehouse. Your remotely located customer (client) will select which kinds of dog food he/she wants to buy, and will pay online.
You will report on the ACME side (server) how many bags of dog food of each size are remaining, and how much money you have collected. You will assume that the customer always pays in multiples of $5, and we will ignore things like exactly how it's done, if the customer selects a $5 payment then a $5 payment will be sent, and we will ignore things like credit cards, etc. You will inform the customer when no more bags of dog food of a particular size are available. You will report all current status on both client and server.
You will do this two ways:
a) Write a small socket program to do the above. Use a command line interface for the customer and for the server.
b) Write a small program using JAX-WS to do the above. Use a command line interface for the customer and for the server.
Question 2 -
Describe the advantages and disadvantages when comparing JAX-WS to sockets. This must be TYPEWRITTEN and turned in along with your program source code and detailed instructions.