I try to automate an old product build. It’s based on IBM RAD 9.7 and WebSphere 9.
I created a build.xml Ant file containing this:
[...]
<target name="importAndBuildEverything" depends="init" >
<disableIndexer name="jsp" />
<disableIndexer name="links" />
<createWSRuntime targetId="was.v9.base" typeId="com.ibm.ws.ast.st.runtime.v90" javaVersion="8.0" failOnError="false" />
<projectImport ... />
<createWSServer targetId="was90server" typeId="com.ibm.ws.ast.st.v9.server.base" runtimeId="was.v9.base">
</createWSServer>
<startWSServer serverId="was90server" />
[...]
But it fails on <startWSServer>
task:
[...]
[startWSServer] Synchrones Starten der Serverinstanz 'WebSphere Application Server traditional V9.0 @ localhost'. (Beginn)
[createWSServer] ... Hintergrundtask: createWSServer (Fertig)
[createWSServer] ... Hintergrundtask: createWSServer (Fertig)
[startWSServer] ... Hintergrundtask: WebSphere Application Server traditional V9.0 @ localhost wird gestartet: Startstellvertreter wird vorbereitet... (Beginn)
[startWSServer] ... Hintergrundtaskstatus: Überprüfung vor Startvorgang wird ausgeführt...
[startWSServer] ... Hintergrundtaskstatus: Liste der vorausgesetzten Projekte wird gebuildet
[startWSServer] ... Hintergrundtaskstatus: Abschließende Startprüfung wird ausgeführt...
[startWSServer] ... Hintergrundtaskstatus: Quellenlocator wird initialisiert...
[startWSServer] ... Hintergrundtaskstatus: Erweiterung wird gestartet...
[startWSServer] ... Hintergrundtask: WebSphere Application Server traditional V9.0 @ localhost wird gestartet: Startstellvertreter wird vorbereitet... (Fertig)
[startWSServer] Profilname ist ungültig. Geben Sie einen Profilnamen an, der auf dem Server vorhanden ist.
[startWSServer] Synchrones Starten der Serverinstanz 'WebSphere Application Server traditional V9.0 @ localhost'. (Fertig)
BUILD FAILED
XXXbuild.xml:95: Profilname ist ungültig. Geben Sie einen Profilnamen an, der auf dem Server vorhanden ist.
The error message in english is:
Profile name is invalid. Specify a profile name that exists on the server.
I cannot find any documentation about these Ant tasks. How to set a non-empty profile name so it doesn’t fail anymore?
I solved this by opening RAD IDE, going to the Servers tab and deleting the servers. Then Ant created a new server which worked.
Also I’ve found the docs about these Ant tasks: https://www.ibm.com/docs/en/radfws/9.7?topic=applications-ant-tasks-workbench-operations