summaryrefslogtreecommitdiffstats
path: root/winery/org.eclipse.winery.generators.ia/src/main/resources/template/project/README.txt
blob: bce220db9f7a301761e92008b04dcd6ca985c73a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
###########################################################################
GENERATED IMPLEMENTATION ARTIFACT SKELETON FOR IA_CLASS_NAME

Interface Name: IA_CLASS_NAME
Namespace: IA_NAMESPACE
Java Package: IA_PACKAGE
URL: IA_ARTIFACT_TEMPLATE_UPLOAD_URL../
###########################################################################

##### Preconditions
To develop and build this Implementation Artifact you need Maven and Eclipse.
+ How to install maven is described at the end of this file
+ If you use an Eclipse workspace for the first time with a maven project you've to run this command before starting eclipse:
	mvn -Declipse.workspace="<your_workspace_location>" eclipse:configure-workspace
	- When using Windows: Make sure you replace '\' (backslashes) with '/' ('slashes')
	- It doesn't hurt to run it multiple times
	- This command must not be executed in a particular folder
	
##### Preparations
+ Unzip the archive generated by Winery into a location of your choice.
+ Note: All following maven commands are executed on a shell in the root folder of the Implementation Artifact.

##### Create eclipse project
- Run: mvn eclipse:eclipse
- Open Eclipse
- 'File' -> 'Import' -> 'Existing Project into Workspace' -> click 'Next'
- Click 'Browse' and select folder where you unzipped the generated Implementation Artifact
- Select the project from the list and click 'Finish'

##### Test your Implementation Artifact
- Run: mvn clean package tomcat7:run-war
	(more information: http://tomcat.apache.org/maven-plugin-trunk/tomcat7-maven-plugin/plugin-info.html)
- Open this page to see the list of available services: http://localhost:9090/services/
- This page also links the WSDL
- With the WSDL your're able to test your IA using SOAPui or other tools.

##### Upload your Implementation Artifact
You have to options to do this:

### 1) Automatically (to the Winery instance this IA project was generated with)
- Run: mvn deploy
- The WAR is directly uploaded into the correct ArtifactTemplate. Previous versions are overwritten.

### 2) Manually
- Run: mvn clean package
- Locate the WAR file in the /target folder
- Open Winery in your browser, locate the NodeType and then click through to the Implementation of the respective Interface, its Implementation Artifacts and lastly to the ArtifactTemplate representing this IA.
- Upload the WAR file by clicking on the "Attach file..." button


##### Install Maven
- Download latest release of Maven: http://maven.apache.org/download.cgi (Binary zip)
- Unzip into directory of your choice
- Set environment variables (in system environment variables, not the ones for the user account):
	+ Check that the variables JAVA_HOME and JRE_HOME are set. If not create them and enter the path to your JDK, e.g., C:\Program Files (x86)\Java\jdk1.6.0_21
	+ Create the following environment variables
		M2_HOME = C:\Path\where\your\maven\was\unzipped\to  (no backslash at the end)
		M2 = %M2_HOME%\bin
		MAVEN_OPTS = -Xms256m -Xmx512m
	+ Append ;%M2% to the 'Path' environment variable. Make sure to separate the new entry with a semicolon (;) from the last one.
- After that you have to open a new command line windows (if you already opened one) to let the changes take effect.