72. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 9/24/2019 1:38:02 PM Eastern Daylight Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

72.1 Files compared

# Location File Last Modified
1 PCL-5_v1_build_8.zip\v1_build 8\Unredacted\spp_mha_web-development.zip\spp_mha_web-development\Docs Developer Setup Eclipse For Spring MHA Web.docx Wed Jul 31 17:35:31 2019 UTC
2 PCL-5_v1_build_8.zip\v1_build 8\Unredacted\spp_mha_web-development.zip\spp_mha_web-development\Docs Developer Setup Eclipse For Spring MHA Web.docx Mon Sep 23 21:58:51 2019 UTC

72.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 1 256
Changed 0 0
Inserted 0 0
Removed 0 0

72.3 Comparison options

Whitespace
Character case Differences in character case are significant
Line endings Differences in line endings (CR and LF characters) are ignored
CR/LF characters Not shown in the comparison detail

72.4 Active regular expressions

No regular expressions were active.

72.5 Comparison detail

  1   Developer  Environmen t Setup Fo r OT5
  2   Prerequisi tes
  3   RTC is set up and you  have impo rted the p roject suc cessfully  (see RTC S etup Doc).
  4   You have N odeJS inst alled (you  can run n pm from th e command  line)
  5   Nice to Ha ve
  6   JDK 1.8 or  higher in stalled an d java on  the PATH a s a system  variable.
  7   Installing  JDK
  8   If you do  not have e levated pr ivileges,  skip this  as we have  a tempora ry work ar ound.
  9   You can in stall the  JDK 1.8 fr om here: h ttp://www. oracle.com /technetwo rk/java/ja vase/downl oads/jdk8- downloads- 2133151.ht ml 
  10   Then you n eed to add  it to the  path. 
  11   You can ch eck if it  has alread y been add ed to the  path by op ening a co mmand prom pt and typ ing “java  -version”
  12   See this s tackoverfl ow answer  if you nee d add it t o the PATH : https:// stackoverf low.com/qu estions/16 72281/envi ronment-va riables-fo r-java-ins tallation 
  13   1. Eclipse  Project I mport
  14   Extract Ec lipse from  the zip f ile to an  easy acces s location  (ie: User /username/ dev/)
  15   ***It is r ecommended  you have  the “Eclip se IDE for  Java EE D evelopers” ***
  16   Launch Ecl ipse by do uble click ing the pu rple plane t icon in  the newly  extracted  folder.
  17   Eclipse wi ll prompt  you where  you’d like  to store  your works pace. (It’ s recommen ded you ke ep it insi de your ec lipse fold er and not  in where  you keep y our source  files)
  18   Then Click  Launch.
  19  
  20   You should  see a scr een simila r to the f ollowing.
  21  
  22   Click File  > Import  then selec t Maven th en double- click Exis ting Maven  Project.
  23  
  24   Point the  root direc tory to be  the locat ion of our  project w hich is MH LTHWorkspa ce/Javascr ipt/Java/m ha-web.  N OTE: this  is the mha -web/ dir  inside the  Java dire ctory).
  25  
  26   Click Fini sh and the  wizard sh ould close . (This sh ould takes  a few min utes to im port so ho ld tight).
  27   When you s ee this di alog below , click Sh ow Solutio ns.
  28  
  29   You should  see an op tion like  the one fe atured bel ow. Instal l this opt ion.
  30   ***if you’ re on a sl ow GFE and  cannot cl ick the “E clipse Mar ketplace”  window, yo u may need  to click  “Cancel” o n the dial og picture d above in  order to  be able to  click “in stall”.
  31  
  32  
  33   Once you c licked ins tall, you  should see  a dialog  like pictu red below.  Make sure  all the b oxes are c hecked as  featured i n the scre enshot bel ow. Once y ou’ve veri fied the c orrect box es are che cked, clic k Confirm.
  34  
  35  
  36    Accept th e license  agreement  and click  Finish.
  37  
  38   Wait while  this inst alls. You  should see  a green b ar in the  bottom rig ht corner  of Eclipse .
  39    When you  see a dial og like th e one belo w, click I nstall Any ways and c ontinue wa iting unti l Eclipse  prompts yo u to resta rt then cl ick Restar t Now.
  40  
  41  
  42    Once Ecli pse has re started, c lick on th e tiny pac kage explo rer icon p ictured be low to exp and your p roject.
  43  
  44  
  45  
  46   2. Eclipse  Run Confi gurations  (Optional)
  47   Please ski p to secti on 3 unles s you are  confident  with your  abilities  to run pro jects in E clipse.
  48   You can ru n through  this secti on if you  would like  to levera ge running  all your  code insid e Eclipse.  If you ha ve npm and  mvn insta lled and w ant to run  from the  command li ne, jump t o section  4. This is  helpful i f you do n ot have el evated pri vileges on  your syst em. Howeve r, it is p referred t o run any  maven or n pm command s from the  command l ine (secti on 4) to i solate any  issues.
  49   Maven Conf igurations  in Eclips e (Optiona l)
  50    From the  top nav ba r, click R un > Run C onfigurati ons.
  51    Select Ma ven Build  then click  the “new”  icon circ led in the  screensho t below.
  52  
  53    Name it i nstall, pu t install  in the goa ls field a nd point t he base di rectory to  the proje ct using t he File Sy stem butto n and not  the worksp ace button . Then Cli ck Apply.
  54  
  55  
  56    Click the  JRE tab a nd then se lected Ins talled JRE s.
  57  
  58   Click the  Add button
  59  
  60   Then click  Standard  VM > Next.
  61    Click Dir ectory fro m the pane l below an d browse t o your JDK ’s directo ry (the ex ample has  the JRE bu t please p oint to yo ur JDK dir ).
  62   NOTE: if y ou do not  have eleva ted privil eges and d o NOT have  JDK insta lled, you  will have  to use the  OpenJDK u ntil you c an install  the JDK f rom Oracle . If this  is the cas e, point y our direct ory here t o MHTLHWor kspace/Jav ascript/Ja va/Resourc es/java-1. 8.0-openjd k-1.8.0.16 1-1.b14.oj dkbuild.wi ndows.x86_ 64/
  63  
  64   You should  see all J RE Librari es load li ke picture d below if  successfu l.
  65  
  66  
  67    Click Fin ish. Then  select the  newly imp orted JRE  and click  Apply and  Close.
  68  
  69   3. Running  the Appli cation Fro m the CLI
  70   To run thi s portion  from the C LI, you mu st have ma ven AND np m installe d. 
  71   For Maven  downloads  see : http s://maven. apache.org /download. cgi 
  72   For Maven  install se e: https:/ /maven.apa che.org/in stall.html  
  73   **Be sure  to downloa d the bin. zip**
  74   For help s ee this ht tps://www. mkyong.com /maven/how -to-instal l-maven-in -windows/ 
  75   For NPM se e : https: //www.npmj s.com/get- npm 
  76   Download t he “Recomm ended For  Most Users ” version.
  77   Test that  you have i nstalled m aven and n pm success fully but  seeing if  your comma ndline rec ognizes mv n and npm.
  78   Building t he Applica tion
  79   Open 1 com mand promp t window.
  80   In the com mand promp t, CD to m ha-web/ (t he top lev el directo ry. You sh ould see a  pom.xml i n this dir ectory)
  81   Run mvn in stall -Pbu ildAll -Dm aven.skipT ests and p ress enter .
  82   This may t ake a whil e ~10 minu tes.(this  command sh ould only  need to be  run when  you run th e app for  the first  time or wh en you add  a new npm  dependenc y)
  83   Once that  completes,  type mvn  spring-boo t:run and  press ente r. 
  84   This shoul d start th e server.  If you hav e troubles , you may  need to ru n mvn clea n install  -PbuildAll  -Dmaven.  skipTests   then try  running sp ring-boot  again
  85   Once the a pache serv er is up a nd running , point yo ur browser  to https: //localhos t:8443/hom
  86   This shoul d prompt y ou for you r PIV cred entials an d if valid , allow yo u enter th e site.
  87   If it does  NOT promp t you for  your PIV a nd you can not see th e site, pl ease impor t your PIV  cert into  the brows er you are  using.
  88   IE: https: //serverfa ult.com/qu estions/35 9090/how-c an-i-insta ll-a-ca-ro ot-certifi cate-on-ie -9-windows -7 
  89   Chrome: ht tps://supp ort.global sign.com/c ustomer/po rtal/artic les/121154 1-install- client-dig ital-certi ficate---w indows-usi ng-chrome 
  90   You should  see a cer tificate e rror warni ng in your  browser.  That’s fin e because  you have a  self-sign ed certifi cate for d evelopment  purposes.  This caus es a red l ine or bac kground to  appear in  your addr ess bar wh ich is nor mal in loc al environ ments.Clic k “yes con tinue to t he site”NO TE: IE wil l prompt y ou twice f or the PIV  on a new  session be cause our  dev ssl ce rt is self -signed.
  91   See to the  developme nt section  (section  6) for det ails on ho w to see y ou code ch anges take  affect.
  92   5. Debuggi ng (Option al)
  93   You can se t up a deb ugger if y ou’d like.  This debu gger is on ly effecti ve for Jav a code. To  do so, se e this lin k https:// dzone.com/ articles/h ow-debug-r emote-java -applicat  for Eclips e debugger  setup. An d link the  port to b e 5005.
  94   Once that  is setup,  uncomment  the code s hown below  (in pom.x ml) and st art your s erver.
  95  
  96   Then start  your debu gger that  you set up  in step 1 . If you c annot acce ss MHA Web  after sta rting your  server it  is becaus e you need  to start  your debug ger for th e app to f inish star ting. When  you’re do ne using t he debugge r, simply  re-comment  the code  above so y ou don’t n eed the de bugger any more to se e MHA Web  running.
  97   6. Active  Developmen t
  98   Changes (M VN)
  99   CLI: If yo u make cha nges to th e applicat ion, stop  the server  by pressi ng ctrl+c  in the mvn  server te rminal you  ran that  spring-boo t command.  Then simp ly run mvn  compile - PbuildJS - Dmaven.tes t.skip=tru e followed  by mvn sp ring-boot: run again  to see the  Java chan ges reflec ted.
  100   Speeding u p the Dev  Process
  101   To avoid h aving to r un both co mmands, un comment th e webpack  section in  pom.xml l ike shown  below (at  this time  in this sc reenshot i t is lines  175-187):
  102  
  103   Uncommenti ng the sec tion shown  above wil l allow yo u to run m vn spring- boot:run t o package  your proje ct and sta rt the ser ver. Most  developers  do this o nce their  project is  set up an d running.
  104   DO NOT DEL IVER THIS  UNCOMMNETE D CHANGE T O THE STRE AM. It is  only for d evelopment .
  105  
  106   If you get  errors wh en startin g Spring b ecause som ething is  already ru nning on t he port(po rt 8443),  you may ne ed to open  up the ta sk manager  and kill  javaw.exe  processes  for spring .
  107   Spring run s on 8443  when in ht tps (which  is enable d by defau lt in MHA  Web)
  108  
  109   Preparing  the Applic ation for  Production
  110   The projec t leverage s the powe r of Maven  to ready  the projec t of produ ction. We  have many  different  profiles i n the pom. xml as wel l as a sep arate pack age.json o n the top  level for  this reaso n. The pac kage.json  inside the  React por tion diffe rs from th at in the  top level  because on ce package d and read y for prod uction, no de_modules / doesn’t  matter.
  111   We need to  test the  applicatio n in singl e-server m ode before  we packag e it. This  mode will  get us a  look at ho w the JS w ill respon d all bund led up.
  112   Testing th e standalo ne applica tion (Sing le server  MHA Web)
  113   It is enco uraged to  run throug h this sec tion befor e the pack aging sect ion when t esting bef ore a prod uction dep loyment.
  114   cd to mha- web/
  115   Run mvn in stall -Pbu ildAll -Dm aven.skipt Tests and  wait for t hat to com plete (5 m inutes or  so on slow er systems ). This in stalls nod e dependen cies at th e top leve l and pack ages the e ntire Reac t portion  into one J S file (vi a webpack) . If you g et errors  here and n ot when ru nning the  app, its l ikely due  to webpack  not happy  with your  java synt ax or a ne w file ext ension it  has not se en before.  You will  need to up date the w epack.conf ig.js in o rder to co ntinue pac kaging.
  116   Then run m vn spring- boot:run a nd open yo ur browser  to https: //localhos t:8443/mha  
  117   ***At this  level the re is no n eed to run  the Node  server***
  118   Verify the  app runs  correctly.
  119   Packaging  the Applic ation to b e Delivere d
  120   NOTE: Plea se see the  Packaging  for Produ ction doc  for furthe r instruct ions
  121   Open the c ommandline  and navig ate to the  mha-web/  directory.
  122   Run mvn pa ckage -Dma ven.skipTe sts to pac kage the e ntire proj ect into a  jar file.  It will a ppear in t arget/ dir  as mha-we b-X.X.X-SN APSHOT.jar
  123   From here,  you can h and the pr oject off  to whomeve r (prefera bly via AM RDEC). And  they can  launch it  using the  steps belo w. All the y need is  Java insta lled as a  path varia ble to run  the jar.
  124   Running th e JAR
  125   Open the c ommandline  and navig ate to whe rever the  jar file f rom the ab ove sectio n is.
  126   From here  run java - jar [NAME_ OF_JAR].ja r and let  it start u p. You wil l see text  stating “ Started Se rver” when  it has fu lly booted .
  127   Point your  browser t o https:// localhost: 8443/home  and the ap plication  should wor k as expec ted.
  128   NOTE: