Home

Final Report - ORCA-USA

image

Contents

1. 22 Table 3 2 3 Helper Classes used in CPS iPhone App Component ceeeeeeneeeeeenee 22 T ble 3 2 4 Classes of BLL Component ctra di td 24 Table 3 2 5 Classes of DAL COMPU A eee ae 26 Table 4 4 1 Formal Inspection Checklist 4o Ee aes RI ita 48 Table 5 2 1 Operation specification of CPSServices Class ccece cece eee ee eee eee ene eens 50 Table 5 3 1 Attributes of PlanSummary Class ccecceeeee ence cence ence eeeeeeneeneaeenaeenes 53 Table 5 3 2 Operation specification of PlanSummary Class eese 53 Table 5 3 3 Attributes of CPSAnalysis Class c cece cece ence eee e eee e eee nee enne nnne 54 Table 5 3 4 Operation specification of CPSAnalysis Class eee 54 Table 5 4 1 Attributes of Region C 13582 iore a 56 Table 5 4 2 Operation specification of Region Class cc cece eee eee eect ne eneenae en een anes 56 Table 5 4 3 Attributes of land Type Class A E PE 24 Table 5 4 4 Operation specification of LandType ClaSS ooococcccccoccocconcconcnnccnncnncnnconnrnns 37 Table 5 4 5 Attributes of CropDesce Class ie eee eee eren Fn M ESSE VET e 58 Table 5 4 6 Operation specification of CropDesc Class cc ccce ence ence eee e eee eenneeaeaes 58 Table 5 4 7 Attributes of Income Classes vvicv cesses tere a dd 60 Table 5 4 8 Operation specification of Income Class eese 60 Table 5 4 9 Attributes of Cost Classic e
2. 112 3 1 5 5 Summary Details and Print The summary along with its breakdown will be available for each plan in the Summary Details tab The whole farm profitability return over cost for multiple plans will also be summarized in a graph for easy comparison with best worst estimates when expected variation value is entered User may print the detailed report by clicking on Print icon Life is like riding a bike To keep your balance you must keep moving Albert Einstein PAANAGER INFO WHOLE FARM Home Simulator FAQ Contact Us About CPS Location of the land NorhEast Y E Te Plan 1 Jl Plan 2 Plan 3 Plan 4 Summary Details E RETURN OVER COST USD Acre Plan 1 156 99 45 Cost 5 Yield 5 Price 5 Plan 2 241 175 112 Cost 5 Yield 5 Price 5 Plan 1 Plan 2 Built using ChartFX for NET Development SUMMARY PLAN 1 SUMMARY PLAN 2 Crop Acres Income Cost Return Over Cost Crop Acres Income Cost Return Over Cost Corn 100 345 291 54 Alfalfa 100 345 291 54 237 191 45 Wheat 100 331 209 Soybeans 100 121 Farm Per Acre 291 241 50 Farm Per Acre 338 250 88 582 as3 99 Farm Total 200 676 501 Farm Total 200 175 SUMMARY DETAILS PLAN 1 INCOME PER ACRE INCOME PER ACRE 113 3 2 CPS iPhone Application Operation 3 2 1 Simulator Since the iPhone application is not packaged b
3. Software Component Test Case Requirements Tested Results Comments CPS Web App TS 01 SR 3 1 1 Pass TS 02 SR 3 1 2 Pass TS 03 SR 3 1 3 Pass TS 04 SR 3 1 4 Pass TS 05 SR 3 1 5 1 SR 3 1 5 2 SR Pass 3 1 5 3 SR 3 1 5 4 CPS iPhone App TS 06 SR 3 2 1 1 SR 3 2 1 2 SR Pass 3 2 1 3 SR 3 2 1 4 3 Detailed Test Results 3 1 Test Results of CPS Web Application Table 8 3 1 Test Results of Test Suite 1 TS 01 Test Description Expected Outcome Actual Outcome TS1 1 Using your favorite browser The main home page should be Loaded hit the CPS web app at loaded successfully without any successfully http home nabi us CpsWeb error TS1 2 Click on each hyper links All links should render page All links were located on top navigation bar without any errors clicked and of the main Home page loaded successfully 79 TS 1 3 Click on Crop Profitability Simulator image It will bring up Simulator application without any error Simulator application loaded successfully Table 8 3 2 Test Results of Test Suite 2 TS 02 Test Description Expected Outcome Actual Outcome TS2 1 Clink on FAQ link FAQ page should be loaded FAQ page is located on the top without any error loaded navigation bar successfully TS2 2 Click on each questions of It should render the answer of the Clicking on the FAQ page question you have just cl
4. Post give user record not found message if record does not exists Load Signature public bool Load double seed double herbicide double insecticide double fertilizer double consulting double insurance double drying double miscellaneous double machineryExpense double nonMachineryLabor double irrigationLabor double irrigationFuel double irrigationRepair double depreciationOnEquipment double interestOnEquipment double landCharge double interestOnNonLandCost double costChange Description It loads the Cost object Returns to true if all data passed in is valid and load successful Otherwise return false Usage This method is used by Web client where user is allowed to have custom income data applied to user s farm Behavior Pre Passed in data is valid Pre a record should exists in the table class represent Post return true load successful meaning all data valid Otherwise return false Post give user Invalid data message if load unsuccessful 4 7 CropType Class 4 7 1 Description This class represents Crop type e g Conventional organice and responsible to make operation to physical data table CropType This class is used to populate Crop type in plan configuration UI 4 7 2 Attributes Table 5 4 11 Attributes of CropType Class Name Type Description cropTypld Int CropTypes ID Name String Description of CropType e g Con
5. Behavior Pre Passed in data is valid 50 Post return datatable with CpsSummary data Post if invalid data found return null and give user invalid data message 3 Business Logic Layer Component BLLC This section provides class diagram of Business Logic Layer Component and detailed description of each class BLLC is responsible implement business rules and communicate with DALC to query or save information to Physical CPS database Figure 5 3 1 Class diagram of Business Logic Layer Component 3 1 PlanSummary 3 1 1 Description This user defined data structure helps to represent plan summary data displayed with user configure a plan In this project the PlanSummary BLL class is used by web client only The method GetPlanSummaryData is used to return dataset to display complete plan summary 3 1 2 Attributes Table 5 3 1 Attributes of PlanSummary Class Name Type Description planName string Plan Description cropName string Crop Name acreAmount int Crop Acre 51 incomeAmount double Income Amount costAmount double Cost Amount returnOverCost double Profit the return over cost 3 1 3 Operation Specification of non getter setter constructor method Table 5 3 2 Operation specification of PlanSummary Class Method Name Description GetPlanSummary Signature public DataTable GetPlanSummaryDa
6. TS3 2 Click on the email link given in the contact us page It should automatically load your default email client populated email address in To field Table 7 9 4 Test Suite 4 SR 3 1 4 About CPS Test Description Expected Outcome Actual Outcome TS4 1 Clink on About CPS link located on the top navigation bar The About CPS page should be loaded without any error The information should contain name of the product version and copy write information 73 Table 7 9 5 Test Suite 5 Covers from SR 3 1 5 1 to SR 3 1 5 4 Test Description Expected Outcome Actual Outcome TS5 1 Click on Simulator link located at the top navigation bar The simulator should load without any errors TS5 2 In the location of the land Nothing should change at the UI drop down list change region to North West TS5 3 Click on the Y icon next Greater Kansas map should be to location of the land drop displayed drown TS5 4 Click on X hyperlink Popup window should be closed located on the top right corner of the popup window just opened in TS5 3 TS5 5 In Planl tab select number Based on your selected value page of Crop that you would like should be updated with Crop Crop to configure for your plan System Land Type and Total area for each crop with default value populated A summary tabl
7. Document 1 0 2 3 4 5 and section 3 2 in vision document 6 invariants to holds violates Document 1 0 af Test CPS Software and verify that it meets all functional requirements CPS Software stated in section 3 1 and 3 2 in vision document 131 Appendix B Formal Inspection Letter of Amit Borcar April 23 2010 Re Formal Inspection letter for Reza Nabi s MSE Project Dear Dr Andresen I have completed the Formal Technical Inspection for Reza Nabi s MSE project as per the checklist provided in Formal Inspection Checklist Document 1 0 I found everything satisfactory All items in the checklist passed Regards Amit Borcar Software Engineer Sage Software Email amit borcar dsage com 132 Table 1 1 Results of Formal Inspection Checklist eat inspection em rift euis Comment TI 1 The symbols used in the class Architectural diagrams conform to UML Design Document standards 1 0 TI2 The symbols used in the sequence Architectural diagrams state machine diagram Design Document use case diagram conforms to UML 1 0 standards TL3 The symbols used in the component Architectural view diagram conforms to UML Design Document standards 1 0 TL4 The symbols used in deployment Architectural diagram conforms to UML Design Document standards 1 0 TLS The USE model associations and
8. Plan Two configured Clicked on the Summary and verified that Return Over Cost was updated automatically for newly configured Plan Two Verified that data in the Return Over Cost is identical for both web and iPhone app 86 4 Performance Testing To produce a quality product it is imperative to execute performance testing in order to determine speed scalability and or stability characteristic of the system In performance testing we mostly concentrate on response times throughput and resource level utilization The performance testing helps to identify bottlenecks in the system establish a baseline for future testing support performance tuning efforts and determine compliance with performance goals and requirements In this scenario the tool Jakarta Jmeter is used to do the performance testing especially the load testing of the system for two components web services and web pages and compare the response time 4 1 Response Time Comparison of Web Services The service oriented CPS Software communicates with database via DALC and BLLC via web services Below is the comparison of three major web services along with observation notes Table 8 4 1 Response times by number of user for major web services Number of Users GetPlanSummary GetCPS Analysis CropsByRegion 100 347 32 264 500 1042 986 791 1000 2866 2232 6093 3000 9018 6093 4828 87 Figur
9. tab Over Cost table Details and verified that graph shows horizontal line without any highest and lowest point TS5 10 In the Summary Details It will bring up your print dialogue It fired up print tab click on the amp icon and you should be able to print dialogue and able to print successfully TS5 11 To compare multiple plans As you configure multiple plans Configured both side by side click on you will see that summary table is Plan 1 and Plan1 tab configure your added updated all the plans you Plan 2 plan Enter the appropriate expected variation values may be applicable to your estimate Then Click on have configured Noticed that while configuring plans summary 83 Plan and configure the tables were way you like added automatically TS5 12 Assumed that you have You will see return over cost with After configured multiple plans highest and lowest profit if configuring Click on Summary expected variation is provided for Plan 1 and Details tab all plans side by side along with Plan 2 with the bar graph expected variation system display both plans side by side in the graph as well as Return over Cost table 3 2 Test Results of CPS Phone Application Table 8 3 6 Test Results of Test Suite 6 TS 06 Test Description Expected Outcome Actual Outcome TS6 1
10. 3 1 5 Simulator Click on Simulator link to bring up the main Crop Profitability Simulator CPS application 108 The Whole Farm Crop Profitability Simulator E gt hbttp localhost Cpswebclient Simulator aspx Qr Googe D LI Apple Yahoo GoogleMaps YouTube Wikipedia News 60 v Popular v G Life is like riding a bike To keep your balance you must keep moving Albert Einstein ivit WHOLE FARM Crop Profitability Simulator MAMA sta ha A PA SIMULATOR Location of the land North Central 9 Plan 1 Plan 2 Plan 3 Plan 4 Summary Details Number of Crops E 2008 Kansas State University 3 1 5 1 Configure a Plan Configuring a plan is a 4 step process o Select location of the land o Select how many crops you would like to include in this plan o Enter Crop Crop System Land Type and Crop Acre for each crop o Enter Expected Variation if you would like to see best and worst scenario of your profit return over cost AG WHOLE FARM Crop Profitability Simulator One can succeed at almost anything for which he has enthusiasm Charles Schwab Home Simulator FAQ ContactUs About ces Location of the land NorthEast D O GE 2 Plan 3 Plan 4 Summary Details Number of qup EXPECTED VARIATION PLAN 1 NOTE To view the expected variation in Summary crop 1 Show budget detail per acre Details
11. 50 Farm Total 200 582 483 99 A G Leadership and learning are indispensable to each other John F Kennedy AANASERTFO WHOLE FARM Crop Profitability Simulator Home Simulator FAQ ContactUs About ces SIMULATOR Location of the land North East 0 f Summary Details RETURN OVER COST USD Acre Plan High Mean Low Expected Variation Plan 1 156 99 45 Cost 5 Yield 5 Price 5 Plani Plan 2 Plan al Plan 4 PROFIT USD 2288 T Plan 1 Builtusing ChartFXfor NET Development SUMMARY PLAN 1 trop Acres Income Cost Return Over Cost Corn 100 345 291 54 Soybeans 100 237 191 45 Farm Per Acre 291 241 50 3 1 5 4 Comparing Multiple Plans Configure multiple plan and then click on Summary Details tab This will display comparison of plans you have configured side by side A e Life is like riding a bike To keep your balance you must keep moving Albert Einstein A MANAGER INFO WHOLE FARM op Profitability Simulator Home Simulator FAQ contact us About ces SIMULATOR Location of the land Sap East y 9 E 7 Plan 1 Plan 2 Plan 3 Plan 4C Summary Details RETURN OVER COST USD Acre a 250 Plan High Mean Low Expected Variation Plan 1 156 99 45 Cost 596 Yield 5 Price 5 2 200 Plan 2
12. Load the CPS iPhone app CPS iPhone will be loaded with CPS Phone App either via iPhone simulator two plans and summary tab By loaded TS6 2 Note Testing machine will need to have access to the machine that has web service installed Click on the Summary tab default Plan One will be selected listing the entire region available in our database You will see dialogue popup with successfully It loaded with 2 plans Default was Plan 1 which loaded all the regions to pick to configure the plan Clicked on the 84 without configuring any plan the following information Incomplete plan Please configure at least one plan to view the summary Summary tab and system gave warning Please configure at least one plan to view the summary TS6 3 Click on Plan One tab Application will load plan one Clicked on Plan and click on North West detailed configuration form One and then region without any error with some clicked on default value for users North West convenience region System displayed the detailed plan configuration page TS6 4 Click on the button with This should bring up a window Clicking on down arrow next to Crop where user can select the crop of Down Arrow his plan displayed the list of crops Able to select the crop by clicking the OK button TS6 5 Click on the button wi
13. Miscellaneous Cost machineryExpense double Machinery Expense nonMachineryLabor double Non Machinery Labor irrigationLabor double Irrigation Labor irrigationFuel double Cost of Irrigation Fuel irrigationRepair double Cost of Irrigation Repair depreciationOnEquipment double Depreciation On Equipment Cost interestOnEquipment double Interest paid on Equipment landCharge double Land Charge interestOnNonLandCost double Interest paid on Non Land Cost subTotalCostPerAcre double Calculated field totalCostPerAcre double Calculated average cost highEndCost double Calculated highest cost lowEndCost double Calculated lowest cost 4 6 3 Operation Specification of non getter setter method Table 5 4 10 Operation specification of Cost Class Name Description LoadByCrop Signature public bool LoadByCrop string regionName string cropName string landType string cropType int costChange int yiedLevelId Description It loads the Cost object Returns to true if all data passed in is valid and load successful Otherwise return false Usage This method is used by iPhone client where it only needed to return the default found in the database income value based on the given crop configuration Behavior Pre Passed in data is valid Pre a record should exists in the table class represent Post return true if record exists and load successful Otherwise return false 62
14. Real yieldLevel YieldLevel end ASSOCIATIONS Assocation between Region e g North West South West and Crop association LocationOfCrop between Region 1 role locatedAt Crop 0 role cropsByRegion end 36 Assocation between CropType e g Organic Conventional and Crop association TypeOfCrop between CropType 1 role cropSystem Crop 0 role cropsByType end Assocation between LandType e g Dry Irrigate and Crop association LandTypeOfCrop between LandType 1 role typeOfLand Crop 0 role cropsByLandType end Association between Crop Description and Crop association DescriptionOfCrop between CropDesc 1 role cropName Crop 0 role cropsByCropDesc end For each crop system should have at least one Income It also makes sure Income does not have more than 3 One for each yield level e g Average High Low association CropIncomeMap between Crop 1 role cropPointsTo Income 1 3 role incomeData end For each crop system should have at least one cost It also makes sure Cost does not have more than 3 One for each yield level e g Average High Low association CropCostMap between Crop 1 role cropPointsTo Cost 1 3 role costData end 37 CONSTRAINTS constraints cropId in Crop must be unique Constraints No 1 context crp1 Crop inv CropIdIsUnique Crop allInstances forAll crp2lcrpl cropId crp2 cropId implies crpl crp2 System mus
15. TS5 10 In the Summary Details It will bring up your print dialogue tab click on the amp icon and you should be able to print TS5 11 To compare multiple plans As you configure multiple plans side by side click on Plan1 tab configure your plan Enter the appropriate expected variation values may be applicable to your estimate Then Click on Plan and configure the way you like you will see that summary table is added updated all the plans you have configured 75 TS5 12 Assumed that you have configured multiple plans Click on Summary Details tab You will see return over cost with highest and lowest profit if expected variation is provided for all plans side by side along with the bar graph 9 2 CPS iPhone Application Testing Tasks Table 7 9 6 Test Suite 46 Covers SR 3 2 1 1 to SR 3 2 14 Test Description Expected Outcome Actual Outcome TS6 1 Load the CPS iPhone app either via iPhone simulator Note Testing machine will need to have internet access to communicate with backend server via web services CPS iPhone will be loaded with two plans and summary tab By default Plan One will be selected listing the entire region available in our database TS6 2 Click on the Summary tab You will see dialogue popup with without configuring any the following information plan Incomplete pl
16. locations region of crop in both clients 4 1 2 Attributes Table 5 4 1 Attributes of Region Class Name Type Description regionld Int Region s ID name String Description of Region e g North West 4 1 3 Operation Specification of non Getter Setter Constructor method Table 5 4 2 Operation specification of Region Class Name Description Load Signature public bool Load int id Description It loads the Region object Returns to true if data passed in is valid and load successful Otherwise return false Behavior Pre Passed in data is valid Pre a record should exist in region table by the id passed in Post return true if record exists and load successful Otherwise return false Post give user record not found message if record does not exists FindAll Signature public DataTable FindAll Description It finds all the regions available in Region table and returns the datatable of regions Behavior Pre None Post return list of regions found in the system Post If no region exists then return null and give user record 29 not found message 4 2 LandType Class 4 2 1 Description This class represents type of the land e g Dry Irrigated etc and responsible to make operation to physical data table LandType This class is used to populate land type in plan configuration UI 4 2 2 Attributes Table 5 4 3 Attributes of Land
17. 2 Cost all Carrier gt Plan Crop High Mean Low One Corn 67 54 41 Two Wheat 134 121 109 Plan Expected Variation One Cost 2 Price 2 Yield 2 Two Cost 2 Price 2 Yield 2 Comparing return over cost of Plan 1 and Plan 2 side by side with best and worst scenarios 119 4 FAQ and Troubleshooting This section provides information on frequently asked problems and how to troubleshoot the reported problem 4 1 CPS iPhone Frequently Asked Question FAQ 4 1 1 When launching the iPhone application I get service not available error What should I do CPS Error Sorry the Web Service is currently unavailable Please report this to reza ksu edu Answer Open CPS Info plist file and make sure the ServiceURL and Service Namespace is configured correctly as per your installation eoo Key Value v Information Property List 14 items Localization native development re English Bundle display name CPS 1 0 Executable file S EXECUTABLE NAME Icon file aglogo png ServiceURL http rnd CpsWebService CPSServices asmx ServiceNameSpace http agmanager info Bundle identifier com yourcompany PRODUCT_NAME rfc 103 4identifier InfoDictionary version 6 0 Bundle name PRODUCT_NAME Bundle OS Type code APPL Bundle creator OS Type code nN Bundle version 1 0 Application requires iPhone enviror M Main nib file base name MainWindow 120 4 1 2
18. 340 86 414 59 lg COSTS PER ACRE 20 1 Seed 12 12 12 12 12 12 Ell 2 Herbicide 15 11 23 94 23 94 El 3 Insecticide Fungicide d 0 00 0 00 0 00 El 4 Fertilizer and Lime 34 21 44 77 54 37 E 5 Crop Consulting 0 00 0 00 0 00 25 6 Crop Insurance 0 00 0 00 0 00 Eas 7 Drying 9 10 11 70 14 30 Ea 8 Miscellaneous di 6 25 6 25 6 25 a 9 Custom Hire Machinery Expense 63 42 69 32 75 22 29 10 Non machinery Labor 7 17 7 83 8 50 30 11 Irrigation En a Labor 0 00 0 00 0 00 El b Fuel and Oil 0 00 0 00 0 00 E c Repairs and Maintenance 0 00 0 00 0 00 E d Depreciation on Equipment Well 0 00 0 00 0 00 35 e Interest on Equipment 0 00 0 00 0 00 36 12 Land Charge Rent 42 40 53 00 63 60 37 G SUBTOTAL 189 78 228 93 258 30 lag 13 Interest on 1 2 Nonland Costs 5 88 6 98 7 67 R H TOTAL COSTS 195 65 235 91 265 97 40 1 RETURNS OVER COSTS F H 71 47 104 95 148 62 414 X J TOTAL COSTS BUSHEL H A 2 80 2 62 2 42 a K RETURN TO ANNUAL COST I 13 G 40 76 48 89 60 51 2 Project Overview The proposed software The Whole Farm CPS allows farmers in Kansas and surrounding states to assess market risks for multiple farming plans including conventional and organic farming methods The goal of this project is to improve upon the legacy system and implement new features to facilitate scalability robustness integration and improved usability The Whole Farm CPS shall be accessible on two operating
19. Median 12805 91 Figure 8 4 5 Summary Report of 1000 users with 5 loop count and 5 secs ramp up E Simulator jmx C CIS Simulator jmx Apache JMeter 2 3 4 1785646 File Edit Run Options Help 0 1000 bg amp Test Plan E Simulator Summary Report Mit HTTP Request Detal Name summary Report 5 Summary Report Comments f Simulator e 3 Write results to file Read from file aq 2 Home Filename Browse Log Display Only _ Errors Successes Configure E Graph Results 8 WorkBench Samples Average Min Max Std Dev Error Throughput KBisec Avg Bytes 5000 18930 1827 46943 10474 00 0 00 22 2isec 992 66 45780 0 5000 18823 16 30081 6109 94 0 00 24 4 sec 676 98 28438 0 5000 6179 2 29072 3433 79 0 00 28 6 sec 272 88 9782 0 15000 14644 2 45943 9421 73 0 00 66 6 sec 1821 24 28000 0 v Include group name in label Save Table Data Overall Observation With the above 4 scenarios it is clear that with the current architecture and having the system deployed in mid end machine software should be able to handle 1000 one thousand users very easily With having CPS Software deployed in good production level machine with dedicated DB server it can certainly entertain sudden burst of couple of thousands users within 1 to 2 mins of time without any difficulty Unit Testing In an effort to maintain the quality of the code as well a
20. Notice that response time of FAQ page is higher than Home page This is because of the size of the FAQ page which is 28KB with all questions answers along with lots of images 4 3 Comparison of Response Time of 1000 users with different ramp ups This section provides comparison of response times of having 1000 users using the system with different ramp ups The main goal of this test is to verify for 1000 users what would be limit of ramp ups to have an acceptable response time Table 8 4 3 Response times by ramp up period with 1000 user for major web pages Ramp up Periods Simulator App FAQ Page Home Page 5 31371 19173 5043 25 22602 19107 5913 50 10653 7083 5360 100 47 18 2 Figure 8 4 3 Performance graph with various ramp ups for 1000 user 1000 Users in different Ramp ups and 1 loop Count 35000 30000 25000 20000 15000 10000 Response Time ms 5000 4 o Simulator Faq Home 25 50 Ramp up period second 100 90 Observation As per the result of the above test if 1000 users access the system within 50 secs less than 1 min response time becomes 5 sec with my low end machine If 1000 users access the system within 100 secs less than 2 mins response time is very low which is great This tells us that for sudden burst of having 1000 new user within a minute system should be able handle it very gracefully response time
21. page enter the yield price and cost in Crop name Com mee System Conventional v3 percentage that you think can vary at your farm SSS 2 Price 96 Cost 96 crop Acre 00 D Land Typ Dy zD ee 3 gt crop 2 Show budget detail per acre TET Cropiname Soybeans T Crop system Conventional y Crop Acres Income Cost Return Over Cost Crop Acres fi 00 Land Type Dry Corn 100 345 291 54 Soybeans 100 237 191 45 Farm Per Acre 291 241 50 Farm Total 200 582 483 99 2008 Kansas State University 109 3 1 5 2 View Summary As user configures a plan Summary is updated automatically One can succeed at almost anything for which he has enthusiasm Charles Schwab V ANAGER INFO WHOLE FARM at University Home Simulator FAQ ContactUs About cps SIMULATOR Location of the land North East O Plan 1 Plan 2 Plan 3 Plan 4 Summary Details Number of Crops 2 EXPECTED VARIATION PLAN 1 NOTE To view the expected variation in Summary amp Crop 1 Show budget detail per acre Details page enter the yield price and cost in Crop Name Corn E crop system Conventional percentage that you think can vary at your farm Yield 5 96 Price 36 cost Crop Acres fi 00 Land Type Dry Crop 2 Show budget detail per acre GropiName Soybeans H Grop Systemi Conventional Crop Acres Income Cost Retum Over
22. table was Land Type and Total updated Acres if you like instantaneously when values were changed TS 5 7 Click on icon and Clicking on icon will display When plus icon change values of either default values of Income and Cost is clicked it pull Income or Cost that may be in details Changing any value down editable appropriate for your farm should automatically update the costs and income summary table instantaneously as values Upon well changing costs and income values it updated the summary table instantaneously TS5 8 In the Expected With the expected variation value Entered 5 in Variation form enter any given in yield field you will see expected 82 number e g 5 in the yield field and press Tab in your keyboard Now click on Summary Details tab graph with highest and lowest points The return over cost table should have value represented in the graph variation form and clicked on Summary Details tab Noticed that graph had highest and lowest point TS5 9 Click on Plan tab clear Without any value in the expected Cleared entered the yield value you have variation you should see a value in TS5 8 entered in TS5 8 and hit horizontal line in the graph The for Plan 1 Tab key in your value of High Mean and Low Clicked on keyboard Now click on should be the same in Return Summary Summary Details
23. 29 Figure 3 2 8 Sequence diagram of CPS iPhone App eese 30 Figure 3 2 9 State Machine Diagram of Loading CPS Application ssssseessss 31 Figure 3 2 10 State Machine Diagram of View Summary esee 32 Figure 3 3 1 UML Class Diagram with Role Name for Formal Specification 33 Figure 5 2 1 Class Diagram of Web Service Component sssssssssreseeseressrrrrreererrsessee 49 Figure 5 3 1 Class diagram of Business Logic Layer Component esses 52 Figure 5 4 1 Class diagram of Data Access Layer Component cccccccceeserrrrrrrrereee 55 Figure 8 4 1 Performance testing graph of Major web services cesse 80 Figure 8 4 2 Performance testing graph of Major CPS Web Pages oooooccccccocconconcconconocos 81 Figure 8 4 3 Performance graph with various ramp ups for 1000 user ce ee eee eee 83 Ligure 9 T CPS Software Highlights a oxmepealein ar EP SEV xo obe mae SET reed 86 Figure 10 3 1 SLOC Distribution CPS Web APP 125 Figure 10 3 2 SLOC Distribution CPS iPhone App sss 126 xi List of Tables Table 2 3 1 COCOMO EAF Parameters users raid 14 Table 2 3 2 Adjusted EAF Values applied to CPS Project ccceece cece cence eeeeeeaeeeneees 14 Table 3 2 1 List of View and Controller of CPS Web App eccceeee cence cent eeeeeeeaeeees 21 Table 3 2 2 List of View and Controller of CPS iPhone App Component
24. 291 54 Soybeans 100 237 191 45 Farm Per Acre 291 241 50 Farm Total 200 582 as3 99 Crop Acres Income Cost Return Over Cost Alfalfa 100 345 291 54 Wheat 100 331 209 121 Farm Per Acre 338 250 88 Farm Total 200 676 501 175 Life is like riding a bike To keep your balance you must keep moving Albert Einstein iG WHOLE FARM 2 Univer 3 x 2 op Profitability Simulator Home Simulator FAQ Contact Us About CPS SIMULATOR 9 Location of the land NorthEast Plan 2 Plan 3 Plan4 Summary Details Number of Crops 2 EXPECTED VARIATION PLAN 1 NOTE To view the expected variation in Summary EB crop 1 Show budget detail per acre Details page enter the yield price and cost in Crop Name Com E crop system Conventional percentage that you think can vary at your farm Yield J5 9e price 5 Costil5 9 Crop Acres f 00 Land Type Dry E E P amp Crop 2 Show budget detail per acre SUMMARY PLAN 1 Crop Name Soybeans y Crop System Conventional y P worse Woes O REGGE eae Crop Acres 100 Land Type Dry m Com 100 345 291 54 Soybeans 100 237 191 45 Farm Per Acre 291 241 50 Farm Total 200 582 483 99 SUMMARY PLAN 2 Crop Acres Income Cost Return Over Cost Alfalfa 100 345 291 54 Wheat 100 331 209 121 Farm Per Acre 338 250 88 Farm Total 200 676 501 175
25. A A Ve CERE REA Rats 19 2 AL CRS Web Client CoOnmpoOfelit ss cesar eae uA XVn EHE FEX TRI ECT RENE RU KEEN EUR RES 20 2 1 2 CPS iPhone Client Component ceo coe eere te ore ii 21 21 3 CPS Web Service Component rne se kr SERRE S ESTE REESE E EP P pa EESE EENE pet 22 2 1 4 Business Logic Layer BLL Component eorr eda diseno Rb ua er uo ERR era 23 2 1 5 Data Access Layer DAL Component sees enne nnne 24 240 CES Database COmpoOneHlt s ss reet a en e M RE Ee 26 22 Deployment EOS 27 2 3 InteracttobVIeW deseo SS IA SAA A ec a ds 28 2 3 1 Sequence Diagram of View Summary UseCase cc eee eee cence eee nena eens 28 2 3 2 Sequence Diagram of SelectRegion UseCase 00 ccc ecee cece ence eee e eens eeaeenues 29 2A state Machine Vi Wen aa 30 2 4 1 State Machine Diagram of Loading CPS Applicati0N ooooococcccccccnccconcccnnccnno 30 2 4 2 State Machine Diagram of View Summary cese 31 3 Formal Specification of Me Systems li 32 3 1 UML Class Diagram with Role Name AS 32 32 USE Mode lag trader ur E 33 3 3 Transcripts Outcome of CMD Script to hold violate invariants eesusssus 40 CHAPTER 4 INSPECTION LIST our EIER HERR E ER e NR EEE ERE ete 46 Le Introduction saco ee A E ERR ER E TEM I 46 2 Tiems to be rispecled o oso ton des ian daca pU RE ohare s Aiton M acp natn abaco eR UL TAE prd dE 46 AA Ul DL UTENTE 46 2 2 Formal Spectficatlong sodass Eo Sap a ERA
26. CPS Crop Profitability Simulator allows farmers in Kansas and surrounding states to assess market risks for multiple farming plans including conventional and organic farming methods a Plan 1 Plan 2 Plan 3 3 88 PROFIT USD 3 Crop Profitability Simulator In addition to the default values based on Kansas Farm Management Guides the Simulator allows you to customize your calculations to your individual situations in terms of specific revenue and cost items and possible variabilities in price yield and cost The whole farm profitability for multiple plans will be summarized in a graph for easy comparison If you have questions please refer to the Frequently Asked Questions FAQ page If the answer of your question is not available in FAQ please send your questions to the email address available in Contact Us page Partial funding for AgManager info has been provided by K State Research amp Extension the Kansas Corn Commission and AgMRC CORN resource center COMMISSION 3 1 2 FAQ From the main home click on FAQ hyper link to load FAQ page Click on question to view the answer of the question 106 The Whole Farm Crop Profitability Simulator a gt http slocalhost CpsWebClient Fag aspx Q7 Googe D dr CO Apple Yahoo GoogleMaps YouTube Wikipedia News 60 Y Popular Y DA G One can succeed at almost anything for which he has enthusiasm Charles Schwab Macer
27. CPS iPhone application launches 21 This holds and manages the entire UI elements for the application PlanOneView xib View Render plan configuration UI where user PlanOneViewController m Controller selects crop crop system land type acre and PlanTwoView xib View expected variation etc for Plan One Render plan configuration UI where user PlanTwoViewController m Controller selects crop crop system land type acre and expected variation etc for Plan Two Summary View xib View Summary ViewController m Controller Render UI for Summary tab RegionTableView xib View Render the UI where user picks a region first RegionTableController m Controller before configuring the plan one RegionTwoTableView xib View Render the UI where user picks a region first RegionTwoTableController m Controller before configuring the Plan Two Table 3 2 3 Helper Classes used in CPS iPhone App Component Class files Purpose WebServiceHelper m Help to initiate and configure web service connection properties XMLDataSetParser m Help to parse and process the XML data response from the web service DataSet m Custom data structure to hold the parsed data done by XMLDataSetParser class This helper class also helps to find records data with ease DdlCropSystem m These classes help to gives user a drop down experience in DdlLandType m iPhone application instead
28. File Mar 9 2010 11 01 PM 4KB Objec ce File Mar 14 2010 5 08 PM 4 KB C Hea ce File Apr 12 2010 8 41 AM 12 KB Objec ce File Mar 14 2010 5 08 PM 4KB C Hea ce File Mar 14 2010 6 11 PM 8 KB Objec ce File Mar 14 2010 5 09 PM 4 KB C Hea ce File Mar 14 2010 6 11 PM 8KB Objec ce File Mar 10 2010 8 49 PM 8 KB Porta image Nov 2 2009 12 00 PM 4 KB Porta image Nov 2 2009 12 00 PM 4 KB Porta image Feb 27 2010 2 57 PM 4 KB Objec ce File Mar 7 2010 2 01 PM 24 KB Interf ument Mar 23 2010 10 23 PM 8 KB Porta image Feb 27 2010 9 30 PM 4 KB C Hea ce File Feb 27 2010 9 25 PM 8 KB Objec ce File Apr 13 2010 9 39 PM 44 KB Interf ument Apr 13 2010 9 43 PM 40 KB Interf ument Nov 2 2009 12 00 PM 4 KB Porta image Feb 27 2010 10 00 PM 8 KB Interf ument Feb 28 2010 11 07 AM 8 KB Interf ument Mar 10 2010 9 24 PM 4 KB C Hea ce File Mar 10 2010 9 24 PM 4KB Objec ce File Mar 10 2010 9 25 PM 4 KB C Hea ce File Apr 13 2010 8 51 AM 8 KB Objec ce File Click on Build and Go icon String Matching lt gt CPSAppDelegate m 6 No selected dE CPSAppDelegate m CPS e Created by Reza Nabi on 2 27 18 Copyright Kansas State University 2618 All rights reserved HU 3timport CPSAppDe legate h import Plan neNavController h import PlanTwoNavControlLer h 3timport Plan neViewController h import AppData h amp implementation CPSA
29. S 01004 Reza S Done 120 00 120 00 112 00 0 00 H Quick Close Story v challenges to come BED write Software Quality WB assurance Plan 1 0 S 01005 Reza Done 16 00 16 00 16 00 0 00 H Quick Close Story Y af Build first simple executable D prointype S 01006 Reza S Done 80 00 80 00 72 00 0 00 H Quick Close Story Y Quick Close v M4 4 1 5 of 5 DDI Ay 4 2 Phase Two Elaboration Sprint Plan Figure 2 4 1 Action Items of Phase Two Sprint Sprint Alla Reports Burndown o Sprint Summary End Date Total Estimate Detail Estimate hrs Total Done hrs Total To Do hrs Progress 4 6 2010 392 00 400 00 104 00 n NA INN S OU M UM ae Story and Defect Details Add Story Inline B Filter Quick Close 144 4 1 9 of 9 1 gt Apply Reset 154 Detail BB Title ID Owner Status Estimate Estimate Done Effort To Do i a hrs hrs hrs hrs y e pr S is Progress e Y carded adidas S 01007 In Progress Y 32 00 40 00 0 00 H Quick Close Story y D e and construct c 01008 Reza JB in Progress E 120 00 120 00 16 00 H Plan Story v Oo e das contruct 551009 120 00 120 00 16 00 H Plan Story i P AAA s 01010 32 00 32 00 16 00 H Plan Story Y OB write Test Plan 1 0 S 01011 32 00 32 00 16 00 H Plan Story E Write Formal O specification with USE and S 01019 16 00 16 00 16 00 H Plan Story v OCL Oe eae 01020 8 00 8 00 8 00 H Plan Story Inspection Che
30. USE Model invariants are sufficient to meet the Formal requirement outlined in section 3 1 Specification and section 3 2 in vision document Document 1 0 TL6 The USE instantiation scripts and USE Model other cmd scripts provided with Formal USE model is sufficient to verify the Specification invariants to holds violates Document 1 0 TL7 Test CPS Software and verify that it CPS Software meets all functional requirements stated in section 3 1 and 3 2 in vision document 133
31. When I click on Summary I get Incomplete Plan What should I do CPS Information Incomplete Plan Please configure at least one plan to view the summary p Answer To display summary system requires at least one plan to be configured Please click on either Plan One or Plan Two select a region and enter all required values like Crop Crop System Land Type and Total Acre Then click on Summary tab 4 1 3 Ihave found a bug with the Application What should I do Answer Please contact either Dr Andresen dan ksu edu or Dr Hikaru hpp ksu edu or Reza Nabi reza ksu edu We will address it in our next release 121 4 1 4 I have an enhancement request Who should I contact Answer Please contact either Dr Andresen dan ksu edu or Dr Hikaru hpp ksu edu or Reza Nabi reza ksu edu We will address it in our next release 4 1 5 Iam having problem Installing CPS iPhone application What should I do Answer Please contact Reza Nabi reza ksu edu We will help you to resolve the problem you are encountering 4 1 6 I want to install this CPS iPhone application to real iPhone device How can I do that Answer As soon as we package CPS iPhone application via apple you should be able to download and install the application to either iPhone or IPod touch from Apple store We have plan to do this over the summer Stay tuned 4 2 CPS Web Application FAQ A detailed version of the Fequently Aske
32. a single developer with access to the necessary resources non development overhead is minimal Thus in my opinion for an MSE project like the CPS a realistic Effort value should be between 5 to 6 staff months With the adjusted value of staff months 5 5 the new development time can be calculated as Time 2 5 5 5 40 38 4 7 months 4 Sprint Planning The development of this Project is divided into three sprints Each sprint is dedicated to do the development for each phase discussed in section 2 Task breakdown In this section we will display action items for each sprint The software VersionOne is used to track all the action items throughout the project 4 1 Phase One Inception Sprint Plan Figure 2 4 1 Action Items of Phase One Sprint Sprint Reports Burndown Sprint Summary D Title End Date Total Estimate Detail Estimate hrs Total Done hrs Total To Do hrs Progress Current Phase One S 2 15 2010 264 00 264 00 252 00 0 00 E E Story and Defect Details Add Story Inline Filter v Quick Close M4 4 1 5 of 5 DPI Ay Detail OAA Title 1D Owner Status Estimate Estimate Done Effort To Do hes hrs hrs hrs BB write Vision Document 1 0 S 01001 Reza Done 24 00 24 00 30 00 0 00 H Quick Close Story Y P 263 write Project Plan 1 0 S 01003 Reza I Done 1v 24 00 24 00 22 00 0 00 H Quick Close Story Ef Research amp Development on IPhone App and do discoveries of
33. developer very quickly 0 88 ACAP High Developer is experienced in analysis and design 1 3 AEXP High Developer is experienced in project oriented application 1 1 development PCAP High Developer has enough programming experience 1 2 VEXP Moderate Developer has moderate experience with other project 1 1 components excluding software LEXP Moderate Developer is experienced in C used to develop web 1 0 application web service but does not have good experience in Objective C used for iPhone develoment MODP High Project uses modern practices 1 0 TOOL Moderate Use of tool is moderate Developer preferes to write code by 0 92 hand instead of tools SCED Moderate Project is tightly schedule allowing time is permissible with 1 1 Supervisor s approval The EAF value is calculated to 1 5 Based on the source code of the CPS prototypes of both web and iPhone applications I estimated the size to be 5500 LOC Web 2500 LOC iPhone 2000 LOC Effort 3 2 1 5 5 5 41 05 28 74 staff months Time 2 5 15 2 0 38 8 9 months the development time I think that 28 74 staff months for Effort is accurate for a project like CPS where we will be building simulator for both the web and iPhone using web services A project like this has no non value added items and turnaround time between developer and client The 15 Advisor is prompt Since this project has a staff of
34. found a bug in the application What can I do 122 CHAPTER 10 PROJECT EVALUATION 1 Introduction This chapter presents the summary of experiences gained during the entire life cycle of the MSE project 2 Problems Encountered 2 1 Learning Objective C Coacoa XCode amp the world of iPhone Development I have never owned a Mac and I have never used a Mac until this project I had to start from scratch learning the basic OS functionality through development of applications In addition I had to learn Objective C The language has different styles and flavor nothing like Java or C I always enjoy learning new things and I enjoyed learning Objective C as well 2 2 Apple s UIViewPicker an alternate solution of Combobox Not Usable To select an item from a list Apple has a control called UlViewPicker This is very bulky and not good looking at all For CPS application I had to come up with a custom control like ComboBox to save real estate 2 3 Hiccup to performance testing using WebService SOAP sampler While executing my performance testing I was able to run the load tests for web pages with no issues However when I attempted performance test on accessing the web service only it didn t work After couple of hours of trial and error found that there was a bug in the version I was using After downloading the latest version from the Sun website it worked great 2 4USE Model and OCL I learned USE and O
35. loosely coupled application integration and software reuse With the open standards like XML SOAP WSDL and UDDI the Service Oriented Architecture SOA allows interoperability between widely disparate applications running on different platforms and implemented in different languages To demonstrate the benefits of SOA we developed two CPS Clients CPS Web application and CPS iPhone application implemented in different languages and deployed on different platforms The CPS Web application was developed using C language on Microsoft s NET platform and deployed on Windows and the CPS iPhone application was developed using Objective C language on Apple s Coacoa platform running on the iPhone OS Both CPS clients communicate with a central relational database MS SQL Server 2008 via web services using same server components Business Logic Layer Component and Data Access Layer Component to ensure the highest level of modularity maintainability and software reuse 1 2 Terms and Definitions e Plan Combination of picking i a crop e g corn wheat ii crop system e g organic conventional iii land type e g dry irrigated and iv area of total land in acreage e Expected Variation The quantity in percent cost and income value may vary This gives high end and low end profitability in addition to the average e Return Over Cost This is same as profit It is measured as per acre e CPS Crop Profitability Simul
36. ne a xata sud deas te Exe i pua 46 3 Formal InSpeetofszecse eeestoeetu Ao id 46 4 Formal Inspection Checklist 47 CAHPTBEBR 5 COMPONENT DESIGN jh reru yea Ex perdia NA EHE REPERI REESE ERES 48 T InttOduCHOD du e axi eae ah Sale x enr Ss aider Run o E UE REL IR AVENUE ae dex E EN LE NUUS 48 2 Web Service C omponent WSC S oo e s E t epe 48 2 I CPSSEFVICOS CASS a tas Geb hla ge EES eta etch 48 PX Bi SCT RO 48 ZIP mb Se ENEE tuner Ea tee 48 2 1 3 Operation Specification assises ii hA ERR EUER ERE e VERENA a ERROR C ETE 49 3 Business Logic Layer Component BLLC sees e n eene 51 3 1 PlanSummary Class 0 a a 51 3 TT DESCHpuOn v cioe Epp Ie EET TUE REMEUR EE EYURREEREI EUR RAWEROREEPURN uU NEUE eeaeeeotes 51 SL AU DUNES ad a en taal hae ned elie ae A ve a Dedede en nee Lee 52 2x13 Operation Specifications user t e ae eee as do 52 3 2 CPS Analysis Clas ua r te EEEE x EE TLR RTEA RS 53 SAN DESOTO AA Cm 53 A 53 3 2 3 Operation Specification cir A A A A 53 4 Data Access Layer Component DADO ooooccccccconcconcccnncconnconnnconaronncconaconncconacooss 54 A A REGION MAS Uer rete Eb ER EIE EUR MER PERF ERA EREQER UR VeL OP A RDUM UH dE CPU ME ess 35 SANE osse Er RS 55 Al 2 PUL DUES 4 rs wd ck do reina N de 55 4 13 Operation SpeciITIC AUN oues ror E E A E E ER EAEN 55 2 7 Braata SS Read 56 Z7 Description ai ET Soe ae 56 4 2 AMI DUES a a el ee cd 56 4 2 3 Operation Specification ii A venue A ds 56
37. on SOA IEEE Computer Society 2009 8 Ketil Lund Anders Eggen Dinko Hadzic Trude Hafsoe Frank T Johnsen Using Web Services to Realize Service Oriented Architecture in Military Communication Networks IEEE Communication Magazine October 2007 9 Harry M Sneed Integrating legacy Software into a Service oriented Architecture in proceedings of the Conference on Software Maintenance and Reengineering 2006 128 10 Roger S Pressman Software Engineering A practitioner s approach McGraw Hill 2005 11 James Rumbaugh Ivar Jacobson Grady Booch The Unified Modeling Language Reference Manual Covers UML 2 0 Addison Wesley 2005 12 Gustavo Alonso Fabio Casati Harumi Kuno Vijay Machiraju Web Services Concepts architectures and applications Springer Verlag 2004 13 James Rumbaugh Ivar Jacobson Grady Booch Software Project Management A Unified Framework Addison Wesley 1998 14 Apache JMeter User Manual Online Available http jakarta apache org jmeter Accessed April 2010 15 Reza Nabi CIS895 Deliverables Online Available http cis895 nabi us Accessed April 2010 16 Version One Agile Tool to Manage Software Development Project Online Available http www versionone com Accessed January 2010 17 Microsoft Patterns and Pratices Online Available http msdn microsoft com en us practices default aspx Accessed January 2010 129 Appendix A Formal Inspectio
38. plan configuration screen 4 3 2 Attributes Table 5 4 5 Attributes of CropDesc Class Name Type Description cropDescld Int Crop Description ID Name String Name of the Crop e g Corn Wheat Soybean etc 4 3 3 Operation Specification of non getter setter constructor method Table 5 4 6 Operation specification of CropDesc Class Name Description Load Signature public bool Load int id Description It loads the CropDesc object Returns to true if data 57 passed in is valid and load successful Otherwise return false Behavior Pre Passed in data is valid Pre a record should exist in CropDesc table by the id passed in Post return true if record exists and load successful Otherwise return false Post give user record not found message if record does not exists FindByRegion Signature public DataTable FindByRegion string regionName Description Behavior It finds all the CropNames configured for a given region and retuns the datatable Pre None Post return list of Crop names configured for a given region Post If no crop name configured then returns null and give user at least one crop must be configured for a given region message 4 4 Crop Class 4 4 1 Description This class represents crop that has been configured for a plan and responsible to make operation to physical data table Crop This is used
39. region return null and give user At least one CropType needs to be configured for a given region message GetLandTypesByRegion Signature public DataTable GetLandTypesByRegion string regionName Description This method returns list of LandTypes configured in the database for a given region Behavior Pre passed in data is valid Post return datatable of LandType if records found in the database Post if no LandTypes are found for a given region return null and give user At least one LandTypes needs to be configured for a given region message GetPlanSummaryData Signature public DataTable GetPlanSummaryData string regionName string cropName string landType string cropType string sYieldChange string sPriceChange string sCostChange string landArea Description Behavior This method returns the plan summary datatable Pre Passed in data is valid Post return datatable with PlanSummary data Post if invalid data found return null and give user invalid data message GetCpsAnalysisData Signature public DataTable GetCpsAnalysisData string regionName string cropName string landType string cropType string sYieldChange string sPriceChange string sCostChange string planName Description This method returns the datatable of CpsSummary data which is used to draw graph and retune over cost tables for all plans side by side
40. s overview and requirements This phase will include the production of a Vision Document 1 0 a Project Plan 1 0 a Software Quality Assurance Plan 1 0 and a simple prototype of the software 2 1 1 Vision Document This document will include the project s critical requirements It gives a listing of features requirements and labels each requirement as functional and non functional or Future Requirements include validation rules and should be associated with unique section ids so that each requirement can be easily traceable The introduction to this project includes its goals and motivation of the proposed product 2 1 2 Project Plan This document will include a timeline for the project and a cost estimate for completing this project Cost estimates will be developed using the COCOMO estimating methodology All activities involved with this project will be associated with milestones outlined within this document according to the modern software process This process includes Inception Phase Elaboration Phase Production Phase and the Transition Phase 10 2 1 3 Software Quality Assurance Plan This document will include an outline of required documents To ensure software quality practiced standards and conventions will be monitored and followed This document will outline project reviews and the responsibilities of those associated with the proposed software Crop Profitability Simulator CPS 2 1 4 Simple Prototype A si
41. the CPS Software to build an architectural infrastructure by using SOA realizing with de facto standard web services To demonstrate the benefits of SOA we developed two CPS Clients CPS Web application and CPS iPhone application implemented in different languages and deployed on different platforms The CPS Web application developed using C language on Microsoft s NET platform deployed on Windows and the CPS iPhone application developed using Objectiv C language on Apple s Coacoa platform running the iPhone OS Both CPS clients communicate with a central relational database MS SQL Server 2008 via web services using the same server components Business Logic Layer Component and Data Access Layer Component to ensure the highest level of modularity maintainability and software reuse Table of Contents List of PU SUITES nicas Listof Tables NR II E Acknowledgements uisaio eia VOTERS D QU Sd otitis Ae AE Eaa CAHPTER T VISION DOCUMENT ri rs BM Introductions Un AMOO cest esp i n 1 2 Terms and Definitions oe EE OI EE e o Lol de 1 3 Crop Profitability Simulator CPS esee 2 Project OVET VIBW SS cun erue e sue Sero PNE Ra He Tan ee Mud OE 2 1 Product Perspective tay vos ets e exea RR Re RERO TR A 222 Project Goal Reca 2 3 Operating Environment a o a 2 4 Design and Implementation Constraint eese 2 3 User DOCU SAO sss e soy suitor AAA COS ERI T AUI AREE 3 Project Requirement RES 3 1 Features of
42. to find out cost income profit 4 4 2 Attributes Figure 5 2 7 Attributes of Crop Class Name Type Description cropld Int Unique Crop Id landTypeld Int Land type that the crop associated with 58 cropTypeld Int Crop Type that the Crop associated with cropDescld Int Crop Description that the Crop associated with 4 4 3 Operation Specification of non getter setter constructor method Figure 5 2 6 Operation specification of Crop Class Name Description Load Signature public bool Load int cropDesId int cropTypeId int landTypeId int regionld exists Description It loads the crop object Returns to true if all data passed in is valid and load successful Otherwise return false Behavior Pre Passed in data is valid Pre a record should exists in the table class represent Post return true 1f record exists and load successful Otherwise return false Post give user record not found message if record does not 4 5 Income Class 4 5 1 Description This class represents Income data of a given crop and responsible to make operation to physical data table Income This is used to calculate income profit CpsSummary and CPS Analysis data 4 5 2 Attributes Table 5 4 7 Attributes of Income Class Name Type Description cropId int Crop Id that the income records map to yieldPerAcre int Yield per Acre p
43. vi 2 3 CTOpDesc t la ecw sede too SERE enaenads pIME EE Ar aan aos 57 4 31 DESC PO TL 57 SA E 57 43 3 Operation Specificatl N ia 57 LACTOSA SIN EERE 58 4 4 1 Descriptio 0 pasiva 58 SES uM vani T RR 58 4 4 3 Operation Specification i cierre ey nee rh da 59 4 5 Income Cass ee t do vertes 59 2 5 EMDESCHDBHOH 5a O Er Meet td c E rM ELA s NE 59 AL iib Ree Rm 59 4 5 3 OPErA tons PECAR 60 AO Cost Class P A EENE E A A a edie 61 2 6 1 ESCH PU ON ra AU 61 4 6 2 Attributes Mm 61 46 3 Operation Specification ssr E A 62 PCO LYDE Clas Sears oat E A AS 63 AL DESC o e a a er bo LE 63 ERES e d eni Rat as 63 4 7 3 Operati n Specification Na 64 CHAPTER 6 SOFTWARE QUALITY ASSURANCE PLAN see 66 Purpose A vans XR SAY Y e YAN S CARRY yen sa had Haws dy a AA AAA A 66 Pi TY 66 NESCIRE 66 22 CI CP 66 2 3 RESPONSES is AA od S NR 66 2ra DEVELOPE MEE 66 PR PA A AS EE E AA A N E E 65 253 HO UDEFVISOTY COMMITEE 19 2 oiv poner ag OKE EEEO x EO ORIS aia 67 2 3 4 Formal Technical Inspector careto rollito ERN SERRE ETE NEN UPS ippo 67 3 DOCU A deed ov ae A AA A et aes 67 vil Dal PUL OSC apenas vats AS e e da ees 67 3 2 Minimum Documentation Requirement 0 cece cece ence ence eee eene 67 4 Standards Practices Convention and MetriCS ooocccccccccccccncccnnnccnncncnnnnnnnnnnnnnnnnnnns 68 2 Reviews and AUS is Ee amo Ix eap es dur xa tee Stews ass DEIN RFA ENNIE 68 A E 68 7 Prob
44. 241 175 112 Cost 5 Yield 5 Price 5 E 150 i g 100 a 504 Plan 1 Plan 2 Built using ChartFX for NET Development SUMMARY PLAN 1 SUMMARY PLAN 2 Crop Acres Income Cost Return Over Cost Crop Acres Income Cost Return Over Cost Corn 100 345 291 54 Alfalfa 100 345 291 54 Soybeans i00 237 191 45 Wheat i00 331 209 121 Farm Per Acre 291 241 50 Farm Per Acre 338 250 88 Farm Total 200 582 483 99 Farm Total 200 676 501 175 SUMMARY DETAILS PLAN 1 INCOME PER ACRE INCOME PER ACRE 111 When we are planning for posterity we ought to remember that virtue is not hereditary Thomas Paine A MANAGER INFO WHOLE FARM St Crop Profitability Simulato Home simulator FAQ contact us About cps SIMULATOR Location of the land NorhEast Y lan 3 Plan 4 Summary Details EA Number of Crops 27m PECTED VARIATION PLAN 2 p NOTE To view the expected variation in Summary Crop 1 Show budget detail per acre Details page enter the yield price and cost in Crop Name Alfalfa v crop System Conventional gt percentage that you think can vary at your farm Yield 5 96 price 5 36 cost 5 Crop Acres 100 Land Type Dry AS Crop 2 Show budget detail per acre SUMMARY PLAN 1 Crop Name Wheat Crop System Conventional y Em A Over Gast Crop Acres fo Land Type Dy H Corn 100 345
45. 9 2010 4 14 2010 4 19 2010 4 22 2010 4 27 2010 4 30 2010 Sprints ToDo Ideal 126 Burndown Remaining To Do 5 Lessons Learned e Working and understanding USE OCL and core UML notations used to draw architectural diagrams e Being that person responsible for everything this project gave me great experience of playing every role required to develop and release software e Learned IEEE standard of various documents which were required to produce in each phase I learned a lot while producing various deliverables using IEEE standards e This project gave me a chance to learn Service Oriented Architecture and implement a model solution ensuring the highest level of software reuse and Interoperability e From not knowing anything about the Mac operating system this project gave me great opportunity to learn and develop a full fledge application integrated with various platforms e This project also gave me a great knowledge and experience to integrate software between rival technologies like Microsoft and Apple 6 Conclusion amp Future Work In this project we developed fully functional CPS Software based on core Service Oriented Architecture The CPS Software is deployable on multiple platforms and accessible via both web browser universal client and iPhone or iPodTouch reusing the same server components as well as leveraging open standards like XML SOAP WSDL and UDDI In this project we proved that SOA is not a buz
46. A SERVICE ORIENTED CROP PROFITABILITY SIMULATOR CPS REALIZING WITH WEB SERVICES by REZA NABI Bachelor of Engineering Department of Computer Science and Engineering Zhejiang University Hangzhou PR China 1996 A THESIS submitted in partial fulfillment of the requirements for the degree MASTER OF SOFTWARE ENGINEERING Department of Computing and Information Sciences College of Engineering KANSAS STATE UNIVERSITY Manhattan Kansas 2010 Approved by Major Professor Dr Daniel Andresen Abstract The Service Oriented Architecture SOA a bleeding edge architectural paradigm facilitates software development by providing modular design scalability robustness loosely coupled application integration and software reuse With the XML SOAP WSDL and UDDI open standards the Service Oriented Architecture SOA allows interoperability between widely disparate applications running on different platforms and implemented in different languages The Department of Agriculture has a legacy Crop Profitability Simulator CPS which is an Excel spreadsheet that allows farmers in Kansas and surrounding states to assess market risks by viewing income cost and profit based on the Kansas Farm Management guides Due to the limitations of Excel the CPS software has various shortcomings with regards to robustness scalability interoperability usability and reuse This thesis examines the shortcomings of the legacy system and improves upon
47. Below is the CPS database schema diagram outlines tables structures and the relationships among the tables Figure 3 2 5 CPS Database Schema Crop Cropp E CropDescID en CropTypelD E LandTypeID RegionID a Consulting El Insurance al Drying IB Miscellaneous MachineryExpense E NonMachineryLabor Income ml IrrigationLabor IncomeID IrrigationFuel En CropID RI IrrigationRepair m YieldPerAcre ET DeprciationOnEquipment E PricePerBushel Ei InterestOnEquipment E GovtPayment ul LandCharge ER IndemnityPayment ET InterestonMonLandCost El MiscIncome E YieldLevel Bj YielLevel 26 2 2 Deployment View This section provides deployment diagram of CPS software including both clients Figure 3 2 6 Deployment Diagram of CPS Software communicates r manifest I U Description CPS Client can be either an iPhone App running on the iPhone OS or a browser loaded with the CPS Web page running using any PC iPhone app communicates with CPS Web service which then access to CPS Database either via BLL component or DAL component For web browser client it first sends the request to a web server then it calls a web service via code behind class of CPS Web App component to query data from the CPS database 27 2 3 Interaction View This section provides two sequence diagrams to demonstrate two path that web service m
48. Boolean checking invariant 5 Region HaveAtLeastOneCropCofigured OK checked 5 invariants in 0 010s 1 failure constraint 4 fails cmd gt use gt Constraint No 5 NoDuplicateCropIdInCostPerYieldLevel Fails Explanation In cst3 cropId 2 and yield level Average is used intentionally to break the constraint As per the requirement for a given yield level Cost cannot have duplicate croplId In this case cropld 2 is used in cst2 object Hence constraint 5 will not hold 44 SCRIPTS RAN use gt read constraint 5 fails cmd constraint 5 fails cmd gt check checking structure checking invariants checking invariant 1 Cost NoDuplicateCropIdInCostPerYieldLevel FAILED gt false Boolean checking invariant 2 Crop CostAndIncomeDataMustBelnSync OK checking invariant 3 Crop CropIdIsUnique OK checking invariant 4 Income NoDuplicateCropIdInIncomePerYieldLevel OK checking invariant 5 Region HaveAtLeastOneCropCofigured OK checked 5 invariants in 0 030s 1 failure constraint 5 fails cmd use 45 CHAPTER 4 INSPECTION LIST 1 Introduction This chapter provides a checklist that is used to perform a technical inspection of the MSE Project developing CPS Software It provides a guideline that is to be followed while inspectors check the integrity of artifacts associated with this project The inspectors will use this document as an aid while inspecting the Architectural Desi
49. CL in CIS771 Software Specification course I had to brush up on my USE and OCL skills 123 3 Source Lines of Code SLOC My initial estimate of source line of code in Phase II was 5500 LOC Web 2500 iPhone 2000 After finishing the project I used the LocMeter tool to count SLOC It turned out that my estimate was off Section 3 1 and 3 2 provides the SLOC of Web app and iPhone app given by LocMeter Tool 3 1 SLOC of CPS Web App Total SOLC reported by LocMeter 5185 Table 10 3 1 SLOC of CPS Web app C CIS LOCCount WebApp Overall Symbol Source Files Directories Kolo BLOC SLOC P SLOC L MVG C amp SLOC CLOC CWORD HCLOC HCWORD C NCISSLOCCount sWebRpp Count Definition Source Files Directories Lines of Code Blank Lines of Code Physical Executable Lines of Code Logical Executable Lines of Code McCabe VG Complexity Code and Comment Lines of Code Comment Only Lines of Code Commentary Words Header Comment Lines of Code Header Commentary Words 124 3 2 SLOC of CPS iPhone App Total SOLC reported by LocMeter 3678 Table 10 3 2 SLOC of CPS iPhone App CACIS LOCCount IPhoneApp Overall Symbol Count Definition Source Files Source Files Directories Directories LOC Lines of Code BLOC 3 Blank Lines of Code SLOC P 3 Physical Executable Lines of Code SLOC L Logical Executable Lines of Code MVG 3 McCabe VG Complexity C amp SLOC Code and Comment Lines of Code CLOC Comment Only Lines of Code CWORD C
50. CPS Web Application cc cee cee eee cence eee eeeeeeeaeees 3 1 1 Home Main Home Page uni id DAD FAQ dem Sl S Contact US ai bevdov ea e uen xu favit ea aie eee Sd A ADOUU CPS Ae A E dct C MUERE Uem A qesta steer s vesc eee dee M aas Suet need adus e ARAN S SOL CES uon RV EORR IU DER DUI MEIN M dd RO O 3 1 5 4 Expected Variation ide 3 1 5 5 Summary Details ui rE PAR EET EEEE A US AAA A 3 2 Features of CPS iPhone Application esee ili 2 2 TF Simulator ERARIO 8 SEA SIM ERU N 8 Sho MA Gro A TE 8 9 22 13 Expected Variation uses ep stad ii 8 202 I9 Summary soera etase d ota eiesa pardons WES FEL VS TRU RDA P PNE M BARCO Eas cE CE ep fS 8 23 241 5 User Interface i ecrit M t Eae bU Ev RERUM tas 8 4 Non Functional Requirements oes sepe p sue ue e Ey NAE EORR SEYERNE AN ERR REPORNEREAT S EOYERS A E nana 9 4 1 Performance Requirement iii toan EUR RE EY whee naw UN YS EN RR PRIN 9 4 2 Safety Requirement S b end Ded LESE ise LE ee 9 Z3 SEU Beguiremelifs soo ne o aad 9 4 4 SOT are Quality Attribute E Irae xu ene EE Od Re 9 9 Other Require Hiellls a d Mte pis veto Henn dieu ERES e iaa 9 CHAPTER 2 PROJECT PLAN iere ie xy exu A a 10 A 10 2 bask Bread nM E 10 ZINC POM PHASES AAN genta Raa E EERE OEE wees 10 2 1 Vision DOGU RB 2 2 orar obser or A A deti tee 10 PALLA A A E 10 2 1 3 Software Quality Assurance Plan li e a ae Shen e E eds 11 ZA Simple Pro
51. Cost crop Acres 100 Land Type Dry m Com 100 345 291 Soybeans 237 191 SUMMARY PLAN 1 Farm Per Acre 291 241 Farm Total 582 483 2008 Kansas State University 3 1 5 3 Expected Variation For each plan there will be an Expected Variation table where user can enter Yield Cost and Price that can vary at user s farm The expected variation data helps to the best and worst estimate of profit along with the average Leadership and learning are indispensable to each other John F Kennedy a I ANAGER INFO WHOLE FARM State University x xm A Agr m Crop Profitability Simulator A Ex Home Simulator FAQ Contact Us About CPS SIMULATOR Location of the land North East 9 Plan 1 Plan 2 Plan 3 Plan4 Summary Details N Number of Crops pza A NOTE To view the expected variation in Summary EB crop 1 Show budget detail per acre Details page enter the yield price and cost in a ercentage that yo an vary at your farm Crop Name Corn v Crop System Conventional v P E 2 2 cons OD Crop Acres 100 Land Type Dry y t Crop 2 Show budget detail per acre SUMMARY PLAN 1 Crop Name Soybeans y Crop System Conventional y Price 5 36 Crop Acres Income Cost Return Over Cost Crop Acres f 00 Land Type Dry m Com 100 345 291 54 Soybeans 100 237 191 45 Farm Per Acre 291 241
52. DI SEOC OL CPS Web APP av tc A e 124 3 2 SLOC of CPS iPhone App cien pn Ye a ua a caves dans dy ie 125 4 Project Duration amp Burndown 22 0 eecoca goto Eo oe Ossa la 125 5 Lessons Learnt and Comments 5 A dia 127 6 Conclusion amp Future WOEE tried 127 Reteren eS CPC DTE 128 Appendix A Formal Inspection Letter of Suresh Pothuri esee 130 Appendix B Formal Inspection Letter of Amit Borcar esse 132 List of Figures Figure 1 1 1 CPS Legacy app provides default income and cost value sce cece eee neee 3 Figure 2 4 1 Action Items of Phase One Sprint esses 16 Figure 2 4 2 Action Items of Phase Two Sprint usce ee ve x eo ree Yu UD Y xoc bru ETE FREU e xedus 17 Figure 2 4 3 Action Items of Phase Three Sprint 0 cece sees eee ee ence eee eeeeneeeeenee ene 17 Figure 3 1 1 Critical Use Case Diagram of CPS software esee 19 Figure 3 2 1 Component Diagram of CPS Software cece sce eee eee e scene eee eeneeeeenaeees 20 Figure 3 2 2 Class diagram of CPS Web Service Component eese 23 Figure 3 2 3 Class diagram of BLL Component tee ee ii ci 24 Figure 3 2 4 Class diagram of DAL Component csse 25 Figure 3 2 5 CPS Database eMe rta rito dota 26 Figure 3 2 6 Deployment Diagram of CPS Software ccc ce ece eee e eee ne eee mee 27 Figure 3 2 7 Sequence diagram of CPS Web App sssssssseesee me eene
53. NoDuplicateCropIdInIncomePerYieldLevel OK checking invariant 5 Region HaveAtLeastOneCropCofigured FAILED false Boolean checked 5 invariants in 0 020s 1 failure constraint 2 fails cmd use Constraint No 3 CostAndIncomeDataMustBelnSync Fails Explanation As per the system requirement for a given yield level if a row exists in Income there must be another row exists in Cost as well for the same yield level Here for the crp3 cropId 3 Income object is created with Average yield level but Cost object is created with High yield level Hence constraint 3 failed SCRIPTS RAN use gt read constraint 3 fails cmd constraint 3 fails cmd gt check checking structure checking invariants checking invariant 1 Cost NoDuplicateCropIdInCostPerYieldLevel OK checking invariant 2 Crop CostAndIncomeDataMustBelnSync FAILED gt false Boolean checking invariant 3 Crop CropIdIsUnique OK checking invariant 4 Income NoDuplicateCropIdInIncomePerYieldLevel OK checking invariant 5 Region HaveAtLeastOneCropCofigured OK 42 checked 5 invariants in 0 010s 1 failure constraint 3 fails cmd gt use gt Constraint No 3 CostAndIncomeDataMustBelInSync Fails Explanation As per the system requirement for a given yield level if a row exists in Income there must be another row exists in Cost as well for the same yield level Here for the crp3 croplId 3 Income objec
54. North Central Crop Name 45 25 Conventional v South East e Land Type v Cost 4 Price 2 Yield 3 Cost 5 Price 4 Yield 4 South Central Crop Acres North West Cost Yield Price North East 94 2 Software Installation This section provides required hardware software and installation process of CPS Software 2 1 Required Hardware DB Server Server should be equipped with at least 2 4 GHz CPU clock speed 2 GB RAM and 120 GB Hard drive Web Server Server should be equipped with at least 2 4 GHz CPU clock speed 2 GB RAM and 120 GB Hard drive iPhone Simulator Since iPhone client needs to be packaged by Apple Developer Program and we don t have the subscription yet for now we need Mac pc or Macbook to test CPS iPhone client using built in iPhone simulator in XCode NOTE If client have limited resources one physical machine with 4GB RAM and 250 GB hard drive playing both DB server and web server role should be sufficient as well 2 2 Required Software 2 2 1 Required Software CPS Web App Microsoft Windows 2008 Server with Web Server role MS SQL Server 2008 or MS SQL Server 2005 CPS Web Client MSI Package Available online at http home nabi us CpsWeb docs PhaselII Setup CpsWebClientSetup msi CPS Web Service MSI Package Available online at http home nabi us CpsWeb docs PhaselIl Setup CpsWebServiceSetup msi CPS Database Installation Scripts available online at http home n
55. PerAcre double pricePerBushel double govtPayment double indemnityPayment double miscPayment int yieldChange int priceChange Description It loads the Income object Returns to true if all data 60 false farm passed in is valid and load successful Otherwise return Usage This method is used by Web client where user is allowed to have custom income data applied to user s Behavior Pre Passed in data is valid Pre a record should exists in the table class represent Post return true load successful meaning all data valid Otherwise return false Post give user Invalid data message if load unsuccessful 4 6 Cost Class 4 6 1 Description This class represents Cost data of a given crop and responsible to make operation to physical data table Cost This is used to calculate cost profit CpsSummary and CPSAnalysis data 4 6 2 Attributes Table 5 4 9 Attributes of Cost Class Name Type Description cropId int Crop Id that the Cost record map to yieldPerAcre int Yield per Acre Seed double Cost of Seed herbicide double Cost of Herbicide insecticide double Cost of Insecticide fertilizer double Cost of Fertilizer consulting double Cost of Consulting insurance double Cost of Insurance 61 Drying double Cost of drying miscellaneous double
56. Phone client invokes GetRegions Web Service to get list of regions that user may pick from The service creates a Region object creation of the object is omitted for clarity and call findAll method which query the database and return the datatable with list of Regions to the web service The web service then sends response to caller the client with list of regions 29 2 4 State Machine View This section provides state machine diagram of CPS software 2 4 1 State Machine Diagram of Loading CPS Application Figure 3 2 9 State Machine Diagram of Loading CPS Application IsWSAvailable true Load Application Description When the iPhone app fires up it first does the initialize routines then it checks if the web service is available If available it gracefully loads the application If the web service is not available or has an error during rendering the service it displays the warning message 30 2 4 2 State Machine Diagram of View Summary Figure 3 2 10 State Machine Diagram of View Summary NumberOfConfigured Plan gt 1 Load Summary Description When the user clicks on the Summary tab in the iPhone app the system first checks if there is a plan configured If there is at least one plan configured the system loads the summary page gracefully If no plans are configured the system gives a warning message 31 3 Formal Specification of the System This section provides class diagram with role
57. RE RAV EN 106 SD JT NHIEU pu 106 SelB Contact US ir A A TA AAA AA AAA AE 107 AI E SiS EE E T E E 108 OU eM 108 d xd onftisure a Plan ro predica 109 31 5 2 View UI A A A A A A AS 110 1X 3 1 5 3 Expected Valat on 2144 ot LL de ae e decane Ia AS 110 3 1 5 4 Comparing Multiple Plans AA RUERS NN ENT 111 3 1 5 5 Summary Details and Print A Aa 113 3 2 CPS iPhone Application Operation 22 seve rere cias pcia 114 S MGE ES IIIDICILU deer 114 3 2 1 1 Configure a Plan Aia REESE 116 3 2 1 2 Configure Crops Crop System and Land Type eese 116 3 2 1 3 Expected Variation ies euch A nk Da dn eR a ee Pa A 118 3 2 1 4 Plan Comparison and Summary ore er eee 118 4 Frequently Asked Questions FAQ and Troubleshooting eene 120 4 1 CPS iPhone Application FAQ ss o ira 120 4 2 CPS Web Application FAO eno A DER E ER E UR OR eS 122 CHAPTER 10 PROJECT EVALUATION cesse III Ie ee eee heme nenne 123 os rese HS 123 2 Problems Enco ntered eccL t eR ker tid e ete A isa 123 2 1 Learning Objective C Coacoa XCode amp the world of iPhone Development 123 2 2 Apple s UIViewPicker an alternate solution of Combobox Not Usable 123 2 3 Hiccup to performance testing using WebService SOAP sampler 123 28 USE Model dud OG L zo asus on ctor te da 123 3 Source Lines of Code SLOC 0 cc ccc cece ence cece een n nee eee ehe e e eese esee 124
58. T_ID N d E Y Notification Services BEGIN 2d idi E SQL Server Agent Agent XPs disable CREATE TABLE dbo CropType POTS TT Diese TREMTTTWGOG 1 MOT NIIT coasts comp laced successfully comp success full tein IN D EB EE Ed Ed EE E EE EE EE E E E 97 4 Load the CPS data by running LoadData bat like the following x CA WINDOWS system32 cmd exe C KSUNDatabaseSetup gt C KSUN DatabaseSetup gt LoadData bat gt LoadResults txt C KSUNDatabaseSetup gt 5 Verify that there is no error in LoadResults txt file Healthy logfile may look like the following Ba 3 Of C KSUNDatabaseSetup gt bep CPS dbo Region in DataFiles Region txt Starting copy 6 rows copied Network packet size bytes 4096 Clock Time ms total 63 C KSUNDatabaseSetup gt bep CPS dbo CropType in DataFiles CropType txt c T Starting copy 2 rows copied Network packet size bytes 4096 Clock Time ms total 1 C KSUN DatabaseSetup gt bep CPS dbo LandType in DataFiles LandType txt c T Starting copy 2 rows copied Network packet size bytes 4096 Clock Time ms total 1 C KSUNDatabaseSetup gt bep CPS dbo YieldLevel in DataFiles YieldLevel txt c T Starting copy 3 rows copied Network packet size bytes 4096 Clock Time ms total 15 C KSUNDatabaseSetup gt bep CPS dbo CropDesc in DataFiles CropDesc txt c T Starting copy 9 rows copied Netwo
59. Type Class Name Type Description landTypld Int Land Type s ID Name String Description of Land Type e g Dry Irrigated 4 2 3 Operation Specification of non getter setter constructor method Table 5 4 4 Operation specification of LandType Class Name Description Load Signature public bool Load int id Description It loads the LandType object Returns to true if data passed in is valid and load successful Otherwise return false Behavior Pre Passed in data is valid Pre a record should exist in LandType table by the id passed in Post return true if record exists and load successful Otherwise return false Post give user record not found message if record 56 does not exists FindByRegion Signature public DataTable FindByRegion string regionName Description It finds all the landTypes configure for a given region and retuns the datatable Behavior Pre None Post return list of landtypes configured for a given region Post If no landType configured then returns null and give user at least one landtype needs to be configured for a given region message 4 3 CropDesc Class 4 3 1 Description This class represents crop name e g Wheat Corn etc and responsible to make operation to physical data table CropDesc This class promotes reusing crop name for multiple plans This class is used to populate crop list in
60. abi us CpsWeb docs PhasellI Setup DatabaseSetup zip 2 2 2 Required Software CPS iPhone App Mac OS 10 5 or Higher Apple iPhone Development Kit 3 0 or Higher XCode IDE CPS iPhone Client Available online at http home nabi us CpsWeb docs PhasellI Setup iPhoneClient zip 95 NOTE When iPhone application will be packaged by Apple none of the above software is required All we need is iPhone or iPod Touch with deployable CPS iPhone Application package 2 3 Install CPS Software and Setup This section provides steps to load the database setup web client web service and iPhone application 2 3 1 Load Database 1 Download and unzip the Database Installation scripts available online at http home nabi us CpsWeb docs PhaselllI Setup DatabaseSetup zip 2 Load SQL Server Management Studio and create a database called CPS File Edit View Project Tools Window Community Help T New Query Ly y Clo DllD 1 ES dd A Eo 3 B e a Object Explorer Connect 89 m 4 Y 4 CHIMP SQL Server 9 0 1399 sa Summary a 2 us Report X j Databases CHIMP Databases Sysl New Database Dat Attach Adv Restore Database Adv Restore Files and Filegroups E F Bud F CM Refresh LA System Databases t E ORCA Lj Database Snapsho
61. aded without any navigation bar error TS5 2 In the location of the land Nothing should change at the UI No change on UI drop down list change region to North West TS5 3 Click on the Y icon next Greater Kansas map should be Kansas state map to location of the land drop displayed was displayed drown TS5 4 Click on X hyperlink Popup window should be closed Clicking on X located on the top right link closed the corner of the popup popup window window just opened in TS5 3 TS5 5 In Planl tab select number Based on your selected value page System provided of Crop that you would like should be updated with Crop Crop crop to configure for your plan System Land Type and Total area configuration for each crop with default value form populated A summary table dynamically 81 should also be displayed on the right along with Expected Variation table on the top based on the number of crop is picked It also displayed the summary table as well with default cost and income data TS5 6 In the Crop drop down When the crop or crop system or Changed crop change selected default land type or total acres changes total acres of Crop to something else In information of the summary table land crop addition to changing crop should be update instantaneously system and land you may also change other type Summary values like Crop System
62. an Please configure at least one plan to view the summary TS6 3 Click on Plan One tab Application will load plan one and click on North West detailed configuration form region without any error with some default value for users convenience TS6 4 Click on the button with This should bring up a window down arrow next to Crop where user can select the crop of his plan 76 TS6 5 Click on the button with down arrow next to User should be able to select the land type and crop system without LandType and Crop any error System TS6 6 In the expected variation You should see Return Over form of plan one enter Cost table populated with high some number e g 5 in low and mean value returned from yield field Then click on the backend server via web Summary tab service TIPS Regarding closing the number pad after typing or selecting number from the number pad you need to hit enter to close the number pad TS 6 7 Click on Plan Two tab With the second plan configured and configure another crop you will see that summary page is with the crops system land updated with the high low and type total acre and mean value of the second plan expected variation you like Then click on Summary tab TS6 8 Note down the plan one Verify that the high mean and low and plan two configurations you have performed Do the same co
63. anual effort to maintain different version of the source code 10 Media Control No formal process has been adopted to control the media for this project 11 Record Collection Maintenance and Retention Two copies of all deliverables will be produced One will be with the Major Professor and one will be with the developer In addition the entire source code documentation and web pages for the project website will also be burned into CD and will be kept with the developer 69 12 Training If Major Professor wishes developer will be conducting the training to the farmers users 13 Risk Management Both the developer and Major Professor have primary responsibility for identifying and mitigating risks during the project Any risks identified during the development will be reported at each weekly meeting report 70 CHAPTER 7 TEST PLAN 1 Introduction This document provides the plan for testing all the features outlined in section 3 1 and section 3 2 in vision document Chapter 1 of Crop Profitability Simulator CPS software The document will also describe the activities and environment related to testing the software 2 Test Items e CPS Web application features stated in section 3 1 in vision document Chapter 1 e CPS iPhone application features stated in section 3 2 in vision document Chapter 1 3 Tested Features All features of CPS Web application and CPS iPhone application will be tested The features are
64. ates to the NET Framework Cancel 104 2 3 4 Install CPS iPhone Client 1 Download CPS iPhone Application Source Code Available online at http home nabi us CpsWeb docs PhasellI Setup iPhoneClient zip to MacBook or Mac PC where iPhoneSDK 3 0 or higher and XCode is installed 2 Open up CPS Info plist file and make sure SeriveURL is pointed to the correct address where you have installed in section 2 3 3 PS FT ES fs File Edit Search View Tools Macros Configure Window Help 19 x DSuBgemBi e a1 OY EG ges E lt xml version 1 0 encoding UTF 8 gt lt DOCTYPE plist PUBLIC Apple DTD PLIST 1 0 EN http www apple co lt plist version 1 0 gt lt dict gt TextPad C KSU CPSApp Cps Web docs phaselllSetup IPhoneClient iPhoneciient EPS lt key gt CFBundleDevelopment Region lt key gt lt string gt English lt string gt lt key gt CFBundleDisplayNane lt key gt string CPS 1 0 lt string gt lt key gt CFBund leExzecutable lt key gt lt string gt EXECUTABLE_NAME lt string gt cam A e ad ke gervicaNaRSODEDE Rae string http agmanager info string lt key gt CFBundleldentifier lt key gt lt string gt com yourcompany PRODUCT_NAME rfcl034identifier lt string lt key gt CFBundleInfoDictionaryVersion lt key gt lt string gt 6 0 lt string gt key gt CFBund leNane lt key gt lt string gt PRODUCT_NAME lt strin
65. ation and CPS iPhone application implemented in different languages and deployed in different platforms The CPS Web application was developed using C language on Microsoft s NET platform deployed on Windows and the CPS iPhone application was developed using Objective C language on Apple s Coacoa platform running on the iPhone OS Both CPS clients communicate with a central relational database MS SQL Server 2008 via web services using the same server components Business Logic Layer Component and Data Access Layer Component to ensure highest level of modularity maintainability and software reuse CPS Web Application A fully functional web application will be developed to allow farmers to calculate return over costs based on their personalized data such as expenses and income The web application will be accessible live at http home nabi us CpsWeb The detailed requirements of the web application are available in section 3 1 of Chapter 1 CPS iPhone Applicaton The Crop Profit Simulator with at least 2 plans so that they can be compared by user will be developed to run on the iPhone and the iPodTouch The light weidght CPS iPhone application will assist us to demonstrate benefits of SOA having two disparate systems using the same server components The detailed requirements of the iPhone application are available in section 3 2 of Chapter 1 2 3 Operating Environment There are two major operating environments required for the prod
66. ation of elements and practices using UML diagrams and notations for architectural description 1 2 Terms and Definitions e Plan Combination of picking i a crop e g corn wheat ii crop system e g organic conventional iii land type e g dry irrigated and iv area of total land in Acre that may apply to a farmer s local farm e Expected Variation The quantity in percent Cost and Income value may vary This gives high end and low end profit in addition to average e Return Over Cost This is same as profit It is measured as per Acre e View A representation of a whole system from the perspective of a related set of concerns 1 3 Scope The proposed software CPS is used by farmers to assess market risks by comparing profits summary side by side for multiple plans The configuring plans include selecting region crop crop system e g organic conventional land type and total acres The following is the use case of a base CPS system For details of the requirement please refer to Vision document Chapter 1 18 Figure 3 1 1 Critical Use Case Diagram of CPS software Crop Profitablity Simulator CPS Critical Requirement c 1 y k lt Include gt gt j I s s M y nclude r Include lt A A e s x P m lt lt Include gt gt _ 2 4 77 e Include CPS Database 2 Architecture of t
67. ator the product we are building to help farmers assess market risks for multiple plans by comparing profitability side by side e SOA Service Oriented Architecture an architectural paradigm used to promote modular design scalability robustness loosely coupled application integration interoperation and software reuse 1 3 Crop Profitability Simulator CPS The legacy CPS system is an Excel spreadsheet where users may view default Income and Cost values of a crop for a given region based on Kansas Farm Management Guides Below is the screenshot of legacy CPS System Figure 1 1 1 CPS Legacy app provides default income and cost value EY FarmManagementGuides Crops Conventional xls Compatibility Mode Microsoft Excel Et E eis ear ae FABI En C an x Farm Management Guide MF 2159 Grain Sorghum Cost Return Budget in North Central Kansas Department of Agricultural Economics www AgManager info AAA A A I CVM a o o Kansas State University Agricultural Experiment Station and Coooperative Extension Service Daniel M O Brien Stewart R Duncan Brian L S Olson Agricultural Economist Crops and Soils NE Crops and Soils NW INCOME PER ACRE Yield Level bu ac Your Farm 27 A Yield per acre 70 90 110 Byn B Price per bushel 363 363 363 14 C Net government payment 13 03 14 16 15 29 15 D Indemnity payments 0 00 0 00 0 00 Me E Miscellaneous income 0 00 0 00 0 00 F Returns acre Ax B C D E 267 13
68. ay take query CPS database 2 3 1 Sequence Diagram of View Summary Usecase Figure 3 2 7 Sequence diagram of View Summary CpsAnalysis Usecase callCpsAanlysisWS ca GetCpsAanalysisData i LoadByCrop c LoadByCrop query Description Web iPhone client invokes CpsAanlysis Web Service which is used to get data needed to display return over cost tables to do compare plan side by side Web service creates a CpsAnalysis object which is omitted in the diagram for clarity and call GetCpsAanalsysisData method This method first creates income object and call LoadByCrop method which queries the database and load the income object Then it creates Cost object and call LoadByCrop method which queries the database and load cost object CpsAnalysis object then does required calculation build datatable structure and send data to CpsWebServices object The web service then return response to the caller the client 2 3 2 Sequence Diagram of Select Region UseCase Note The diagram below is displayed to demonstrate different path that web service takes to query data from the database In this case the web service directly call object of 28 DAL to query the database and get the data instead of using BLL object stated in 2 3 1 section above Figure 3 2 8 Sequence diagram of Get Regions callGetRegionsWS r findAIl Description Web i
69. ckList n Progress Mj e ry a O ni dear Plan s o1021 Reza JB lin Progress 7 8 00 8 00 8 00 H Plan Story Y O P Write Vision Document s 01022 8 00 8 00 8 00 H Plan Story Y Quick Close 44 4 1 9 of 9 D Apply Reset C gt 4 3 Phase Three Production Sprint Plan Alla Reports Burndown Y ps Story and Defect Details Add Story Inline Filterv Quick Close I 4 1 6 of 6 PM Detail Done Effort ToDo A 88 Title ID Owner Status Estimate Estimate hrs hrs hrs hrs ELLE ceste e O v abi S 01013 120 00 120 00 80 00 H Plan Story DEB write Test Plan 2 0 S 01014 32 00 32 00 32 00 H PlanStory v DEB write User Manual 1 0 S 01015 40 00 40 00 40 00 H Plan Story v EF Finishing Service Ul aciented web dient S 01016 32 00 32 00 32 00 H Plan Story v O SS Write Projet PERI nda 32 00 32 00 32 00 H Plan Story Eg Test Assessment O i v Mia Hoc S 01018 40 00 40 00 Plan Story Quick Close 44 4 1 6 of 6 1 b Ny CHAPTER 3 ARCHITECTURE DESIGN 1 Overview The overview provides the purpose scope and intended user of the proposed software the Crop Profitability Simulator CPS the useful terms and definition and references used during production of this document 1 1 Purpose The purpose of this document is to outline architectural design of the CPS software This architectural document should help to lay foundation for quality of the software and cost gain through standardiz
70. d Questions FAQ section is available for the Web application To access the FAQ page load the CPS web application and click on FAQ link The Whole Farm Crop Profitability Simulator jnixi 4 http focalhost CpsWebClient Faq aspx C Or Google D 2 LL Apple Yahoo GoogleMaps YouTube Wikipedia News 60 Y Popular Y gt One can succeed at almost anything for which he has enthusiasm Charles Schwab Acento WHOLE FARM Kansas Stat ersity s z Crop Profitability Simulator Home simulator Contact Us About cps FREQUENTLY ASKED QUESTIONS FAQ 1 am at the main home page How do I bring up the simulator Q 1 farm 200 acres of non irrigated land in northwestern Kansas If I want to grow com on 100 acres and soybeans on 100 acres using conventional methods how do I simulate the whole farm profitability for my plan Q the default values for INCOME PER ACRE and COST PER ACRE found in the Summary Details page are not applicable to my farm Can I personalize the budgets Q whatis the Expected Variation table in each plan for Q 1n the Simulator I see tabs for 4 available plans How can I make the best use of it Can you please give an example Q 1f any field in COST PER ACRE or INCOME PER ACRE for my field is left blank the page does not do anything What am I doing wrong Q Isee there are only 4 crops available to choose from How can I add a crop in the simulator that I am interested in Q 1
71. e should also be displayed on the right along with Expected Variation table on the top TS5 6 In the Crop drop down When the crop or crop system or change selected default Crop to something else In addition to changing crop you may also change other values like Crop System land type or total acres changes information of the summary table should be update instantaneously 74 Land Type and Total Acres if you like TS 5 7 Click on icon and change values of either Income or Cost that may be appropriate for your farm Clicking on icon will display default values of Income and Cost in details Changing any value should automatically update the summary table instantaneously as well TS5 8 In the Expected With the expected variation value Variation form enter any given in yield field you will see number e g 5 in the yield graph with highest and lowest field and press Tab in points The return over cost table your keyboard Now click should have value represented in on Summary Details tab the graph TS5 9 Click on Plan tab clear Without any value in the expected the yield value you have variation you should see a entered in TS5 8 and hit horizontal line in the graph The Tab key in your value of High Mean and Low keyboard Now click on should be the same in Return Summary Details tab Over Cost table
72. e 8 4 1 Performance testing graph of CPS Web Services Performance Testing of Major Web Services 10000 9000 8000 7000 6000 5000 GetPlanSummary 4000 lil GetCPSAnalysis Response Time ms i CropsByRegion 3000 2000 1000 0 100 500 1000 3000 Number of User Observation We have captured response times of major web services for 100 500 1000 and 3000 users with 1 loop count and 5 ramp up periods Since GetCpsPlanSummary web service does some extra computation to display calculated summary hence it takes little more time which makes sense With 1 loop count more loop count will bring the response time even lower due to caching and 3000 users the highest response time is less than 1 sec which is very much acceptable I wanted to take some more sample with users like 6000 10000 etc but due to the limitation of Jmeter anytime I picked more than 3000 user Jmeter was throwing java exception The above stats was taken from home workstation which has very limited resources couple of years old machine with 2 GB RAM Deployment of web service to a production level server response time will decrease significantly 4 2 Response Time Comparison of Major Web Pages This section compares response times of main CPS Web app Simulator aspx and two other major web pages which are FAQ and Home followed by observation note All test cases used 5 loo
73. e Oriented Architecture SOA realizing with de facto standard web services 1 1 Motivation Department of Agriculture has a legacy Crop Profitability Simulator CPS which is an Excel spreadsheet that allows farmers in Kansas and surrounding states to assess market risks by viewing income cost and profit based on the Kansas Farm Management guides The major shortcomings of the legacy system include e It provides default Cost and Income values along with breakdown based on Kansas Management Guides but it does not provide a profit summary e It does not facilitate comparing multiple plans simultaneously Since farmers need to assess market risks it would be useful to provide a view of multiple plans side by side and display high end low end and average profit summaries e It does not take in account variation in entities such as yield price and cost e Due to the limitations of Excel the application has various shortcomings with regards to robustness scalability interoperability usability reuse and the power of a relational database The motivation of this project is not only to address the shortcomings of the legacy application but to build an architectural infrastructure suitable for decades to come by using Service Oriented Architecture SOA realizing with de facto standard web services The SOA a bleeding edge architectural paradigm facilitates software development by providing modular design scalability robustness
74. e online at http home nabi us CpsWeb docs PhaselllI Setup Cps WebService msi 2 Double click the CpsWebServiceSetup msi file and load the CPS Web Service 1 0 setup wizard 3 Click on Next button to continue ji CPS Web Service 1 0 Welcome to the CPS Web Service 1 0 Setup Wizard 4 Provide the installation address you like and click Next to continue 102 i9 CPS Web Service 1 0 Select Installation Address The installer will install CPS Web Service 1 0 to the following web location To install to this web location click Next To install to a different web location enter it below Site Default Web Site y Disk Cost Virtual directory Cesws Application Pool Default amp ppPool X Cancel lt Back 5 Click Next to begin installation ii CPS Web Service 1 0 Confirm Installation The installer is ready to install CPS Web Service 1 0 on your computer Click Next to start the installation Cancel lt Back E 103 EA lola Installing CPS Web Service 1 0 CPS Web Service 1 0 is being installed Please wait 6 CPS Web Service installation is complete Click on Close to exit the setup wizard fi CPS Web Service 1 0 all xf Installation Complete CPS Web Service 1 0 has been successfully installed Click Close to exit Please use Windows Update to check for any critical upd
75. e recorded as either as pass or fail All failed test will contain detailed description of the failure date time along with comments if any 9 Testing Tasks 9 1CPS Web Application Testing Tasks Table 7 9 1 Test Suite 1 SR 3 1 1 Home Test Description Expected Outcome Actual Outcome TS1 1 Using your favorite browser The main home page should be hit the CPS web app at loaded successfully without any http home nabi us CpsWeb error TS1 2 Click on each hyper links All links should render page located on top navigation bar without any errors of the main Home page TS 1 3 Click on Crop Profitability It will bring up Simulator Simulator image application without any error 12 Table 7 9 1 Test Suite 2 SR 3 1 2 FAQ Test Description Expected Outcome Actual Outcome TS2 1 Clink on FAQ link located on the top navigation bar FAQ page should be loaded without any error TS2 2 Click on each questions of FAQ page It should render the answer of the question you have just clicked Table 7 9 3 Test Suite 3 SR 3 1 3 Contact Us Test Description Expected Outcome Actual Outcome TS3 1 Clink on Contact Us link located on the top navigation bar The Contact Us page should be loaded with contact information which should include phone email name and physical address
76. eage land type and crop system 3 1 5 2 Crops There should be no limitation on how many crops a user may choose The list of crops will be based on the data stored in the database For each crop the user should be able to view default costs and income values The application should also enable the user to enter their personalized values for cost and income The calculation of profit return over cost should be entirely based on what the user has entered in the Cost and Income fields 3 1 5 3 Summary When observing or modifying a plan a summary table will be displayed and updated automatically The information in Summary table will include crop acre cost income and profit for each crop At the bottom of the summary table Farm per Acre and Farm Total will be displayed for the given plan 3 1 5 4 X Expected Variation For each plan there will be an Expected Variation table where the user can enter Yield Cost and Price that can vary at the user s farm The expected variation data shows the user the best worst and average estimates of the profit 3 1 5 5 Summary Details The summary along with its breakdown will be available for each plan in the Summary Details tab The whole farm profitability return over cost for multiple plans will also be summarized in a graph for easy comparison with best worst estimates when an expected variation value is entered 3 1 5 6 User Inter
77. ene er edo SERERE ME ERR MEE eta EIC 62 Table 5 4 10 Operation specification of Cost Class cesses 63 Table 5 4 11 Attributes of YieldLevel Class nas een Poss Soon igen PERIERE HR ESRVEVA As 64 Table 5 4 12 Operation specification of YieldLevel ClasS oooococcoccccccocconconccnncnnconnrnnns 64 Table 6 3 1 List of documentation required for each phase cesses 65 Table 7 9 1 Test Suite 1 SR 3 1 1 Home 0 0c cece ree 65 Table 7 9 2 Test Suite 42 SR 3 12 PAQUI VES EEEE Ea EPESOES 65 Table 7 9 3 Test Suite 3 SR 3 1 3 Contact US seeeeeeeeee 66 xii Table 7 9 4 Test Suite 4 SR 3 1 3 About CPS sss 66 Table 7 9 5 Test Suite 5 Covers from SR 3 1 5 1 to 3 1 5 4 00 c cece cece cece eee eeeeeees 66 Table 7 9 6 Test Suite 6 Covers SR 3 2 1 1 to SR 3 2 1 4 ccc ccc cece cece eee ne eee eens 68 Table 5 2 T Testresults summary ia 71 Table 8 3 1 Test Results of Test Suite 1 TS O1 000 00 III 71 Table 8 3 2 Test Results of Test Suite 2 TS 02 0 0 ccc eee ee eee III 72 Table 8 3 3 Test Results of Test Suite 3 TS O03 0 00 0c ccc RII 12 Table 8 3 4 Test Results of Test Suite 4 TS 04 sees 73 Table 8 3 5 Test Results of Test Suite 45 TS O5 000 ccc e eect ee eeeeeenees 73 Table 8 3 6 Test Results of Test Suite 46 TS 06 seeeeeeeeeee RII 76 Table 8 4 1 Response times by number of user for major web ServicesS oo
78. environments a website accessible through common web browsers as well as an application accessible from an iPhone or iPod Touch 2 1 Product Perspective The proposed software The Whole Farm CPS allows farmers in Kansas and surrounding states to assess market risks for multiple farming plans including conventional and organic farming methods In addition to the default values based on Kansas Farm Management Guides the Simulator enables the user to customize calculations to individual situations in terms of specific revenue and cost items and possible variability in price yield and cost The whole farm profitability for multiple plans will be summarized in a graph for easy comparison Detailed feature is available in section 3 of Chapter 1 Vision Document 2 2 Project Goal In addition to addressing the shortcomings of legacy system stated in section 1 1 of Chapter 1 the proposed software CPS will be built on top of Service Oriented Architecture SOA realizing with Web Services The SOA facilitates software development by providing modular design scalability robustness loosely coupled application integration and software reuse With open standards like XML SOAP WSDL and UDDI the Service Oriented Architecture SOA allows interoperability between widely disparate applications running on different platforms and implemented in different languages To demonstrate the benefits of SOA we will develop two CPS Clients CPS Web applic
79. erformance Requirement Performance may vary depending on the hardware used to host the application However maintaining a response time of less than 7 seconds for any page is expected 4 2 Safety Requirement If deployed at KSU Campus the KSU IT team shall be responsible for the daily backup of the data If deployed on the developer s LAN the developer shall be responsible for the daily backup 4 3 Security Requirement The product must be physically located behind a firewall with a private IP so that the system is not publicly accessible Only port 80 will be open to access the CPS web application and CPS web services 4 4 Software Quality Attribute Service Oriented Architecture MVC design pattern along with an object oriented programming approach should be used while developing this product which will help to boost the metrics when it comes to flexibility reusability maintainability scalability and interoperability 5 Other Requirements None CHAPTER 2 PROJECT PLAN 1 Overview This project plan document provides a task break down completion criteria of tasks and cost estimation of the project using COCOMO model As per the MSE portfolio guide line the project is broken down into three major phases After each phase certain artifacts refer to section 2 need to be produced followed by a presentation to the committee 2 Task Breakdown 2 1 Inception Phase The inception phase will concentrate on the project
80. es with CPS database Model via CPS Web service Table 3 2 1 List of View and Controller of CPS Web App Web Forms and its Controller Purpose Default aspx View To render main home page Default aspx cs Controller AboutCPS aspx View Render About CPS page AboutCPS apsx cs Controller ContactUs aspx View Render Contact Us page ContactUs aspx cs Controller Faq aspx View Render Faq page Faq aspx cs Controller Simulator aspx View Launch CPS the main application Simulator aspx cs Controller 2 1 2 CPS iPhone Client Component Like CPS Web app client component the design pattern MVC Model View Controller is also strictly followed building CPS iPhone app client component to facilitate clean separation and enforce code software reuse This component consists of NIB files View along with its Controller class which communicates with CPS database Model via CPS Web service component In addition to view and controller some other helper classes are also added to this component to process results rendered by web service sharing information among the tabs planl plan2 summary Below are the entities of the CPS iPhone app client component Table 3 2 2 List of View and Controller of CPS iPhone App Component NIB File and its Controller Purpose MainWindow xib View Render the main form of the application This CPSAppDelegate m Controller is where the
81. face The User Interface is dynamic clean and suitable for the target audience mildly technical farmers exploring their options 3 2 Features of CPS iPhone Application 3 2 1 Simulator To demonstrate the benefit of SOA a mini version of the CPS Phone application will be developed with the following features 3 2 1 1 Plan Users should be able to specify at least 2 plans with different combinations of crop acreages land type and crop system 3 2 1 2 Crops There are no limitations placed on how many crops a user can choose The list of crops will be based on the data available in the database and should be identical to the web client s Crop drop down list With the iPhone version of the simulator personalized cost and income value will not be entertained 3 2 1 3 Expected Variation For each plan there will be an Expected Variation table where the user can enter Yield Cost and Price that can vary at the user s farm The expected variation data shows the user the best worst and average estimates of the profit 3 2 1 4 Summary There will be a summary tab in iPhone version of simulator In this tab a summary table along with expected variation and High Mean and Low values will be displayed A break down of costs and income is not provided 3 2 1 5 User Interface The user interface has been developed as per Apple s UI guidelines 4 Non Functional Requirements 4 1 P
82. g house png main m MainWindow xib mg By rn zm y Sp re ran on PlanOneView xib PlanTwoView xib preferences png RegionTableView xib RegionTwoTableView xib WebServiceHelper h WebServiceHelper m XMLDataSetParser h XMLDataSetParser m ab Sb E Sb ok ie WebServiceHelper h WebServiceHelper m XMLDataSetParser h XMLDataSetParser m DataSet h DataSet m ils DdlCropSystem h DdiCropSystem m DdiCrop h DdlCrop m DdltandType h DdltandType m AppData h AppData m DdiBase h DdiBase m asses CPSAppDelegate h CPSAppDelegate m amp EJXEJEJNEJEJE SummaryViewController h SummaryViewController m PlanOneNavController h PlanOneNavController m RegionTableViewController h RegionTableViewController m IEEE EEE C EEE x amp x EEE PIS sil PlanOneViewController h PlanOneTableViewController h PlanOneTableViewController m m CPSAppDelegate m Apr 13 2010 8 52 PM 40 KB Porta image Apr 12 2010 8 29 AM 4 KB C Hea ce File Apr 12 2010 8 29 AM 4KB Objec ce File Feb 27 2010 3 36 PM Folder Apr 15 2010 12 05 AM Folder Feb 27 2010 2 57 PM 4 KB C Prec e File 11 AM 4KB XML P ty List 010 12 06 AM 108 KB Xcode ct File Mar 10 2010 9 26 PM 4 KB C Hea ce File Mar 18 2010 9 26 AM 8 KB Objec ce File Mar 14 2010 6 31 PM 8 KB Porta image Mar 9 2010 11 01 PM 4 KB C Hea ce
83. g gt lt key gt CFBundlePackageType lt key gt lt string gt APPL lt string gt lt key gt CFBundleSignature lt key gt lt string gt lt string gt lt key gt CFBundleVersion lt key gt lt string gt 1 0 lt string gt lt key gt LSRequiresIPhoneOS lt key gt lt true gt lt key gt NSMainNibFile lt key gt string MainWindow string lt dict gt lt plist gt CPS Info plist 14 B Read Ovr Block Sync Rec Caps A 3 Double click on CPS project file CPS xcodeproj and load the iPhone application on XCode IDE 4 Click on Build and Go to load the CPS iPhone Application using iPhone Simulator 105 3 CPS Software Operation This section provides instructions on how to use the CPS Software 3 1 CPS Web Application Operation 3 1 1 Home Main Home Page Using your favorite browser hit the address where you have installed the CPS Web Application Client Developer s CPS Web application Client is accessible at http home nabi us CpsWeb Default aspx The Whole Farm Crop Profitability Simulator gt http localhost CpsWwebClient Q7 Google D ze CO Apple Yahoo GoogleMaps YouTube Wikipedia News 59 v Popular v zm A G Life is like riding a bike To keep your balance you must keep moving Albert Einstein serio WHOLE FARM Crop Profitability Simulator Home simulator FAQ ContactUs About ces The Whole Farm
84. gn Document 1 0 and USE Model 2 Items to be inspected Following are items that need to be inspected by the technical reviewer 2 1 UML Diagrams e Class Diagram e Sequence Diagram e Component Diagram e Deployment Diagram e State Machine Diagram e Use Case Diagrams 2 2 Formal Specifications e USE Model e Scripts to test Model 3 Formal Inspectors Amit Borcar Software Engineer Sage Software Email amit borcar sage com 2 Suresh Pothuri Software Engineer Sage Software Email suresh pothuri sage com 46 4 Formal Inspection Checklist Table 4 4 1 Formal Inspection Checklist Inspection Item Artifact Results Comments The symbols used in the class Architectural I 1 diagrams conform to UML standards Design 1 0 The symbols used in the sequence Architectural L2 diagrams state machine diagram use Design 1 0 case diagram conforms to UML standards The symbols used in the component Architectural L3 view diagram conform to UML Design 1 0 standards The symbols used in deployment Architectural 14 diagram conform to UML standards Design 1 0 The USE model associations and USE Model L5 invariants are sufficient to meet the Formal requirement outlined in section 3 1 Specification 1 0 and section 3 2 in vision document The USE instantiation scripts and USE Model L6 other CMD scripts provided with Formal USE model is sufficient to verify the Specifica
85. he System The CPS software is built on top of Service Oriented Architecture SOA realizing with web services to facilitate loosely coupled application integration among various platforms and software reuse In this project two clients CPS iPhone app and CPS Web app running different platform have been developed and both clients share the same Business Logic Layer BLL components Data Access Layer DAL components and the same backend database Refer to Component Diagram in section 2 1 and deployment diagram in section 2 2 for details of software reuse and loosely coupled application integration 2 1 Component View This section provides component diagram of the CPS software followed by class diagram of each component 19 Figure 3 2 1 Component Diagram of CPS Software lAccessDB ADO NET Description Both CPS iPhone app and CPS Web app component communicates with CPS Web service component to get access to Data Access Layer DAL directly or via Business Logic Layer BLL component e g calculate and return data for CPS Analysis to get data from CPS database Note This Architecture regardless to what client needs are iPhone or web it use the same BLL DAL and CPS Database component 2 1 1 CPS Web Client Component The design pattern MVC Model View Controller is followed building CPS web app client component This component consists of ASP NET web form View and its 20 code behind class Controller that communicat
86. ibutes id Integer name String end LandType is to hold the type of the land e g Dry Irrigated class LandType attributes id Integer name String end Crop is to hold details information of the crops location of the land region type of land crop type description of the crop and an unique cropld The unique cropld is used to map with income and cost data 34 class Crop attributes cropld Integer landTypeld Integer cropDescld Integer cropTypeld Integer regionld Integer OPERATIONS operations Get the costs for a given crop getCostsBy YieldLevel yl YieldLevel Set Cost self costData gt select cst cst yieldLevel yl Get the Incomes for a given crop getIncomesBy YieldLevel yl YieldLevel Set Income self incomeData gt select incm incm yieldLevel yl end class Income attributes cropld Integer yieldPerAcre Real pricePerBushel Real govtPayment _ Real indemnityPayment Real miscIncome Real yieldLevel YieldLevel end 35 class Cost attributes cropld Integer seed Real herbicide Real insecticide Real fertilizer Real consulting Real insurance Real drying Real miscellaneous Real machineryExpense Real nonMachineryLabor Real irrigationLabor Real irrigationFuel Real irrigationRepair Real depreciationOnEquipment Real interestOnEquipment Real landCharge Real interestOnNonLandCost
87. icked question rendered the answer Table 8 3 3 Test Results of Test Suite 3 TS 03 Test Description Expected Outcome Actual Outcome TS3 1 Clink on Contact Us link The Contact Us page should be Contact Us located on the top loaded with contact information page loaded navigation bar which should include phone email name and physical address successfully It also displayed email phone and physical address TS3 2 Click on the email link given in the contact us page It should automatically load your default email client populated email address in To field It fired up the email client with email address populated on recipient list 80 Table 8 3 4 Test Results of Test Suite 4 TS 04 Test Description Expected Outcome Actual Outcome TS4 1 Clink on About CPS link located on the top navigation bar The About CPS page should be loaded without any error The information should contain name of the product version and copy write information Page loaded successfully It contains product name version and copy write information Table 8 3 5 Test Results of Test Suite 5 TS 05 Test Description Expected Outcome Actual Outcome TS5 1 Click on Simulator link located at the top The simulator should load without any errors Simulator lo
88. ion Constraints No 6 context Region inv AtleastHaveOneRegion Region allInstances gt asSequence gt size gt 1 Make sure system at least has one Crop Type e g Organic Conventional Constraints No 7 context CropType inv AtleastHaveOneCropType CropType allInstances gt asSequence gt size gt 1 Make sure system at least has one Land Type e g Dry Irrigate Constraints No 8 context LandType inv AtleastHaveOneLandType LandType allInstances gt asSequence gt size gt 1 39 3 3 Transcripts Outcome of CMD Script to hold violate invariants Following are the outcome along with explanation of USE cmd scripts refer to section 4 in formal specification document which is used to instantiate the USE model and to hold violate the invariants LLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLDLLLLLLLLLLLI CPS MSE Project Transcripts The results of various runs CMD Scripts Author Reza Nabi Email reza ksu edu LLLLLLLLLLLLLLLLLLLLLLDLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLI All Constraints Holds Confirm basic instantiation satisfies all basic structure requirements SCRIPTS RAN use read A basic init cmd cps basic init cmd gt use gt check checking structure checking invariants checking invariant 1 Cost NoDuplicateCropIdInCostPerYieldLevel OK checking invariant 2 Crop CostAndIncomeDataMustBelnSync OK checking invariant 3 Crop CropIdIsUnique OK chec
89. king invariant 4 Income NoDuplicateCropIdInIncomePerYieldLevel OK checking invariant 5 Region HaveAtLeastOneCropCofigured OK checked 5 invariants in 0 020s O failures use gt 40 Constraint No 1 CropIdIsUnique Fails Explanation In crp3 object created with a cropId 1 which is used in crpl Hence CropIdIsUnique constraint failed SCRIPTS RAN use read constraint 1 fails cmd constraint 1 fails cmd gt check checking structure checking invariants checking invariant 1 Cost NoDuplicateCropIdInCostPerYieldLevel OK checking invariant 2 Crop CostAndIncomeDataMustBelnSync OK checking invariant 3 Crop CropIdIsUnique FAILED false Boolean checking invariant 4 Income NoDuplicateCropIdInIncomePerYieldLevel OK checking invariant 5 Region HaveAtLeastOneCropCofigured OK checked 5 invariants in 0 010s 1 failure constraint fails cmd use Constraint No 2 HaveAtLeastOneCropCofigured Fails Explanation There is no Crop configured System requires that at least one must be configured Hence constraint 2 failed SCRIPTS RAN use read constraint 2 fails cmd constraint 2 fails cmd check checking structure 41 checking invariants checking invariant 1 Cost NoDuplicateCropIdInCostPerYieldLevel OK checking invariant 2 Crop CostAndIncomeDataMustBelnSync OK checking invariant 3 Crop CropIdIsUnique OK checking invariant 4 Income
90. law 4 Provide the installation address you like and click Next to continue By default CPSWebClient is set as virtual directory for the web application You may change it to any meaningful name you like e g CPSWeb 99 i9 CPS Web Client 1 0 Select Installation Address The installer will install CPS Web Client 1 0 to the following web location To install to this web location click Next To install to a different web location enter it below Site Defaut Web Site Disk Cost Virtual directory CoswebCient Application Pool Default amp ppPool m Cancel lt Back 5 Click Next to begin installation 3 CPS Web Client 1 0 Confirm Installation The installer is ready to install CPS Web Client 1 0 on pour computer Click Next to start the installation Cancel lt Back f 100 fe CPS Web Client 1 0 Installing CPS Web Client 1 0 215 x CPS Web Client 1 0 is being installed Please wait 6 CPS Web Application Client installation complete Click on Close to exit the setup wizard 5 CPS Web Client 1 0 Installation Complete CPS Web Client 1 0 has been successfully installed Click Close to exit Please use Windows Update to check for any critical updates to the NET Framework Cancel 101 2 3 3 Install CPS Web Service 1 Download the CPS Web Service MSI Package Availabl
91. lem Reporting and Corrective Actions cssssssssssssssssses eee e emen 68 8 Tools Techniques and Methodologies ccceecc cence ence eee eeeeeeeeeeeaeeeneeenaeenneees 68 9 Code Control A A 69 IG Media Control scsi ee e AAA 69 11 Record Collection Maintenance and Retention ccc ccc ccc cece eee 69 A Uri P Y 69 I5 Risk Nana pere nt io sI ad 70 dy WN OCUCH OM yesviguierirce DS 71 2 A e AA O 71 a AAA A en EEE H eter aS 71 4 Features Not To Be Tested Las A A 71 AA e Metre Nr es tn tee iia es E Aes 71 6 Item Pas Pal OME did sake 71 7 Suspension Criteria and Resumption Requirement csse 72 TI SUSDOHSIOI Erter is fis vce ee heehee neta dee A rasta 42 7 2 Resumption Requirement 2 eee RR TRE ORROR NR vce us ERE E VENE UNA S REUS SERRE S c kie 12 Test Deliverables c mesicni este E ET S O 12 9 Testing Tasks ipie iaae k a AE EE T a send E a E a aves 72 9 1 CPS Web Application Testing Tasks eser hee nh nn eye eer rene 12 9 2 CPS iPhone Application Testing Tasks 00 Sd A Mod vas ieiP ue iut 76 IG Environmental Needs ecesna nen iari aa A AER UT EE S 78 10 1 Environmental needs of CPS Web Application cc cecce ence cence ence eee e ena eeenees 78 10 2 Environmental Need of CPS iPhone Application sese 78 CHAPTER 8 ASSESSMENT EVALUATION eeeeeeeeeeeeeeen nennen nenne nennen enne nne 79 Ut connatis 79 viii PES Re SUS SUMINIALY ver
92. mple prototype will be developed to demonstrate at least one aspect of the software It will demonstrate some of the critical requirements outlined in the Vision Document such as implementation of critical validation rules This is completed to demonstrate feasibility or to illuminate risky project requirements Completion Criteria The phase will be complete once supervisory committee has approved 2 1 1 to 2 1 4 2 2 Elaboration Phase The elaboration phase will concentrate on the project s architecture This phase will include the production of an Architectural Design document revisions to the Project Plan and the Vision Document a formal specification Test Plan and two architecture inspections 2 2 1 Architectural Design Document The Architecture Design plan will include appropriate UML diagrams such as class diagrams use case diagrams and sequence diagrams as per the IEEE Std 1471 2000 IEEE recommended practice for Architectural Description 2 2 2 Revision of Project Plan and Vision Document Appropriate changes will be made to project plan 1 0 and vision 1 0 document as per the recommendation of the committee 2 2 3 Formal Specification CPS software will be formally specified using core UML and OCL The USE model along with testing scripts to hold specified constraint and to violate constraint will 11 be produced A transcript document holding results of all test script along with explanation if needed will al
93. n Letter of Suresh Pothuri April 24 2010 Re Formal Inspection letter for Reza Nabi s MSE Project Dear Dr Andresen I have reviewed Architecture document USE model and tested the service CPS Software All diagrams conform to core UML notations In addition verified that CPS Software meets all the functional requirements All items provided in the formal checklist document are passed Sincerely A S ny il f Lusa N Suresh Pothuri Software Engineer Sage Software Email suresh pothuri sage com 130 Table 1 1 Results of Formal Inspection Checklist TI 1 The symbols used in the class Architectural diagrams conform to UML Design Document standards 1 0 Comments The symbols used in the sequence Architectural diagrams state machine diagram Design Document 1 0 use case diagram conforms to UML standards The symbols used in the component Architectural view diagram conforms to UML Design Document 1 0 Architectural standards Pass Pass The symbols used in deployment diagram conforms to UML Design Document 1 0 USE Model standards TI TI TI The USE instantiation scripts and USE Model other cmd scripts provided with Formal USE model is sufficient to verify the Specification The USE model associations and invariants are sufficient to meet the Formal requirement outlined in section 3 1 Specification
94. n specification of CPSAnalysis Class Method Name Description GetAnalysisData Signature public DataTable GetAnalysisData Cost c Income i string planName Description It takes Cost Income and planName and it calculates as per the business rule and return CPSAnalysis datatable Behavior Pre Passed in data is valid Post return datatable with CPSAnalysis data Post if invalid data found return null and give user invalid data message Load Signature public bool Load Cost c Income i string planName Description It loads the CPS Analysis object Returns to true if all data passed in is valid and load successful Otherwise return false 53 Behavior Pre Passed in data is valid Post return true load successful meaning all data is valid Otherwise return false Post give user Invalid data message if load unsuccessful 4 Data Access Layer Component DALC This section provides class diagram of Data Access Layer Component and detailed description of each class DALC is responsible to communicate with Physical CPS database Figure 5 4 1 Class diagram of Data Access Layer Component associated With associated With 1 3 54 4 1 Region Class 4 1 1 Description This class represents location of the land e g North West South West etc and responsible to make operation to physical data table Region This class is used to list the
95. name used by model USE model along with CMD scripts which is used to hold violate invariants stated in the model 3 1 UML Class Diagram with Role Name Figure 3 3 1 UML Class Diagram with Role Name for Formal Specification cropgBy Type opsByLandType 0 0 0 L Pia locatedAt cropsByCropDesc 1 cropPointsTo 1 cropPointsTo 1 3 costData incomeData 32 3 2 USE Model EMLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLDLLLLLLLLLLLLLLLLLLLLLLLLLLE Formal Specification of CPS Crop Profitability Simulator MSE Project Spring 2010 Kansas State University Lo Weeks se K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K K File Name cps use Author Reza Nabi Date Mar 25 2010 model CPSSystem ENUMERATIONS enum YieldLevel Average High Low CLASSES Region is used to identify location of the land e g South West North West North Central etc Each Region will have a name and Active flag When we don t want to support any entered region we can just set the active flag to false class Region attributes id Integer name String end 39 CropDesc is used to hold the description of the crop e g Corn Wheat etc class CropDesc attributes id Integer name String end CropType is to hold the type of the crop also known as crop system e g Organic Conventional class CropType attr
96. nd expected results of all test Please refer to this document for further detail 7 Problem Reporting and Corrective Actions All problems will be reported as a result of presentations or brought about by the major professor They will be compiled into an action document after each presentation and will be resolved prior to the next presentation 68 Tools Techniques and Methodologies Following tools will be used during the proposed CPS Software development Microsoft Visual Studio NET 2008 IDE for coding web app and web services XCode IDE for iPhone application development e Cft for coding web app and web services SQL for web app web service and database development Objective C for coding iPhone application Cocoa Framework for iPhone application development NET Framework 3 5 for web app and web service development e MVC design pattern to develop iPhone application and web application JavaScript for coding web app HTML for coding web app XML for coding web app iPhone app web services e CSS for coding web app IS for web server to serve web application and web service e MS SQL SERVER 2008 for database server MS Word 2007 for documentation VersionOne for Project Planning Tracking Burndown chart USE 2 3 1 and OCL for formal specification and verification Code Control No version control system is used for the project yet Developer takes m
97. nfiguration using CPS Web application value in the Return Over Cost table in both CPS iPhone application and CPS Web application is the same 77 10 Environmental Needs 10 1 Environmental needs of CPS Web Application To test the CPS Web application the web application and the web service need to be deployed on a Windows 2008 server running IIS If a Windows 2008 server is not available any other operating system with IIS and NET frame work 3 5 installed should be fine Also a database SQL Server 2008 or SQL Server 2005 is required 10 2 Environmental Need of CPS iPhone Application To officially package the iPhone application we need to pay an IDP iPhone Developer Program membership fee 99 to Apple Since we don t have the IDP membership the only official way we can test is by using an iPhone simulator built in within XCode the IDE to develop iPhone application Hence to test the CPS iPhone application Leopard OSX 10 5 or higher is needed with Coacoa framework and Xcode installed The machine where the iPhone app is deployed needs to have access to the Windows box where the web service is deployed 78 CHAPTER 8 ASSESMENT EVALUATION 1 Introduction This chapter provides the results of functional testing of CPS Software and performance testing The test cases are based on the Test Plan 1 0 document produced in Phase II 2 Test Results Summary Table 8 2 1 Test results summary
98. nks to my 9 year old daughter Samah and 6 year old Son Tahsin for helping Daddy create the Table of Contents I am eternally grateful to Ammu Daddy and Mommy for their love support and constant prayers for me I would like to thank my manager Alan Uhl for being kind supportive and approving vacations on very short notice to work on my thesis I am truly indebted to Rosanne Haines Sage HR Manager for serving as my Proctor for the past 6 years I would like to extend my deepest regard and appreciation to Amit Borcar and Suresh Pothuri for being my formal technical inspectors and spending their valuable time on this project I would also like to thank Sophia Lyimo and Elizabeth Dobelstein QA Analysts for their best wishes and willingness to test my work Lastly I offer my thanks to all of my friends for being supportive and letting me study or work on this project during various social gatherings xiv CHAPTER 1 VISION DOCUMENT 1 Introduction Kansas State University currently uses a legacy product that enables farmers in Kansas and surrounding states to assess market risks based on the Kansas Farm Management guides The current product does not allow the user to compare multiple plans simultaneously view a profit summary or take in to account variations in yield price and cost This project addresses the shortcomings of the legacy application and builds an architectural infrastructure suitable for expandability by using Servic
99. o WHOLE FARM Home Simulator a Contact Us About CPS FREQUENTLY ASKED QUESTIONS FAQ I am at the main home page How do I bring up the Q 1 farm 200 acres of non irrigated land in northwestern Kansas If I want to grow corn on 100 acres and soybeans on 100 acres using conventional methods how do I simulate the whole farm profitability for my plan Q The default values for INCOME PER ACRE and COST PER ACRE found in the Summary Details page are not applicable to my farm Can I personalize the budgets Q whatis the Expected Variation table in each plan for Q In the Simulator I see tabs for 4 available plans How can I make the best use of it Can you please give an example Q 1f any field in COST PER ACRE or INCOME PER ACRE for my field is left blank the page does not do anything What am I doing wrong Q 1 see there are only 4 crops available to choose from How can I add a crop in the simulator that I am interested in 1 found a bug in the application What can I do 2008 Kansas State University The Whole Farm Crop Profitability Simulator lt gt http slocalhost cpswebClient Fag aspx e Qr Google Dr zt LI Apple Yahoo GoogleMaps YouTube Wikipedia News 60 Popular Y DA G One can succeed at almost anything for which he has enthusiasm Charles Schwab pps WHOLE FARM ability Simulat Home Simulator FAQ ContactUs About c
100. o return the list of Land Types available for a given region 23 2 1 4 Business Logic Layer BLL Component This section provides class diagrams and brief description of classes used in BLL component Figure 3 2 3 Class diagram of BLL Component Table 3 2 4 Classes of BLL Component Class Name Description PlanSummary This user defined data structure helps to represent plan summary data displayed with user configure a plan In this project this BLL class is used by web client only The method GetPlanSummaryData is used to return dataset to display complete plan summary CPSAnalysisData This helps to represent CPSAnalysis data which is used to display overall return over costs with High Low Mean value if expected variation entered for multiple plans side by side 2 1 5 Data Access Layer DAL Component This section provides class diagrams and brief description of classes which is used in DAL component that is responsible to communicate with CPS Database component the physical database via ADO NET framework 24 Figure 3 2 4 Class diagram of DAL Component associated With associated With 1 3 Table 3 2 5 Classes of DAL Component Class Name Description Region This class represents location of the land e g North West South West etc and responsible to make operation to physical data table Region This class is used to list the locations region of cro
101. ococcooccocconconccncns 79 Table 8 4 2 Response times by number of user for major pages csse 81 Table 8 4 3 Response times by ramp up period with 1000 user for major web pages 82 Table TO S T SEOG CPS Web ADD secsuvadessaueev yw e RSEN WEE EN Yd eos REESE en EP ERE AS 125 Table 10 5 2 SLOC CPS iPhone App ies ee eye hr x rr R IR RAEP an PAY ERES 126 xiii Acknowledgements Before I express my special thanks and gratitude to individuals I bear witness that all praise is due to my Lord who created me and to Him I shall return for His countless blessings and mercy upon me and my family I am heartily thankful to Dr Daniel Andresen as my Major Professor and Dr Hikaru Peterson as my committee member for giving me a chance to work on this wonderful project building service oriented software realizing with web services Without their guidance encouragement and support from inception I could not have finished this project I am also grateful to Dr Neilsen for feedback during the life cycle of the project and kindly agreeing to be on my committee My deepest gratitude goes to my family for their love and support I could not have come this far without them Looking back on the last 6 years I know I have spent many weekends researching without spending quality time with my beautiful wife Roxy my daughter Samah and my son Tahsin Indeed they are so patient and supportive of me I would like to extend my special tha
102. of UI View picker This is to save DdlCrop m real estate in configuring plan UI AppData m This class is designed using singleton pattern This helps to share data among tabs 22 2 1 3 CPS Web Service Component Figure 3 2 2 Class diagram of CPS Web Service Component CPSServices class is the heart of SOA This class implements all the required web methods to facilitate clients Web app or iPhone app to have access to BLL Business Logic Layer and DAL Data Access Layer components and return the results to the caller client Below are the lists of web methods along with descriptions Table 3 2 4 Web Methods for CPSServices class Web Method Name Description getCpsAnalysisData This helps to return the calculated data which is used to display profit high low mean for each plan side by side This method uses CpsAlanysis class from BLL component to serve the request made by the client getPlanSummaryData This helps to return the calculated summary data for each plan in the plan configuration screen This method uses Plan Summary class from BLL component to do the task getRegions This helps to return the list of regions available in the CPS database getCropsB yRegions This helps to return the list of crops available for a given region getCropTypesRegions This helps to return the list of CropTypes available for a given region getLandTypesRegions This helps t
103. ommentary Words HCLOC Header Comment Lines of Code HCWORD 5 Header Commentary Words Figure 10 3 2 SLOC Distribution of CPS iPhone App Based on SLOC P 4 Project Duration amp Burndown This project was planned to finish by the end of the spring semester The project proceeded smoothly without any major hiccups Below is the duration of the project along with the burndown chart which clearly shows that in Phase II and III project was ahead of schedule 125 Table 10 4 1 Project Duration and Burndown Phase Start Date Finish Date How well did it go Burndown Chart Phase I 01 15 2010 02 15 2010 Burndown Remaining To Do ase One Show Weekends 1 Burndown Remaining To Do 300 4 250 4 200 4 o Q 150 4 pd 100 4 50 4 0 T T T T T T T T 1 15 2010 1 20 2010 1 25 2010 1 28 2010 2 2 2010 2 5 2010 2 10 2010 2 15 2010 Sprints ToDo Ideal Phase II 2 16 2010 04 06 2010 Burndown Remaining To Do Sprint E Show Weekends C O cs Burndown Remaining To Do 400 4 300 8 Q 200 4 e 100 4 0 T T T T T T 2 15 2010 2 22 2010 3 1 2010 3 8 2010 3 15 2010 3 22 2010 3 29 2010 X 4 5 2010 Sprints ToDo Ideal Phase III 04 07 2010 05 04 2010 Sprint Ea Show Weekends Burndown Remaining To Do 300 4 250 4 200 4 150 4 3 100 4 50 4 0 50 T T T T T T 4 6 2010 4
104. outlined in section 3 1 Web application and section 3 2 iPhone application in CPS Vision Document Chapter 1 4 Features Not To Be Tested Non functional requirements outlined in section 4 in vision document chapter 1 will not be tested 5 Approach To test the CPS Software the user will perform a set of actions or Test Scenarios The scenarios will be evaluated by the visual results of the action performed The user will verify the result of each scenario with the Expected Outcome provided in section 10 Testing Task 6 Item Pass Fail Criteria For reach requirement a test suite is provided in section 10 Testing Task Each test suite will be considered successful if the outcome met the requirement stated in vision document and the result matches the expected outcome stated in test suite 71 7 Suspension Criteria and Resumption Requirement 7 1 Suspension Criteria If a test case fails all further testing will be suspended and failure will be logged into the testing log document a deliverable for the tester 7 2 Resumption Requirement For post test case failure testing will resume only after the failure has been logged in test log document and the solution of the failure is found and the fix is included in the source code as well as in the build 8 Test Deliverables The deliverables that will be produced by the tester upon completing test of CPS Software are 1 Test Log 11 Test Plan Each test must b
105. p count and 5 second ramp up period 88 Table 8 4 2 Response times by number of user for major web pages Number of Users Simulator App FAQ Page Home Page 20 45 18 3 50 3958 499 265 100 5070 1197 678 200 6617 3058 1215 500 10766 8544 3265 1000 1893 18823 6179 Figure 8 4 2 Performance testing graph of major CPS Web Pages 20000 18000 16000 14000 e N O e eo o o o 8000 Response Time ms 6000 4000 2000 200 500 1000 Number of User Performance Testing of Major Web Pages Simulator App E FAQ Page wale Home Page Observation We have captured response times of major web pages for 20 50 100 200 500 and 1000 users with 5 loop count and 5 second ramp up periods Simulator app is the main CPS web application which loads all the required data when first time page loads This helps to do client side computing for the subsequent request The size of Simulator page is 89 almost 49KB which is pretty good size This is why for 1000 users with 5 secs ramp up response time is around 18 secs The above stats was taken from home workstation which has very limited resources couple of years old machine with 2 GB RAM Deployment of CPS web application to a production level server and having a dedicated DB server can surely bring the response time down to less than 10 secs for 1000 users
106. p in both clients LandType This class represents type of the land e g Dry Irrigated etc and responsible to make operation to physical data table LandType This class is used to populate land type in plan configuration UI CropType This class represents crop system e g Organic Conventional and responsible to make operation to physical data table CropType This class is used to populate Crop System drop down in plan configuration screen CropDesc This class represents crop name e g Wheat Corn etc and responsible to 25 make operation to physical data table CropDesc This class promotes reusing crop name for multiple plans This class is used to populate crop list in plan configuration screen Crop This class represents crop that has been configured for a plan and responsible to make operation to physical data table Crop This is used to find out cost income profit Income This class represents Income data of a given crop and responsible to make operation to physical data table Income This is used to calculate income profit CpsSummary and CPSAnalysis data Cost This class represents Cost data of a given crop and responsible to make operation to physical data table Cost This is used to calculate cost profit CpsSummary and CPSAnalysis data 2 1 6 CPS Database Component This component holds the physical CPS Database the model of MVC design pattern
107. pectors Mr Amit Borcar Software Engineer Sage Software Mr Suresh Pothuri Software Engineer Sage Software 2 2 Tasks All project tasks are outlined in Project Plan document in Chapter 2 2 3 Responsibilities 2 3 1 Developer The developer is responsible for documentation implementation and testing of this project Three presentations will be given detailing project progress Bi weekly 66 meetings with the major professor are required these meeting are also open to all member of the committee 2 3 2 Major Professor The major professor is responsible for overseeing the work done by the developer S he must approve all artifacts of the project and is considered the end user for agent Tool IMs validation S he will also provide guidance and advice to the developer throughout the project s lifetime 2 3 3 Supervisory Committee The supervisory committee is responsible for preparing for and attending each of the three presentations The committee will provide comments on the artifacts presented during the presentation and feedback is expected at these times 2 3 4 Formal Technical Inspector The formal technical inspectors are responsible for completing a formal inspection of the project framework They will also conduct a preliminary functional walkthrough of the project 3 Documentation All documentation will be available at http cis895 nabi us 3 1 Purpose The purpose of the project documentation is to p
108. ppDelegate synthesize window synthesize rootController synthesize planOneNavControl ler synthesize planTwoNavControl ler synthesize planOneViewControl ler void applicationDidFinishLaunching UIApplication application Get the singleton object shnredAnnhata FAnnhntn shared nnhntaInstoncel 115 3 2 1 1 Configure a Plan Configuring a plan is a two step process o Select a region e g North Central all Carrier gt South Central Corn North East Crop Name Crop System Conventional South West Land Type PY South East Crop Acres North Central o For convenience all fields are populated except Expected Variation Change the value of Crop Land Type Crop System and Crop Acre that apply to your farm 3 2 1 2 Configure Crops Crop System and Land Type To change Crop Crop System and Land Type tap the down arrow button This will invoke a selection list Select the desired value and tap the OK button Below are few screenshots 116 C N Corn HIP SEU Soybeans Crop System Conventional p Sy p ov 7 kv Corn Land Type Crop Acres 10 Expected variation in percent Yield Price Cost Click on these button to change values of those fields t t Plan One Plan One all Carrier gt Select Crop System Select Land Conventional A ry Plan Two Plan Two 117 3 2 1 3 Expected Va
109. produced 2 3 3 Demo the CPS Software the release candidate All functional features outlined in the vision document in section 3 1 and 3 2 should be demonstrated Completion Criteria The phase will be complete once supervisory committee has approved 2 3 1 to 2 3 3 3 Cost Estimate 3 1 COCOMO The COnstructive COst MOdel COCOMO developed by Barry Boehm will be used to estimate project effort and time There are three modes based on software domains to estimate project effort and time in COCOMO These modes are organic semidetached and embedded Organic mode projects are less complex developments and have fair flexibility Embedded mode projects are usually similar to defense projects Complexity reliability and real time issues play a bigger role in embedded mode projects Semidetached mode projects represent a hybrid between organic and embedded mode projects The CPS Software based on SOA with Web and iPhone client have average complexity and fair flexibility Thus I would consider CPS in an organic mode project COCOMO cost estimation for organic mode projects follow the following formula Effort 3 2 EAF Size 11 05 Time 2 5 Effort 0 38 Where Effort number of staff months EAF Effort Adjustment Factor 13 Size number of lines of code for completed product It is measured in KLOC Time total number of months The Effort Adjustment Factor is the product of the 15 adjustment parameters Each adjustmen
110. ps FREQUENTLY ASKED QUESTIONS FAQ 1 am at the main home page How do I bring up the simulator Click on the Simulator hyperlink on the top navigation bar You can also bring up the simulator by clicking on Crop Profitability Simulator image Crop Profitability Simulator The Whole Farm CPS Crop Profitability Simulator allows farmers in Kansas and surrounding states to assess market risks for multiple farming plans including conventional and organic farming methods Eao ContactUs about ces HOME Plan 1 Plan 2 Plan 3 Crop Profitability Simulator In addition to the default values based on Kansas Farm Management Guides the Simulator allows you to customize your calculations to your individual situations in terms of specific revenue and cost items and possible variabilities in price yield and cost The whole farm profitability for multiple plans will be summarized in a graph for easy comparison If you have questions please refer to the Fi ly As page If the answer of your question is not available in FAQ pleara Sarid VOUK OURENSE ansi sddtessravallabie in TA eru Q 1 farm 200 acres of non irrigated land in northwestern Kansas If I want to grow corn on 100 acres and soybeans on 100 acres using conventional methods how do I simulate the whole farm profitability for mv plan a 3 1 3 Contact Us Click on Contact us link view the contacts of general questions or commen
111. riation For each plan there will be an Expected Variation table where the user can enter Yield Cost and Price that can vary at the user s farm The expected variation data helps estimate the best and worst of potential profit along with the average To enter expected variation data type a number and tap Done Selecting Done will cause the number pad to disappear mil Carrier gt 8 02 AM Plan configuration applied to your Farm Plan configuration applied to your Farm Crop Name heat V Crop Name d Crop System Conventional V Crop System Conventional V Land Type P V Land Type PY V Crop Acres 1 Crop Acres Expected variation in percent M Yield J Price Cost Y ABE Type a number and hit Enter to disappear the 5 number pad JKL 3 2 1 4 Plan Comparison and Summary To view a plan comparison side by side configure both Plan 1 and Plan 2 Then select the Summary tab The system should display a Return Over Cost summary table if an expected variation value is entered a the system will also display best and worst scenarios 118 all Carrier gt ill Carrier gt Crop Name Wheat V Crop Name em V Crop System Conventional V Crop System Conventional V Land Type P v Land Type PY V 100 Crop Acres Crop Acres Expected variation in percent Expected variation in percent Yield Price Cost Yield 2 Price
112. ributes No attribute is required for this web service class as this class is designed to have only web methods 48 2 1 3 Operation Specification of non getter setter constructor method Table 5 2 1 Operation specification of CPSServices Class Method Name GetRegions Signature Description public DataTable GetRegions Description This method returns list of Regions found in the database Behavior Pre None Post return datatable of regions found in the database Post if no regions found return null and give user at least one region must be configured message GetCropsByRegion Signature public DataTable GetCropsByRegion string regionName Description This method returns list of Crops found in the database for a given region Behavior Pre passed in data is valid Post return datatable of Crops if records found in the database Post if no crops are found for a given region return null and give user At least one crop needs to be configured for a given region message GetCropTypesB yRegion Signature public DataTable GetCropTypesByRegion string regionName Description This method returns list of CropTypes configured in the database for a given region Behavior Pre passed in data is valid Post return datatable of CropType if records found in the database Post if no CropTypes are found for a given 49
113. ricePerBushel double Price per bushel govtPayment double Government payment 59 indemnityPayment double Indemnity Payment miscIncome double Miscellaneous income yieldLevelld int Yield level returnPerAcre double Default average return per acre highEndReturn double The highest return user may have based on the expected variation data This is calculated field lowEndReturn double The lowest return user may have based on the expected variation data This is calculated field 4 5 3 Operation Specification of non getter setter constructor method Table 5 4 8 Operation specification of Income Class Name Description LoadByCrop Signature public bool LoadByCrop string regionName string cropName string landType string cropType int yieldChange int priceChange int yiedLevellId Description It loads the Income object Returns to true if all data passed in is valid and load successful Otherwise return false Usage This method is used by iPhone client where it only needed to return the default found in the database income value based on the given crop configuration Behavior Pre Passed in data is valid Pre a record should exists in the table class represent Post return true if record exists and load successful Otherwise return false Post give user record not found message if record does not exists Load Signature public bool Load double yield
114. rk packet size bytes 4096 Clock Time ms total 15 C KSUNDatabaseSetup gt bep CPS dbo Crop in DataFiles Crop txt c T Starting copy 216 rows copied Network packet size bytes 4096 Clock Time ms total 16 C KSUNDatabaseSetup gt bep CPS dbo Cost in DataFiles Cost txt c T Starting copy 216 rows copied Network packet size bytes 4096 Clock Time ms total 46 C KSUNDatabaseSetup gt bep CPS dbo Income in DataFiles Income txt c T Starting copy 216 rows copied Network packet size bytes 4096 Clock Time ms total 15 si LoadResults tst File LoadResults txt 1450 bytes 48 lines PC ANSI 98 2 3 2 Install CPS Web Application 1 Download the CPS Web Client MSI Package Available online at http home nabi us CpsWeb docs PhaselllI Setup CpsWebClientSetup msi 2 Double click the CpsWebClientSetup msi file and load the CPS Web Client 1 0 setup wizard 3 Click on Next button to continue Li ox Welcome to the CPS Web Client 1 0 Setup Wizard PAG Prianacen nro _ Kansas Sate Universty The installer will guide you through the steps required to install CPS Web Client 1 0 on your computer WARNING This computer program is protected by copyright law and international treaties Unauthorized duplication or distribution of this program or any portion of it may result in severe civil or criminal penalties and will be prosecuted to the maximum extent possible under the
115. rn one row and when expected variation given a CpsWebServiceSetup H Value in High column is greater than value in Mean column El c Server TestMethod cH DALC c public void GetCpsinalysisDataTest LM Cpsws t El sf BLLC CPSServices target new CPSServices gt i UnitTest target Url AppSetting GetServiceURL To maintain the quality E ie Solution Items string regionName North West prlde 43 CPSApp vsmdi string eropName Corn fiware 48 LocalTestRun testrunconfig string landType Dry kating io aide e Gi CpsTest yp Y make sure web services Ea Properties string cropType Conventional return as it is expected 3 aaj References string sYieldChange 5 and make sure DALC 3 AuthoringTests txt string sPriceChange string Empty and BLLC works as F i i E CPSServicesTest cs string sCostChange string Empty designed Te Utils string planName Plan One aj Properties Sj References AppSetting cs qe CPSProxy cs Utility cs esults a All 6 web services returend the expected resulis all passed GetRegionsTest GetCropTypesByRegionTest 19 Passed 19 Passed CpsTest 19 Passed 19 Passed 19 Passed 19 Passed GetCpsAnalysisDataTest GetPlanSummaryDataTest GetCropsByRegionTest GetLandTypesB
116. rovide a reference and timeline for this project Other project documentation may be required this is at the discretion of the project developer and major professor The current state of the documentation will be evaluated by the major professor within each phase of the development and must be approved by all committee members at the conclusion of each phase 67 3 2 Minimum Documentation Requirements Table 6 3 1 List of documentation required for each phase Phase I Phase II Phase III Project Plan 1 0 Project Plan 2 0 Component Design 1 0 Vision Document 1 0 Vision Document 2 0 Formal Inspection Letters SQAP 1 0 Test Plan 1 0 Project Evaluation 1 0 Formal Inspection Check List Project Source Code Formal Requirement Specification User Manual 1 0 Architectural Document 1 0 Executable Project Executable Architecture Prototype 4 Standards Practices Convention and Metrics IEEE standards will be followed for documents when applicable throughout this project C naming conventions and practices will be followed for all project coding COCOMO will be used as a cost estimate metric 5 Reviews and Audits All artifacts produced will be reviewed and assess by the supervisory committee This includes all documents and executable project code The artifacts will be evaluated at the conclusion of each phase which is marked by one of the three presentations 6 Testing Test Plan 1 0 will out line testing procedures a
117. s to maintain the quality of the Service Oriented CPS Software unit tests were added to the source code and tested by the developer The scope of the unit tests were limited to the Web Service Component only Since the framework for unit testing is already in place adding unit tests for other components should be very easy and straight forward Below is the screenshot of the result of the unit tests of all web services 92 B CPSApp Microsoft Visual Studio File Edit view Refactor Project Build Debug Data Test Tools Window Help Dlo k3 KO G9 EG E EQ il ed 4 a A gt 0 gt Debus LEY RS ae dE S BO B 2 6 2393 88 a 8Q amp _z int expectedRowReturned 1 int actualRowReturned DataTable dt target GetCps nalysisData regionName actualRowReturned dt Rows Count Make sure it returne expeced 1 row for the given plan one Assert amp reEqual expectedRovReturned actualRowReturned i When waristion ia riven cropNar make sure valne in Hinh and CPSServicesTest cs vx gt r f e1 E amp t CpsTest CPSServicesTest v GetCpsAnalysisDataTest i L 5x Solution CPSApp 8 projects a summary fx Ch x Client Ar SESE for GetCpsinalysisData web method used to do plan comp A cpsweb E i lt summar y 06 Deployment z Make sure for a given plan configuration it at least CpsWebClientSetup retu
118. so be produced 2 2 4 Test Plan 1 0 The test plan will include a complete testing procedure for the project This will include all test suites required to test all the functional requirements and appropriate procedures for reporting and correcting failed test 2 2 5 Architecture Inspection Two professional Software Engineers will perform formal technical inspections and send their report to major Professor Dr Andresen 2 2 6 Demo the Prototype Most of the functional requirements should be demonstrated end of the elaboration phase If there is any architectural challenge is encountered and failed to demo most of the functional requirements committee must be notified at least a week before the 2nd presentation Completion Criteria The phase will be complete once supervisory committee has approved 2 2 1 to 2 1 6 2 3 Production Phase The production phase will include project implementation and testing This phase includes project coding and documentation 2 3 1 Project Coding and Testing Project coding will consist of all committee approved and designated tasks to be coded and developed Testing will be done while coding and Test plan 1 0 document will be revised and updated with appropriate changes 2 3 2 Project Documentation 12 A complete User Manual document of the CPS software will be produced In addition to the final report of the project Component Design document and project evaluation document will also be
119. t e de Rs 79 3 Detailed Test Res lts ma uire eaey A A EE ae Meee 79 3 1 Test Results of CPS Web Application 00ii A A dr nae 79 3 2 Test Results of CPS iPhone Application 2 uoo iso uberes e rer De E Pare da Hen kv ER Y ME 84 4 Performa ce Testing secors T cap 87 4 1 Response Time Comparison of Web Services cece cece eee ence ene ene enact eenaeees 87 4 2 Response Time Comparison of Major Web Pages csse 88 4 3 Comparison of Response Time of 1000 users with different ramp ups 90 4 4 Throughput of 1000 users with 5 loop count and 5 sec ramp up eeee eee eens 91 A PES INS ues ovals ad E ME 92 CHAPTER 9 USER MANUA Lin It ac 94 INTO GUCIION iese ii E E A A A dE 94 2 Software Installation Li ol 95 2 Required Hardware OA AAA 95 2 2 Required SOftWAtEe sins 95 2 2 1 Required Software CPS Web APD ero E RUE EY EE g UE RO ERE 95 2 2 2 Required Software CPS iPhone APP ee eva x quss oa o ES eve is 95 2 5 Install C PS Sof ware and Setup ae sco SO ER DO ERO RE E 96 2301 Load Databases su ose E E 96 2 3 2 Install CPS Web Application cs iia 99 233 Install CPS Web Service serisini rise eaen oa HUI EE EEN E N EENES 102 2 3 4 Install CPS 1Phone Chent li seve ton e ess odie A AAA 105 SC PS Software Operation roo 106 3 1 CPS Web Application Operation iii 106 3 11 Home Main Home Padel i t ede en reos pe PES Su dennes es SE oi E p PERRO
120. t have at least one Crop configured At least one or more cost and income data is forced by association CropCostMap and CropIncomeMap by multiplicity 1 3 Constraints No 2 context Region inv HaveAtLeastOneCropCofigured self cropsByRegion gt size gt 1 and Region allInstances gt asSequence gt size gt 1 For each Yield Level make sure number of Costs and Incomes are equal This will help to make sure the data is in sync NOTE For fun I made these functional and using them here Constraints No 3 context crp Crop inv CostAndIncomeDataMustBelnS ync crp getCostsB y YieldLevel A verage gt size crp getIncomesBy YieldLevel Average gt size and crp getCostsBy YieldLevel High gt size crp getIncomesBy YieldLevel High gt size and crp getCostsB y YieldLevel Low gt size crp getIncomesBy YieldLevel Low gt size 38 In Income make sure cropId is unique for a given yieldLevel Constraints No 4 context incm1 Income inv NoDuplicateCropIdInIncomePer YieldLevel Income allInstances forAll incm2lincml cropId incm2 cropId and incm1 yieldLevel incm2 yieldLevel implies incm1 incm2 In Cost make sure cropld is unique for a given yieldLevel Constraints No 5 context cst1 Cost inv NoDuplicateCropIdInCostPerYieldLevel Cost allInstances gt forAll cst2lestl cropId cst2 cropld and cstl yieldLevel cst2 yieldLevel implies cstl cst2 Make sure system at least has one reg
121. t is created with Average yield level but Cost object is created with High yield level Hence constraint 3 failed SCRIPTS RAN use gt read constraint 3 fails cmd constraint 3 fails cmd gt check checking structure checking invariants checking invariant 1 Cost NoDuplicateCropIdInCostPerYieldLevel OK checking invariant 2 Crop CostAndIncomeDataMustBelnSync FAILED gt false Boolean checking invariant 3 Crop CropIdIsUnique OK checking invariant 4 Income NoDuplicateCropIdInIncomePerYieldLevel OK checking invariant 5 Region HaveAtLeastOneCropCofigured OK checked 5 invariants in 0 010s 1 failure constraint 3 fails cmd use 43 Constraint No 4 NoDuplicateCropIdInIncomePerYieldLevel Fails Explanation In incm3 cropld 2 and yield level Average is used intentionally to break the constraint As per the requirement for a given yield level Income cannot have duplicate cropld In this case cropld 2 is used in incm2 object Hence constraint 4 will not hold SCRIPTS RAN use read constraint 4 fails cmd constraint 4 fails cmd gt check checking structure checking invariants checking invariant 1 Cost NoDuplicateCropIdInCostPerYieldLevel OK checking invariant 2 Crop CostAndIncomeDataMustBelnSync OK checking invariant 3 Crop CropIdIsUnique OK checking invariant 4 Income NoDuplicateCropIdInIncomePerYieldLevel FAILED false
122. t parameter is defined as very low low nominal high or very high The table 1 below shows all the adjustment factors and their ranges Table 2 3 1 COCOMO EAF Parameters Identifier Effort Adjustment Factor Range RELY Required reliability 0 75 1 40 DATA Database size 0 94 1 16 CPLX Product complexity 0 70 1 65 TIME Execution time constraint 1 00 1 66 STOR Main storage constraint 1 00 1 56 VIRT Virtual machine volatility 0 87 1 30 TURN Computer turnaround time 0 87 1 15 ACAP Analyst capability 1 46 0 71 AEXP Applications experience 1 29 0 82 PCAP Programmer capability 1 42 0 70 VEXP Virtual machine experience 1 21 0 90 LEXP Language experience 1 14 0 95 MODP Use of modern practices 1 24 0 82 TOOL Use of software tools 1 24 0 83 SCED Required development schedule 1 23 1 10 Table 2 3 2 Adjusted EAF Values applied to CPS Project Identifier Level Reasoning My Value RELY Low Project is not safety critical 0 76 14 DATA Low Current size of the database is low But i twill grow in future 0 98 CPLX Moderate Complexity of the product is medium 1 1 TIME Moderate Project need to respond to client The Committee 1 15 STOR Low No store constraint 1 0 VIRT Moderate Complexity of the software and hardware is moderate 0 95 TURN Very Low Results are reported to the
123. ta Crop crp int landArea Cost c Income i Description It takes Crop landArea Cost and Income object and it calculates as per the business rule and return PlanSummary datatable Behavior Pre Passed in data is valid Post return plan summary datatable Post if invalid data found return null and give user invalid data message Load Signature public bool Load Cost c Income i string planName Description It loads the PlanSummary object Returns to true if all data passed in is valid and load successful Otherwise return false Behavior Pre Passed in data is valid Post return true load successful meaning all data is valid Otherwise return false Post give user Invalid data message if load unsuccessful 52 3 2 CPSAnalysis 3 2 1 Description This helps to represent CPS Analysis data which is used to draw graph and display overall return over costs with High Low Mean value if expected variation entered for multiple plans side by side 3 2 2 Attributes Table 5 3 3 Attributes of CPSAnalysis Class Name Type Description planName string Plan Description expectedVariation string Expected variation applied to user s estimate High double Highest profit user may have Mean double Average profit Low double Lowest profit user may have 3 2 3 Operation Specification of non getter setter constructor method Table 5 3 4 Operatio
124. th User should be able to select the Able to select or down arrow next to land type and crop system without change Crop LandType and Crop any error System and Land System Type using the down arrow button as well without any error TS6 6 In the expected variation You should see Return Over Entered 5 in the 85 form of plan one enter some number e g 5 in yield field Then click on Summary tab TIPS Regarding closing the number pad after typing or selecting number from the number pad you need to hit enter to close the number pad Cost table populated with high low and mean value returned from the backend server via web service yield field and click on the summary Noticed that it displayed the High and Low value in the Return Over Cost table in Summary tab TS 6 7 TS6 8 Click on Plan Two tab and configure another crop with the crops system land type total acre and expected variation you like Then click on Summary tab Note down the plan one and plan two configurations you have performed Do the same configuration using CPS Web application With the second plan configured you will see that summary page is updated with the high low and mean value of the second plan Verify that the high mean and low value in the Return Over Cost table in both CPS iPhone application and CPS Web application is the same
125. tion 1 0 invariants to holds violates Test CPS Software and verify thatit CPS Software L7 meets all functional requirements stated in section 3 1 and 3 2 in vision document NOTE This item will help to maintain supplier control guideline stated in Quality Assurance Plan Document 1 0 47 CHAPTER 5 COMPONENT DESIGN 1 Introduction The purpose of this chapter is to outline the internal design of server side components such as Web Service Component Data Access Layer Component DALC and Business Logic Layer Component BLLC that we discussed briefly high level in section 2 of Chapter 3 Architecture Design For a component diagram of the whole CPS Software please refer to Figure 3 2 1 Component Diagram of CPS Software in chapter 3 2 Web Service Component WSC This section provides class diagram of Web Service Component and detailed description of each class WSC is responsible serves the client s Web Client or iPhone Clinet request using BLLC or DALC based on the type of the request Figure 5 2 1 Class Diagram of Web Service Component 2 1 CPSServices Class 2 1 1 Description CPSServices class is the heart of SOA This class implements all the required web methods web service to facilitate clients Web app or iPhone app to have access to BLL Business Logic Layer Data Access Layer components and Database Component and return the results to the caller client 2 1 2 Att
126. tion 3 2 iPhone application 3 1 Features of CPS Web Application 3 1 1 Home Main Home Page The product will have a hyper link called Home which will be displayed when the user accesses the CPS application URL at http home nabi us CpsWeb Content of the main home page includes short description of the Whole Farm CPS product how to access the simulator frequently asked questions and hyperlinks to major sponsors of this project 3 1 2 FAQ The product will have a hyperlink for frequently asked questions FAQ with answers and screenshots where applicable The information in the FAQ section will help users understand the product its uses and troubleshoot issues without contacting support 3 1 3 Contact Us The product will have a hyperlink called Contact us which will provide the user with the contact information of resources for general questions or comments The information of the contact page includes name email phone number and physical address 3 1 4 About CPS The product will have a hyper link called About CPS which will display the name of the product version build date and copyright information 3 1 5 Simulator The product will have a hyper link called Simulator which will bring up the main Crop Profitability Simulator application The CPS application has the following features available 3 1 5 1 Plan A user is able to specify up to 4 plans with different combinations of crop acr
127. totype case Na 11 2 2 PlADOrallON PASC isi tede dl Se et eg E DS IA A Led ceo 11 2 2 1 Architectural Design Document 1 iecore hx rye da 11 2 2 2 Revision of Project Plan and Vision Document eee 11 2 2 9 Formal Specification id 11 224 TestPlandU s ecustteset bees bes eet Pot ie tenebo Pte eet Pott SE Edel etw the 12 229 7 Architecture Inspection SS d lop tod EU UHR Ve d DESEAS dde dee 12 22 0 Demo the Prototype pa eie nr E E Sa PER OR PPAR Vera eee EE UE 12 2 3 Production Phase Sarerea cree reo e a rara ed er dabas dud 12 2 3 D Project Coding ana Cesta oe Io RT twp PUE ad Ded alas 12 2 3 2 Project DOCumeltatiONic ei cape sacsuwar canes nian gents Ro YERe HN REPE LETT MEI RYE EIU S OUI 12 2 3 3 Demo the CPS Software the release candidate ccc ccc cece cece ects eee e cece cues 13 iv SACOS Estimate eese A o ld 13 A ia on 13 4 Panta incas E AE At 16 4 1 Phase One Inception Sprint Pla ata 16 4 2 Phase Two Elaboration Sprint PlaN oooococcccoccconcconcccnncconcccnnccnnnon cnc emen 17 4 3 Phase Three Production Sprint Plan 1 eeeceet eese ttr tere ene drid 17 CHAPTER 3 ARCHITECTURE DESIGN eeeeeeeeeeetee hehehe nennen tenente 18 LOA EE 18 Is de PU OSC sates use p p HN ob set e bsc b tec e isst Ce tisch 18 1 2 Terms and DO a e a cds dee 18 LISO DE BM 18 2 Te tec Ure pE the SM S e dene pisa e tpa rr CHE DESIT epu ida 19 2 1 Component VIEW xci A RE Bes badly TA
128. ts 107 The Whole Farm Crop Profitability Simulator lt gt J http slocalhost CpswebClient ContactUs aspx Qr Google Br O Apple Yahoo Google Maps YouTube Wikipedia News 60 Y Popular When we are planning for posterity we ought to remember that virtue is not hereditary Thomas Paine PPMANAGERINFO WHOLE FARM cu I EOSS 1 simulator cao Contac us ds CONTACT US Department of Agricultural Economics Kansas State University 345 Waters Hall Manhattan KS 66506 4024 Questions or Comments contact Dr Kevin Dhuyvetter Dr Rich Llewelyn Phone 785 532 3527 Phone 785 532 1504 Email kcd ksu edu Email rllewely ksu edu 2008 Kansas State University 3 1 4 About CPS Click on About CPS link to view the name of the product version and copyright information 9 The Whole Farm Crop Profitability Simulator zox e Qy Google Gr x YouTube Wikipedia News 60 Y Popular v lt gt nttp localhost Cpsweb AboutCPS aspx Q Apple Yahoo Google Maps When we are planning for posterity we ought to remember that virtue is not hereditary Thomas Paine PPANAGERINFO WHOLE FARM Crop Profitability Simulator Home simulator FAQ contact us fabout cps ABOUT CPS Crop Profitability Simulator CPS Version 1 0 Copyright c 2008 Kansas State University All Rights Reserved 2008 Kansas State University
129. ts F MenuDb J Adventureworks OBS ul Adventure WorksDW Bin E BudgetSimulator ProjectTracker y an y UniBD E gj Security Y Menudb E Server Objects y OBS A Replication E ORCA D Management y PMD 3j 3 Notification Services U ProjectTracker B SQL Server Agent Agent XPs disabled T UniBD 96 E New Database By 1 MB unrestricted growth By 10 percent unrestricted growth Server CHIMP Connection sa EN View connection properties 3 Load the CPS Schema by executing CreateSchema sql which is available under DatabaseSetup folder P CPS CreateSchema sql USE CPS Create CropDesc Table SET ANSI_NULLS ON Go SET QUOTED IDENTIFIER ON Go IF NOT EXISTS SELECT FROM sys objects WHERE object id OBJECT ID N d BEGIN CREATE TABLE dbo CropDesc CropDescID int IDENTITY 1 1 NOT NULL Name nvarchar 200 COLLATE SQL Latini General CP1 CI AS NULL Active bit NULL CONSTRAINT PK CropDesc PRIMARY KEY CLUSTERED I ProjectTracker D ASC UniBD CropDescID WITH IGNORE_DUP_KEY OFF ON PRIMARY E GA Database Diagrams ON PRIMARY El LA Tables one El CA Views El A Synonyms E EA Programmability Go El LA Service Broker El LA Storage Create CropType Table Cg Security SET ANSI NULLS ON Cg Security Go E A Server Objects SET QUOTED_IDENTIFIER ON E Replication Go LA Management IF NOT EXISTS SELECT FROM sys objects WHERE object id OBJEC
130. uct CPS e The web services and web application will be deployed on Windows 2008 server running NET framework 3 5 or higher IIS will be used on the http server MS SQL Server 2008 will be used for the back end database The website can be viewed through common Internet browsers e The iPhone CPS application will be running on IPod Touch or iPhone OS 3 0 or higher An internet connection will be required to run the CPS application as the client will be communicating with backend server via web services 2 4 Design and Implementation Constraint The AJAX enabled web application will be built using the Microsoft NET framework and C C Sharp will be used to develop the product The iPhone application will be built using Cocoa framework and Objective C will be used to develop the product Both web and iPhone application will be built on SOA and both clients will communicate with the same server components via web services The SOA will facilitate a modular design scalability robustness loosely coupled application integration and interoperation and software reuse 2 5 User Documentation A user manual will be provided for both the CPS web application and the iPhone application The user may contact the developer of this product or Dr Andresen regarding any ambiguity in the documentation 3 Project Requirement The Whole Farm CPS product will have the following features requirements stated in section 3 1 Web application and sec
131. ventional Organic 63 4 7 3 Operation Specification of non getter setter constructor method Table 5 4 12 Operation specification of CropType Class Name Load Description Signature public bool Load int id Description It loads the CropType object Returns to true if data passed in is valid and load successful Otherwise return false Behavior Pre Passed in data is valid Pre a record should exist in CropType table by the id passed in Post return true if record exists and load successful Otherwise return false Post give user record not found message if record does not exists FindByRegion Signature public DataTable FindByRegion string regionName Description Behavior It finds all the CropTypes configure for a given region and retuns the datatable Pre None Post return list of CropType configured for a given region Post If no CropType configured then returns null and give user at least one CropType needs to be configured for a given region message 64 4 8 YieldLevel Class 4 5 1 Description This class represents level of Yield a farm produce e g Average High and Low This class is responsible to make operation to physical data table YieldLevel Currently our database only have data that belongs to Average yield level In future we have plan to store Farm management guide data for other yield level as
132. well 4 8 2 Attributes Table 5 4 13 Attributes of YieldLevel Class Name Type Description yieldLevelld Int Yield Level ID Name String Description of Yield Level e g Average High Low 4 8 3 Operation Specification of non getter setter constructor method Table 5 4 14 Operation specification of YieldLevel Class Name Description Load Signature public bool Load int id Description It loads the YieldLevel object Returns to true if data passed in is valid and load successful Otherwise return false Behavior Pre Passed in data is valid Pre a record should exist in YieldLevel table by the id passed in Post return true if record exists and load successful Otherwise return false Post give user record not found message if record does not exists 65 CHAPTER 6 SOFTWARE QUALITY ASSURANCE PLAN 1 Purpose This document is produced to outline the necessary steps to ensure the project has an acceptable level of quality It will describe the necessary steps taken to ensure quality throughout the entire life cycle process for this project 2 Management 2 1 Organization Below is a listing of the organization and their roles with the MSE project for developing CPS Software Developer Mr Reza Nabi Major Professor Dr Daniel Andresen Supervisory Committee Dr Daniel Andresen Dr Mitchell Neilsen Dr Hikaru Peterson Formal Technical Ins
133. with 5 sec even with poor machine like the developer s With a production level server and having a dedicated DB server can surely bring the response time down to 1 or 2 secs 4 4 Throughput of 1000 users with 5 loop count and 5 sec ramp up This section displays graph result along with summary table of a test ran with 1000 user 5 loop count and 5 sec ramp up period which is also plotted in the section 4 1 graph Performance testing with major web pages The throughput found in this test 3996 min supports earlier finding in section 4 3 where we concluded that the CPS Software should have no problem entertaining sudden burst of couple thousand users within 1 to 2 minutes i e 60 to 120 ramp up secs Figure 8 4 4 Graph results of 1000 users with 5 loop count and 5 secs ramp up E Simulator jmx C CIS Simulator jmx Apache JMeter 2 3 4 1785646 File Edit Run Options Help 0 1000 9 amp Test Plan E Simulator Hif HTTP Request Deta E Summary Report Pp Simulator Pp Faq Pp Home E Graph Results E WorkBench Graph Results Name Graph Results Comments Write results to file Read from file Filename 29730 ms Oms 4 r Browse LogDisplay Only Errors _ Successes Configure Graphs to Display v Data v Average y Median v Deviation y Throughput No of Samples 15000 Deviation 9421 Latest Sample 2 Throughput 3 996 323 minute Average 14644
134. y Apple yet which requires membership with Apple the only way we can operate the iPhone application is via simulator built in XCode an IDE for iPhone development To launch the CPS Phone application do the following e Configure the Web Service URL for the Phone Application To do this open CPS Info plist file and change the value of ServiceURL parameter that applies to your installation CPS Info plist Key Value w Information Property List 14 ite English Localization native development re Bundle display name CPS 1 0 Executable file EXECUTABLE_NAME Icon file aglogo png ServiceURL http rnd CpsWebService CPSServices asmx ServiceNameSpace Bundle identifier InfoDictionary version Bundle name Bundle OS Type code Bundle creator OS Type code Bundle version Application requires iPhone enviror Main nib file base name http agmanager info com yourcompany PRODUCT_NAME rfc 103 4identifier 6 0 PRODUCT_NAME APPL 70 1 0 M MainWindow e Load the project by double clicking CPS codeproj file 114 1 of 36 selected 199 42 GB available Date Modified Size Kind v a va aglogo AppData h AppData m gt build gt Classes CPS Prefix pch CPS Info plist fx CPS xcodeproj DataSet h DataSet m ddl DdiBase h DdiBase m DdiCrop h DdiCrop m DdiCropSystem h DdiCropSystem m DdiLandType h DdiLandType m doneup graph pn
135. yRegionTest CpsTest CpsTest CpsTest CpsTest Ready Ln 198 93 y Solution Explorer gg Class View Col 41 ch 41 INS CHAPTER 9 USER MANUAL 1 Introduction The Whole Farm CPS Software allows farmers in Kansas and surrounding states to assess market risks for multiple farming plans including conventional and organic farming methods In addition to the default values based on Kansas Farm Management Guides the Simulator allows you to customize your calculations to your individual situations in terms of specific revenue and cost items and possible variability in price yield and cost The whole farm profitability for multiple plans will be summarized in tabular format and Graph for web client for easy comparison Detailed feature is available in section 3 Software Operation Figure 9 1 1 CPS Software Highlights Plani Plan2 Plan3 Plan4 Summary Details y Plan162 46 30 Cost 4 Yield 3 Price 2 2 60 o a Plan2 45 25 6 Cost 5 Vield 49 Price 49 L J 40 E 20 Plan 1 Pian 2 Builtusing ChartFXfor NET Development SUMMARY PLAN 1 Crop Acres Income Cost Return Over Cost Crop Acres Income Cost Return Over Cost Corn 100 330 284 46 Wheat 100 261 235 25 Farm Per Acre 3310 284 6 Farm Per Acre 261 235 25 Farm Total 100 330 284 46 Farm Total 100 261 235 25 sl Carrier gt 10 10 PM gt 11 26 PM South West 62 46 30 6 Wheat v
136. zword it is real when it comes to achieving the highest level of interoperability loosely coupled integration modularity and software reuse Future works of this project are comprised of two parts first get an Apple Developer Membership and package the iPhone client code so that it can be deployed on an actual iPhone device with ease second I would add more features to the iPhone client allowing users to enter their custom data and view summary details 127 References 1 Stephen G Kochan Programming in Objective C 2 0 A complete introduction to the Objective C language for Mac OS X and iPhone development Addision Wesley 2009 2 Aaron Hillegass Cocoa Programming for Mac OS X Addision Wesley 2008 3 Apple iPhone Development Center Online Available http developer apple com iPhone Accessed January 2010 4 Apple iPhone human interface guidelines Online Available http developer apple com iPhone library documentation UserExperience Conceptual MobileHI G Introdu ction Introduction html Accessed January 2010 5 Parichat Pasatcha Komrhon Sunat A Distributed e Education System Based on the Service Oriented Architecture IEEE Computer Society 2008 6 Guillermo Licea Leocundo Aguilar Reyes Ju rez Ram rez Luis G Mart nez iPECH a framework for generating views in iPhone iPod touch applications IEEE Computer Society 2009 7 Hongqi Li Zhuang Wu Research on Distributed Architecture Based

Download Pdf Manuals

image

Related Search

Related Contents

  Philips SHAVER 9000 SensoTouch 3D RQ1260  パーツリストPDF  LCS Guide - kiteassessments.org  Ouvrir S.V.P. Openklappen Bitte aufklappen Mode d`emploi Barbecu  MPL-16V5.0-PCIWXP 取扱説明書  BV 69E - BV 77E - Van Spijk Agenturen  Calibrating your DAW Studio  Viewsonic Professional Series VP720 - 17" Ergonomic LCD Monitor  

Copyright © All rights reserved.
Failed to retrieve file