Question: Please implement the inventey management system by using Apache. When each arguments have the unexpected value, the output should be ERROR. The number of the

Please implement the inventey management system by using Apache.
When each arguments have the unexpected value, the output should be "ERROR".
The number of the characters of the products is less than or equal to 8.
Followings are the execution example.
The form of the output is as follows.
 Please implement the inventey management system by using Apache. When each
arguments have the unexpected value, the output should be "ERROR". The number
of the characters of the products is less than or equal to
8. Followings are the execution example. The form of the output is
as follows. Below are the functions implemented for /stocker (1) Addition of
inventory argument: . function (required): addstock o name (required): Specify the name
of the target product. o amount (arbitrary): Specify the number (positive integer)

Below are the functions implemented for /stocker (1) Addition of inventory argument: . function (required): addstock o name (required): Specify the name of the target product. o amount (arbitrary): Specify the number (positive integer) to add the target product to the inventory. The default is 1. Output: None (2) Inventory check argument: function (required): checkstock o name (optional): Specify the name of the target product. Output: . If a name is specified, the number of items in stock with that name is output in the "[name]: [amount]" format. When there is no stock, amount is displayed as 0. When name is not specified, the number of stocks of all products is sorted in ascending order with name as a key and output. Items with O inventory are not displayed. . Example output: O xXx: 12 Wy: 7 (3) Sales argument: function (required): sell o name (required): Specify the name of the target product o amount (arbitrary): Specify the number (a positive integer) of the target product sold. The default is 1. price (optional): Specify the price of the target product (a number greater than o). Only when input, add price x amount to sales. Output: None . (4) Sales check argument: function (required): checksales Output: Displays the current sales in the format "sales: (sales)". For decimal numbers, round up to the second decimal place. Example output: sales: 400 (5) Delete all argument: function (required): deleteall Output: None /stocker o running below returns xxx: 96 $ curl "http://1.2.3.4:8080/stocker?function=deleteall" $ curl "http://1.2.3.4:8080/stocker?function-addstock&name=xxx&amount=100" $ curl "http://1.2.3.4:8080/stocker?function=sell&name=xxx&amount=4" $ curl "http://1.2.3.4:8888/stocker?function=checkstock&name=xxX" o running below returns xxx: 96 yyy: 100 YYY: 100 $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=yyy&amount=100" $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=YYY&amount=100" $ curl "http://1.2.3.4:8080/stocker?function=checkstock" $ curl "http://1.2.3.4:8080/stocker?function=deleteall" $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=xxx&amount=100" $ curl "http://1.2.3.4:8080/stocker?function=sell&name=xxx&amount=4" $ curl "http://1.2.3.4:8080/stocker?function=checkstock&name=xxx" XXX: 96 $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=yyy&amount=100" $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=YYY&amount=100" $ curl "http://1.2.3.4:8080/stocker?function=checkstock" YYY: 100 XXX: 96 yyy: 100 $ curl "http://1.2.3.4:8080/stocker?function=deleteall" $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=xxx&amount=1.1" ERROR $ curl "http://1.2.3.4:8080/stocker?function=deleteall" $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=aaa&amount=10" $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=bbb&amount=10" $ curl "http://1.2.3.4:8080/stocker?function=sell&name=aaa&amount=4&price=100" $ curl "http://1.2.3.4:8080/stocker?function=sell&name=aaa&price=80" $ curl "http://1.2.3.4:8080/stocker?function=checkstock&name=aaa" aaa: 5 $ curl "http://1.2.3.4:8080/stocker?function=checksales" sales: 480 $ curl "http://1.2.3.4:8080/stocker?function=deleteall" $ curl "http://1.2.3.4:8080/stocker?function=addstock&name=xxx&amount=1.1" ERROR

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!