Wiki source code of Maven Hello WOrld
Last modified by Lachlan Deck on 2008/12/08 16:15
Show last authors
author | version | line-number | content |
---|---|---|---|
1 | The following guide is aimed at getting you up and running with as minimal fuss as possible. | ||
2 | |||
3 | === Requirements === | ||
4 | |||
5 | You'll need the following software installed prior to following this tutorial. | ||
6 | |||
7 | * Install Maven 2 | ||
8 | ** To install maven other than on mac, see [[http:~~/~~/maven.apache.org/download.html>>url:http://maven.apache.org/download.html||shape="rect"]] (scrolling down also for installation instructions) | ||
9 | ** To install maven on a mac: | ||
10 | install macports [[http:~~/~~/www.macports.org/install.php>>url:http://www.macports.org/install.php||shape="rect"]], then on the terminal | ||
11 | |||
12 | {{noformat}} | ||
13 | sudo port install maven2 | ||
14 | {{/noformat}} | ||
15 | |||
16 | {{info title="Future upgrades"}} | ||
17 | In future, to keep this up to date: | ||
18 | |||
19 | {{noformat}} | ||
20 | sudo port upgrade maven2 | ||
21 | {{/noformat}} | ||
22 | {{/info}} | ||
23 | |||
24 | * Maven Settings | ||
25 | |||
26 | TODO | ||
27 | |||
28 | === Step 1 - Importing WebObjects libraries === | ||
29 | |||
30 | Download and [[install>>url:https://connect.apple.com||shape="rect"]] the latest WebObjects frameworks from Apple (included with Xcode Developer Tools). Then import the WebObjects jars into your repository by executing the following from the terminal: | ||
31 | |||
32 | {{noformat}} | ||
33 | mvn wobootstrap:install | ||
34 | {{/noformat}} | ||
35 | |||
36 | {{info title="~"Additional reading~""}} | ||
37 | For further information about the available options and goals of the wobootstrap plugin see [[here>>url:http://wiki.objectstyle.org/confluence/display/WOL/maven-wobootstrap-plugin||shape="rect"]]. | ||
38 | {{/info}} | ||
39 | |||
40 | The output from running the above command will look something like this: | ||
41 | |||
42 | {{noformat}} | ||
43 | |||
44 | ldecks-macbook-pro:tutorials ldeck$ mvn wobootstrap:install | ||
45 | [INFO] Scanning for projects... | ||
46 | [INFO] Reactor build order: | ||
47 | [INFO] Unnamed - com.mycompany.app:app:pom:1.0-SNAPSHOT | ||
48 | [INFO] getting-started | ||
49 | [INFO] my-webapp Maven Webapp | ||
50 | [INFO] Unnamed - com.mycompany.app:modules:pom:1.0-SNAPSHOT | ||
51 | [INFO] starting-again | ||
52 | [INFO] Searching repository for plugin with prefix: 'wobootstrap'. | ||
53 | [INFO] org.objectstyle.woproject.maven2: checking for updates from mdimension.releases | ||
54 | [INFO] org.objectstyle.woproject.maven2: checking for updates from central | ||
55 | [INFO] org.apache.maven.plugins: checking for updates from mdimension.releases | ||
56 | [INFO] org.codehaus.mojo: checking for updates from mdimension.releases | ||
57 | [INFO] artifact org.objectstyle.woproject.maven2:maven-wobootstrap-plugin: checking for updates from mdimension.releases | ||
58 | Downloading: http://webobjects.mdimension.com/maven2/releases/org/objectstyle/woproject/maven2/maven-wobootstrap-plugin/2.0.16/maven-wobootstrap-plugin-2.0.16.pom | ||
59 | 2K downloaded | ||
60 | Downloading: http://webobjects.mdimension.com/maven2/releases/org/objectstyle/woproject/maven2/maven-wobootstrap-plugin/2.0.16/maven-wobootstrap-plugin-2.0.16.jar | ||
61 | 20K downloaded | ||
62 | [INFO] ------------------------------------------------------------------------ | ||
63 | [INFO] Building Unnamed - com.mycompany.app:app:pom:1.0-SNAPSHOT | ||
64 | [INFO] task-segment: [wobootstrap:install] (aggregator-style) | ||
65 | [INFO] ------------------------------------------------------------------------ | ||
66 | [INFO] [wobootstrap:install] | ||
67 | [INFO] Installing /Library/WebObjects/lib/JavaBusinessLogic.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaBusinessLogic/5.4.3/JavaBusinessLogic-5.4.3.jar | ||
68 | [INFO] Installing /Library/WebObjects/lib/JavaDirectToWeb.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaDirectToWeb/5.4.3/JavaDirectToWeb-5.4.3.jar | ||
69 | [INFO] Installing /Library/WebObjects/lib/JavaDTWGeneration.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaDTWGeneration/5.4.3/JavaDTWGeneration-5.4.3.jar | ||
70 | [INFO] Installing /Library/WebObjects/lib/JavaEOAccess.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOAccess/5.4.3/JavaEOAccess-5.4.3.jar | ||
71 | [INFO] Installing /Library/WebObjects/lib/JavaEOApplication.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOApplication/5.4.3/JavaEOApplication-5.4.3.jar | ||
72 | [INFO] Installing /Library/WebObjects/lib/JavaEOControl.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOControl/5.4.3/JavaEOControl-5.4.3.jar | ||
73 | [INFO] Installing /Library/WebObjects/lib/JavaEODistribution.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEODistribution/5.4.3/JavaEODistribution-5.4.3.jar | ||
74 | [INFO] Installing /Library/WebObjects/lib/JavaEOGeneration.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOGeneration/5.4.3/JavaEOGeneration-5.4.3.jar | ||
75 | [INFO] Installing /Library/WebObjects/lib/JavaEOInterface.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOInterface/5.4.3/JavaEOInterface-5.4.3.jar | ||
76 | [INFO] Installing /Library/WebObjects/lib/JavaEOInterfaceCocoa.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOInterfaceCocoa/5.4.3/JavaEOInterfaceCocoa-5.4.3.jar | ||
77 | [INFO] Installing /Library/WebObjects/lib/JavaEOInterfaceSwing.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOInterfaceSwing/5.4.3/JavaEOInterfaceSwing-5.4.3.jar | ||
78 | [INFO] Installing /Library/WebObjects/lib/JavaEOProject.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOProject/5.4.3/JavaEOProject-5.4.3.jar | ||
79 | [INFO] Installing /Library/WebObjects/lib/JavaEORuleSystem.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEORuleSystem/5.4.3/JavaEORuleSystem-5.4.3.jar | ||
80 | [INFO] Installing /Library/WebObjects/lib/JavaEOTool.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaEOTool/5.4.3/JavaEOTool-5.4.3.jar | ||
81 | [INFO] Installing /Library/WebObjects/lib/JavaFoundation.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaFoundation/5.4.3/JavaFoundation-5.4.3.jar | ||
82 | [INFO] Installing /Library/WebObjects/lib/JavaJDBCAdaptor.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaJDBCAdaptor/5.4.3/JavaJDBCAdaptor-5.4.3.jar | ||
83 | [INFO] Installing /Library/WebObjects/lib/JavaJNDIAdaptor.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaJNDIAdaptor/5.4.3/JavaJNDIAdaptor-5.4.3.jar | ||
84 | [INFO] Installing /Library/WebObjects/lib/JavaMonitorSupport.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaMonitorSupport/5.4.3/JavaMonitorSupport-5.4.3.jar | ||
85 | [INFO] Installing /Library/WebObjects/lib/JavaRealEstate.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaRealEstate/5.4.3/JavaRealEstate-5.4.3.jar | ||
86 | [INFO] Installing /Library/WebObjects/lib/JavaWebObjects.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaWebObjects/5.4.3/JavaWebObjects-5.4.3.jar | ||
87 | [INFO] Installing /Library/WebObjects/lib/JavaWebServicesClient.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaWebServicesClient/5.4.3/JavaWebServicesClient-5.4.3.jar | ||
88 | [INFO] Installing /Library/WebObjects/lib/JavaWebServicesGeneration.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaWebServicesGeneration/5.4.3/JavaWebServicesGeneration-5.4.3.jar | ||
89 | [INFO] Installing /Library/WebObjects/lib/JavaWebServicesSupport.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaWebServicesSupport/5.4.3/JavaWebServicesSupport-5.4.3.jar | ||
90 | [INFO] Installing /Library/WebObjects/lib/JavaWOExtensions.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaWOExtensions/5.4.3/JavaWOExtensions-5.4.3.jar | ||
91 | [INFO] Installing /Library/WebObjects/lib/JavaWOJSPServlet.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaWOJSPServlet/5.4.3/JavaWOJSPServlet-5.4.3.jar | ||
92 | [INFO] Installing /Library/WebObjects/lib/JavaXML.jar to /Users/ldeck/.m2/repository/com/webobjects/JavaXML/5.4.3/JavaXML-5.4.3.jar | ||
93 | [INFO] Installing /Library/WebObjects/lib/PetStoreWOModel.jar to /Users/ldeck/.m2/repository/com/webobjects/PetStoreWOModel/5.4.3/PetStoreWOModel-5.4.3.jar | ||
94 | [INFO] Installing /Library/WebObjects/lib/WOComponentElements.jar to /Users/ldeck/.m2/repository/com/webobjects/WOComponentElements/5.4.3/WOComponentElements-5.4.3.jar | ||
95 | [INFO] Installing /Library/WebObjects/lib/WOComponentExamples.jar to /Users/ldeck/.m2/repository/com/webobjects/WOComponentExamples/5.4.3/WOComponentExamples-5.4.3.jar | ||
96 | [INFO] Installing /Library/WebObjects/lib/WOExamplesHarness.jar to /Users/ldeck/.m2/repository/com/webobjects/WOExamplesHarness/5.4.3/WOExamplesHarness-5.4.3.jar | ||
97 | [INFO] Installing /Library/WebObjects/lib/WOSessionStoreExample.jar to /Users/ldeck/.m2/repository/com/webobjects/WOSessionStoreExample/5.4.3/WOSessionStoreExample-5.4.3.jar | ||
98 | [INFO] ------------------------------------------------------------------------ | ||
99 | [INFO] BUILD SUCCESSFUL | ||
100 | [INFO] ------------------------------------------------------------------------ | ||
101 | [INFO] Total time: 10 seconds | ||
102 | [INFO] Finished at: Tue Dec 09 08:02:40 EST 2008 | ||
103 | [INFO] Final Memory: 3M/6M | ||
104 | [INFO] ------------------------------------------------------------------------ | ||
105 | ldecks-macbook-pro:tutorials ldeck$ | ||
106 | |||
107 | {{/noformat}} | ||
108 | |||
109 | === Step 2 - Creating a WebObjects Application Project === | ||
110 | |||
111 | TODO | ||
112 | |||
113 | === Step 3 - Run The Application === | ||
114 | |||
115 | {{noformat}} | ||
116 | |||
117 | mvn clean jetty:run-war | ||
118 | |||
119 | {{/noformat}} |