JavaTypes attribute of autoType Ant Task

I have got two files Account.java and ContactInformation.java. I am trying to
create webservices for Account.java and this java file uses a non-build in data
type object ContactInformation.java.
After compiling the code i try and generate the serialization class, xsd, xml
and web-services xml using the ant task autotype. On running this i get the below
mentioned error
E:\bea\weblogic700\samples\server\src\examples\webservices\basic\account>E:\bea\weblogic700\server\bin\ant
-buildfile build1.xml
Buildfile: build1.xml
generate-typeinfo:
BUILD FAILED
E:\bea\weblogic700\samples\server\src\examples\webservices\basic\account\build1.xml:6:
The <autotype> task doesn't support the "javatypes" attribute.
Total time: 1 second
My entry in build1.xml is
<project name="buildWebservice" default="generate-typeinfo">
     <target name="generate-typeinfo">
          <autotype javaTypes="com.sun.sample.ws.account.ContactInformation"
                    targetNamespace="http://www.bea.com/webservices/basic/statelesSession"
                    packageName="com.sun.sample.ws.account"
                    destDir="." />
          </target>
</project>
Can someone point out how can this be corrected?
Regards,
Rahul.

Thanks Michael,
This is what i am trying to do.
I have Account.java as java class that is to be used as a web service backend
component for weblogic web service. All the attributes of this class are primitive
types. There is one data type that is a NON BUILT IN DATA TYPE. Now in such a
scenario i need some more files to create a web service. The extra files are the
serilization class, an XML Schema reprsenting the non built in data type, data
type mapping information in the web-services.xml. These requiremnts are defined
in Chapter 9 of the weblogic webservices pdf document.
One can create the file manually or automatically. The manual is lengthy and complex
so I am following the automatic procedure. The document also suggests automatic
procedure. For that one need to write a build.xml with the contents that I have
already posted. When I execute the same it gives me error that the attribute javaTypes
is not supported.
For ur ref i am attaching the Account.java, ContactInformation.java(This is the
non built in data type used by Account.java, the websevice build.xml and the autotype
auto_build.xml). They are in a zip file.(2KB)
I followed the below steps after setting the env using the file setWLSEnv.cmd.
Compiled the java files using javac -d . *.java.
Now run the autotype ant task using auto_build.xml to generate the serilaization
class and XML schema. Here I get the error posted in the earlier email to this
group.
Thanks in advance for ur help
Rahul
"Michael Wooten" <[email protected]> wrote:
>
Hi Rahul,
I think this is either an error in the e-docs, or the code to actually
add the
javaTypes attribute to the AutoTypeTask didn't make it into the release.
It sounds like you have already created the ContactInformation.class
(from the
ContactInformation.java file), so are you just trying to get something
else out
of the <autotype> Ant task? If you can tell me what you were looking
for, I might
be able to tell you how to get it.
Regards,
Mike Wooten
"Rahul Naithani" <[email protected]> wrote:
I have got two files Account.java and ContactInformation.java. I amtrying
to
create webservices for Account.java and this java file uses a non-build
in data
type object ContactInformation.java.
After compiling the code i try and generate the serialization class,
xsd, xml
and web-services xml using the ant task autotype. On running this iget
the below
mentioned error
E:\bea\weblogic700\samples\server\src\examples\webservices\basic\account>E:\bea\weblogic700\server\bin\ant
-buildfile build1.xml
Buildfile: build1.xml
generate-typeinfo:
BUILD FAILED
E:\bea\weblogic700\samples\server\src\examples\webservices\basic\account\build1.xml:6:
The <autotype> task doesn't support the "javatypes" attribute.
Total time: 1 second
My entry in build1.xml is
<project name="buildWebservice" default="generate-typeinfo">
     <target name="generate-typeinfo">
          <autotype javaTypes="com.sun.sample.ws.account.ContactInformation"
                    targetNamespace="http://www.bea.com/webservices/basic/statelesSession"
                    packageName="com.sun.sample.ws.account"
                    destDir="." />
          </target>
</project>
Can someone point out how can this be corrected?
Regards,
Rahul.
[testcode.zip]

Similar Messages

  • Autotype ant task and java source file having method which  returns hashmap

    Hi Friends,
    I am using autotype ant task to generate types.xml and supporting java classes.
    The task is defined as follows .
    <target name="std">
    <source2wsdd javaSource="HelloWorld.java"
    typesInfo="types.xml"
    ddFile="ddfiles/web-services.xml"
    serviceURI="/HelloWorldService"/>
    </target>
    In my java source i have method which is returning an HashMap. In this scenario I am getting error when i run the task. The error is as follows
    C:\test-ws\javaclass>ant auto
    Buildfile: build.xml
    auto:
    [autotype] Autotyping for javaTypes TestBean
    [autotype] weblogic.xml.schema.binding.BindingException: Invalid class received
    : interface java.util.Map loaded from file:/C:/bea/jdk142_05/jre/lib/rt.jar!/jav
    a/util/Map.class. All classes that will be serialized or deserialized must be n
    on-interface, non-abstract classes that provide a public default constructor
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.en
    sureValidClass(JavaInspector.java:1050)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.fi
    llDescriptor(JavaInspector.java:174)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.ge
    tDescriptor(JavaInspector.java:139)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.cr
    eateBeanProperty(JavaInspector.java:927)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.cr
    eateBeanProperty(JavaInspector.java:905)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.ad
    dPropertiesToScalar(JavaInspector.java:834)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.fi
    llDescriptor(JavaInspector.java:209)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.ge
    tDescriptor(JavaInspector.java:139)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.cr
    eateDescriptorForClass(JavaInspector.java:106)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.Compiler.compile
    (Compiler.java:106)
    [autotype] at weblogic.xml.schema.binding.internal.XSDTypeMappingBuilder.ma
    pClass(XSDTypeMappingBuilder.java:89)
    [autotype] at weblogic.xml.schema.binding.internal.XSDTypeMappingBuilder.ma
    pClass(XSDTypeMappingBuilder.java:102)
    [autotype] at weblogic.xml.schema.binding.internal.TypeMappingBuilderBase.a
    ddMapping(TypeMappingBuilderBase.java:180)
    [autotype] at weblogic.webservice.tools.build.internal.Java2SchemaImpl.doTy
    peMapping(Java2SchemaImpl.java:267)
    [autotype] at weblogic.webservice.tools.build.internal.Java2SchemaImpl.run(
    Java2SchemaImpl.java:167)
    [autotype] at weblogic.ant.taskdefs.webservices.javaschema.JavaSchema.doJav
    a2Schema(JavaSchema.java:302)
    [autotype] at weblogic.ant.taskdefs.webservices.javaschema.JavaSchema.execu
    te(JavaSchema.java:184)
    [autotype] at org.apache.tools.ant.Task.perform(Task.java:341)
    [autotype] at org.apache.tools.ant.Target.execute(Target.java:309)
    [autotype] at org.apache.tools.ant.Target.performTasks(Target.java:336)
    [autotype] at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
    [autotype] at org.apache.tools.ant.Project.executeTargets(Project.java:1255
    [autotype] at org.apache.tools.ant.Main.runBuild(Main.java:609)
    [autotype] at org.apache.tools.ant.Main.start(Main.java:196)
    [autotype] at org.apache.tools.ant.Main.main(Main.java:235)
    BUILD FAILED
    file:C:/test-ws/javaclass/build.xml:62: weblogic.webservice.tools.build.WSBuildE
    xception: Failed to do type mapping - with nested exception:
    [weblogic.xml.schema.binding.BindingException: Invalid class received: interface
    java.util.Map loaded from file:/C:/bea/jdk142_05/jre/lib/rt.jar!/java/util/Map.
    class.  All classes that will be serialized or deserialized must be non-interfac
    e, non-abstract classes that provide a public default constructor]
    Can any one provide the solution for this
    Thanks
    Anantha

    Hi Friends,
    I am using autotype ant task to generate types.xml and supporting java classes.
    The task is defined as follows .
    <target name="std">
    <source2wsdd javaSource="HelloWorld.java"
    typesInfo="types.xml"
    ddFile="ddfiles/web-services.xml"
    serviceURI="/HelloWorldService"/>
    </target>
    In my java source i have method which is returning an HashMap. In this scenario I am getting error when i run the task. The error is as follows
    C:\test-ws\javaclass>ant auto
    Buildfile: build.xml
    auto:
    [autotype] Autotyping for javaTypes TestBean
    [autotype] weblogic.xml.schema.binding.BindingException: Invalid class received
    : interface java.util.Map loaded from file:/C:/bea/jdk142_05/jre/lib/rt.jar!/jav
    a/util/Map.class. All classes that will be serialized or deserialized must be n
    on-interface, non-abstract classes that provide a public default constructor
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.en
    sureValidClass(JavaInspector.java:1050)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.fi
    llDescriptor(JavaInspector.java:174)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.ge
    tDescriptor(JavaInspector.java:139)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.cr
    eateBeanProperty(JavaInspector.java:927)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.cr
    eateBeanProperty(JavaInspector.java:905)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.ad
    dPropertiesToScalar(JavaInspector.java:834)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.fi
    llDescriptor(JavaInspector.java:209)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.ge
    tDescriptor(JavaInspector.java:139)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.JavaInspector.cr
    eateDescriptorForClass(JavaInspector.java:106)
    [autotype] at weblogic.xml.schema.binding.internal.codegen.Compiler.compile
    (Compiler.java:106)
    [autotype] at weblogic.xml.schema.binding.internal.XSDTypeMappingBuilder.ma
    pClass(XSDTypeMappingBuilder.java:89)
    [autotype] at weblogic.xml.schema.binding.internal.XSDTypeMappingBuilder.ma
    pClass(XSDTypeMappingBuilder.java:102)
    [autotype] at weblogic.xml.schema.binding.internal.TypeMappingBuilderBase.a
    ddMapping(TypeMappingBuilderBase.java:180)
    [autotype] at weblogic.webservice.tools.build.internal.Java2SchemaImpl.doTy
    peMapping(Java2SchemaImpl.java:267)
    [autotype] at weblogic.webservice.tools.build.internal.Java2SchemaImpl.run(
    Java2SchemaImpl.java:167)
    [autotype] at weblogic.ant.taskdefs.webservices.javaschema.JavaSchema.doJav
    a2Schema(JavaSchema.java:302)
    [autotype] at weblogic.ant.taskdefs.webservices.javaschema.JavaSchema.execu
    te(JavaSchema.java:184)
    [autotype] at org.apache.tools.ant.Task.perform(Task.java:341)
    [autotype] at org.apache.tools.ant.Target.execute(Target.java:309)
    [autotype] at org.apache.tools.ant.Target.performTasks(Target.java:336)
    [autotype] at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
    [autotype] at org.apache.tools.ant.Project.executeTargets(Project.java:1255
    [autotype] at org.apache.tools.ant.Main.runBuild(Main.java:609)
    [autotype] at org.apache.tools.ant.Main.start(Main.java:196)
    [autotype] at org.apache.tools.ant.Main.main(Main.java:235)
    BUILD FAILED
    file:C:/test-ws/javaclass/build.xml:62: weblogic.webservice.tools.build.WSBuildE
    xception: Failed to do type mapping - with nested exception:
    [weblogic.xml.schema.binding.BindingException: Invalid class received: interface
    java.util.Map loaded from file:/C:/bea/jdk142_05/jre/lib/rt.jar!/java/util/Map.
    class.  All classes that will be serialized or deserialized must be non-interfac
    e, non-abstract classes that provide a public default constructor]
    Can any one provide the solution for this
    Thanks
    Anantha

  • Wlappc ANT task "runtimeFlags" attribute doesn't take effect

    I am intermittently counter "java.lang.OutOfMemoryError" error while I am running wlappc ANT task to compile jsp pages. I have lots of jsp files (about 500). According to weblogic's document, I set runtimeFlags="-J-ms512m -J-mx1024m". So my ant task looks like this:
              <wlappc source="${websrc}" output="${output}" runtimeFlags="-J-ms1024m -J-mx1024m">
              </wlappc>
              But it doesn't work. It still complains out of memory error. I tried various approach including "-J-Xms1024m -J-Xmx1024m". But not helpful at all.
              So I gave up and ended up using weblogic.appc class to build my jsp pages. So I have fully control of jvm options. I set up -Xms1024m -Xmx1024m as JVM parameters and works well.
              It looks to me that wlappc ANT task ignore runtimeFlags at all. It doesn't take any effect.
              Is it a known bug? anyone succeeded solving OutOfMemoryError by setting runtimeFlags attribute of wlappc ANT task?

    I was having the same issue.
              Try using the maxmemory argument for the standard java ant task and calling weblogic.appc:
              <java classname="weblogic.appc" fork="yes" failonerror="true" maxmemory="256m">
              <classpath>
              <fileset dir="${weblogic.home}/server/lib" includes="weblogic.jar,webservices.jar" />
              </classpath>
              <arg value="${ear.dir}" />
              <arg value="-verbose" />
              </java>

  • Class generated by genInterface ant task does not compile

    I am trying to build a web service from existing wsdl using genInterface and topDownAssemble ant tasks.
    The wsdl contains following type definition. Java class generated from this type (see below) does not compile. The problem is that there are two class members named
    'value'. Is this an issue with Web Services Assembly tool or there is some way to get
    around it?
    <s:simpleType name="quantityType">
    <s:restriction base="s:string">
    <s:enumeration value="summation"/>
    <s:enumeration value="demand"/>
    <s:enumeration value="value"/>
    <s:enumeration value="consumption"/>
    </s:restriction>
    </s:simpleType>
    // Version = Oracle WebServices (10.1.3.3.0, build 070610.1800.23513)
    public class QuantityType implements java.io.Serializable {
    private java.lang.String value;
    private static final String _summationString = "summation";
    private static final String _demandString = "demand";
    private static final String _valueString = "value";
    private static final String _consumptionString = "consumption";
    public static final java.lang.String summation = new java.lang.String(summationString);
    public static final java.lang.String demand = new java.lang.String(demandString);
    public static final java.lang.String value = new java.lang.String(valueString);
    public static final java.lang.String consumption = new java.lang.String(consumptionString);
    public static final QuantityType summation = new QuantityType(_summation);
    public static final QuantityType demand = new QuantityType(_demand);
    public static final QuantityType value = new QuantityType(_value);
    public static final QuantityType consumption = new QuantityType(_consumption);
    Andrei

    Pls set debug attribute of JWSC ant task to true or on, e.g.
    <jwsc srcdir="." destdir="${output.dir}" debug="on" keepGenerated="true">
              </jwsc>

  • Line numbers in JWS classfile generated by jwsc Ant task

    Does anyone know how to get the jswc ant task to add line number attributes to JWS class file that it generates. When I try to use Eclipse to set a breakpoint in the service code I get a pop up that states
    +"Unable to install breakpoint in.....due to missing line number attributes. Modify compiler option to generate line number attributes"+
    I looked at the documentation for jswc and I dont see any options that can be passed to the java compiler.
    Karl

    Pls set debug attribute of JWSC ant task to true or on, e.g.
    <jwsc srcdir="." destdir="${output.dir}" debug="on" keepGenerated="true">
              </jwsc>

  • Ant Task Doesn't work : Generating autotypes using Schema

    I have XML schema which import other schemas.Now when i try to generate
    autotype for this schema, it gives error
    "Unable to resolve reference to specified path".
    Reason being the URL specified as target namespace is not valid.
    Does autotype refers to URL for import the refererence .XSD.
    I have the required XSD in my path.
    Can autotype refer to local directory path instead of url.

    Hi Bruce
    I compared your simple.zip with my scenario and it looks
    like problem is with <include> clause.
    I have modified your simple example and i was able to reproduce the error.
    Please refer to attach file.
    Also let me know if i am doing anything wrong.
    I hope this is not limitation of Welogic ant task...this is very urgent
    Thanks
    Bruce Stephens <[email protected]> wrote:
    Hi,
    I posted a very simple schema import example recently [1] you might want
    take a look.
    Could you post a reproducer of the problem you are experiencing?
    Thanks,
    Bruce
    [1]
    http://newsgroups.bea.com/cgi-bin/dnewsweb?cmd=article&group=weblogic.developer.interest.webservices&item=4642
    askbea wrote:
    I have XML schema which import other schemas.Now when i try to generate
    autotype for this schema, it gives error
    "Unable to resolve reference to specified path".
    Reason being the URL specified as target namespace is not valid.
    Does autotype refers to URL for import the refererence .XSD.
    I have the required XSD in my path.
    Can autotype refer to local directory path instead of url.
    [simple.zip]

  • How to generate not nillable complexType with ant task autotype

    Hi all,
    The file types.xml created by ant task autotype contains, among others, all element definitions of my java classes.
    For testing purposes I have a simple class that holds (wraps) only a string. In the types.xml it is shown as followed:
    <xsd:complexType name="StringHolder">
    <xsd:sequence>
    <xsd:element name="mystring"
    type="xsd:string"
    nillable="true"
    minOccurs="1"
    maxOccurs="1">
    </xsd:element>
    </xsd:sequence>
    </xsd:complexType>
    Somehow nullabel is always true, but I want to be false. Does anyone knows how?

    Hello digitxm,
    Since the hardware you have is the limiting factor, with the NI 6008 you can perform a software timed pwm output if timing in your application is not critical (your cycle time is in the seconds range and you do not mind some milliseconds of delay) you can use a digital output with software timing control for your PWM generation. Also, see how to use AO channel(s) to control the voltage level of a square wave output (period of the square wave can be varied). Otherwise, this can be accomplished by using the following example on generating a digital waveform using non-regeneration in order to update frequency and duty cycle on-the-fly using National Instruments M Series or X series DAQ devices.
    Best regards,
    Ali M
    Applications Engineer
    National Instruments
    www.ni.com/support

  • Weblogic ant task wsdl2service - truncating soapaction

    Hi all,
    I'm using the weblogic ant utility "wsdl2service" to deploy my webservice. Here is the ant snippet of my script.
    <taskdef name="wsdl2service" classname="weblogic.ant.taskdefs.webservices.wsdl2service.WSDL2Service"/>
    <wsdl2service wsdl="${dev.dir}/wsdl/${myService}.wsdl" destDir="${build.dir}/wsjar"
         typeMappingFile="AutoType/in_types.xml" packageName="${in_class_packagename}" generateImpl="True">
    <classpath>
         <pathelement path="${lib3}"/>
         <pathelement path="${lib1}"/>
    <pathelement path="${lib2}"/>
         <pathelement path="AutoType/inventoryNotificationType.jar"/>
    </classpath>     
    </wsdl2service>
    It compiles properly and prepares the build. But after deploying the build, when i try to browse the wsdl thru internet browser, it is not populating the SOAPACTION attribute of SOAP:OPERATION element of my wsdl. So in the internetbroser the SOAPAction attribute is having empty value though it is present in the wsdl.
    Can some one tell why the WSDL2SERVICE tool is not populating the SOAPACTION attribute?

    Hi Jay,
    Thanks for your help.
    I am using weblogic 8.1 and Apache Ant version 1.5.3
    Jay I do not have client source code. When I am generating client using clientgen ant task, it gives me only a .jar file with .class files in it.
    I added .jar file generated by clientgen task in 'run' but now I am getting another error.
    <target name="run">
    <java classname="clientpkg.MathFace_Stub" fork="true" >
    <arg value="http://localhost:${port}/WebServices/MyFirstService?WSDL"/>
    <arg value="10"/>
    <arg value="17"/>
    <classpath>
    <pathelement location="staging"/>
    <pathelement location="${wl.home}/server/lib/weblogic.jar"/>
    <pathelement location="staging/MyFirstService_client.jar"/>
    <pathelement location="/ffdt01/resmgt/kul/ws"/>
    <pathelement path="staging"/>
    </classpath>
    </java>
    </target>
    --- This is giving below error:
    cu dmwls(162)$ ant run
    Buildfile: build.xml
    run:
    +[java] Exception in thread "main" j*ava.lang.NoSuchMethodError:* main+
    +[java] Java Result: 1+
    BUILD SUCCESSFUL
    Total time: 1 second
    Edited by: [email protected] on Feb 19, 2010 1:53 PM

  • Built-in wlst ant task does not work in weblogic 10.3.1

    Hi,
    We have an installer script that deploys an ear file to a weblogic managed server. The script also invokes the build-tin wlst ant task to bounce the managed server. However, in version 10.3.1 the wlst task seems to be broken. I get this error:
    [echo] [wlst] sys-package-mgr: can't create package cache dir, '/u00/webadmin/product/10.3.1/WLS/wlserver_10.3/server/lib/weblogic.jar/./java
    tmp/wlstTemp/packages'
    [echo] [wlst] java.io.IOException: No such file or directory
    [echo] [wlst] at java.io.UnixFileSystem.createFileExclusively(Native Method)
    [echo] [wlst] at java.io.File.checkAndCreate(File.java:1704)
    [echo] [wlst] at java.io.File.createTempFile(File.java:1792)
    [echo] [wlst] at java.io.File.createTempFile(File.java:1828)
    [echo] [wlst] at com.bea.plateng.domain.script.jython.WLST_offline.getWLSTOfflineInitFilePath(WLST_offline.java:240)
    [echo] [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [echo] [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    [echo] [wlst] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    [echo] [wlst] at java.lang.reflect.Method.invoke(Method.java:597)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTUtil.getOfflineWLSTScriptPath(WLSTUtil.java:63)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTUtil.setupOffline(WLSTUtil.java:214)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTInterpreter.<init>(WLSTInterpreter.java:133)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTInterpreter.<init>(WLSTInterpreter.java:75)
    [echo] [wlst] at weblogic.ant.taskdefs.management.WLSTTask.execute(WLSTTask.java:103)
    [echo] [wlst] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
    Obviously that is not a valid directory...so I am wondering what it is trying to do, and why. The wlst task worked perfectly in 10.3.0. No changes were made when attempting to run the script against 10.3.0 and 10.3.1, which tells me that something is different with the 10.3.1 setup. Here is the ant code I am running:
    <target name="init-taskdefs">
    <taskdef resource="net/sf/antcontrib/antcontrib.properties">
    <classpath>
    <pathelement location="ant-ext/ant-contrib.jar" />
    </classpath>
    </taskdef>
    <taskdef name="wldeploy" classname="weblogic.ant.taskdefs.management.WLDeploy" />
    <taskdef name="wlst" classname="weblogic.ant.taskdefs.management.WLSTTask" />
    </target>
    <macrodef name="wlShutdownServer">
    <attribute name="adminUser" default="${deploy.admin.username}" />
    <attribute name="adminPassword" default="${deploy.admin.password}" />
    <attribute name="adminUrl" default="${deploy.admin.url}" />
    <attribute name="serverTarget" />
    <sequential>
    <trycatch property="server.error">
    <try>
    <wlst failonerror="true"
    arguments="@{adminUser} @{adminPassword} @{adminUrl} @{serverTarget}">
    <script>
    adminUser=sys.argv[0]
    adminPassword=sys.argv[1]
    adminUrl=sys.argv[2]
    serverTarget=sys.argv[3]
    connect(adminUser,adminPassword,adminUrl)
    target=getMBean("/Servers/"+serverTarget)
    if target == None:
    target=getMBean("/Clusters/"+serverTarget)
    type="Cluster"
    else:
    type="Server"
    print 'Shutting down '+serverTarget+'...'
    shutdown(serverTarget,type,'true',15,force='true')
    print serverTarget+' was shut down successfully.'
    </script>
    </wlst>
    <!-- setDomainEnv.sh must have been called to set DOMAIN_HOME. Remove all leftover .lok files to allow server
    to start back up again. -->
    <echo message="Deleting any lok files that have not been removed..." />
    <delete failonerror="false">
    <fileset dir="${env.DOMAIN_HOME}/servers/@{serverTarget}" includes="**/*.lok"/>
    </delete>
    </try>
    <catch>
    <fail message="@{serverTarget} shutdown failed. ${server.error}" />
    </catch>
    <finally/>
    </trycatch>
    </sequential>
    </macrodef>
    Any help would be appreciated. Thanks!

    Well, it looks like passing something like "-Djava.io.tmpdir=/var/tmp/javatmp/`date +%Y%m%d`" to ant did the trick. I had to make sure that directory existed first, otherwise it threw a java ioexception.
    I still don't understand what changes between 10.3.0 and 10.3.1 to necessitate this change.

  • Error in writing an Ant task for creating a new connection pool.

    I have written the following ant task to create a new connection pool in weblogic 10.3.
    <target name="pool.dev">
         <wlconfig url="http://localhost:7001/" username="weblogic" password="weblogic">
         <query domain="C:/weblogic/rtg-L0" name="myserver"/>
         <create type="JDBCConnectionPool" name="OneSourceConnectionPool">
         <set attribute="DriverName"
         value="oracle.jdbc.OracleDriver"/>
         <set attribute="InitialCapacity" value="1"/>
         <set attribute="MaxCapacity" value="5"/>
         <set attribute="Password" value="rating"/>
         <set attribute="Properties" value="user=rating"/>
         <set attribute="RefreshMinutes" value="0"/>
         <set attribute="ShrinkPeriodMinutes" value="15"/>
         <set attribute="ShrinkingEnabled" value="true"/>
         <set attribute="TestConnectionsOnRelease" value="true"/>
         <set attribute="TestConnectionsOnReserve" value="true"/>
         <set attribute="TestConnectionsOnCreate" value="true"/>
         <set attribute="TestTableName" value="SQL SELECT 1 FROM DUAL"/>
         <set attribute="URL"
         value="jdbc:oracle:thin:@xyz.com:1522:oradvl"/>
         <set attribute="Targets" value="myserver"/>
         </create>
         </wlconfig>
    </target>
    When I run it, I see the following error:
    BUILD FAILED
    C:\ganymede\eclipse\workspace1\RtgSvr\build.xml:286: Failed to connect to the server: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
         java.io.EOFException]
    Can anybody please help me regarding this...
    Thank you,
    Sowmya

    Hi everybody,
    Thank you very much for your replies....actually I added weblogic.jar to the classpath of the target. So, now I dont see that error. But, I have another problem which is as follows:
    <target name="initJDBC">
    <wlconfig url="t3://${host}:${port}" username="${username}" password="${password}">
         <query domain="domain.name" type="Server" name="${target.server}" property="${target.server}"/>
         <create type="JDBCConnectionPool" name="TestConnectionPool">
         <set attribute="DriverName" value="oracle.jdbc.OracleDriver"/>
         <set attribute="Password" value="welcome"/>
         <set attribute="Properties" value="user=welcome"/>
         <set attribute="URL" value="jdbc:oracle:thin:@test.com:1522:oradvl"/>
              <set attribute="Targets" value=""/>
         <set attribute="TestTableName" value="SQL SELECT 1 FROM DUAL"/>
         <set attribute="TestConnectionsOnRelease" value="false"/>
         <set attribute="TestConnectionsOnReserve" value="true"/>
         </create>
         <create type="JDBCDataSource" name="TestDataSource">
              <set attribute="JNDIName" value="TestDataSource"/>
              <set attribute="PoolName" value="TestConnectionPool"/>
              <set attribute="Targets" value=""/>
              </create>
         </wlconfig>
         </target>
    I am not knowing what to give in the value field of <set attribute="Targets" value=""/>. The following is my build.properties file:
    target.server=myserver
    host=127.0.0.1
    port=7001
    username=weblogic
    password=weblogic
    domain.name=testDomain
    If I give <set attribute="Targets" value="${myserver}"/>, I get the following error:
    BUILD FAILED
    C:\ganymede\eclipse\workspace1\TestSvr\build.xml:290: Property not set: ${myserver}
    When I set myserver=myserver in build.properties, I get the following error:
    BUILD FAILED
    C:\ganymede\eclipse\workspace1\TestSvr\build.xml:290: Error invoking MBean command: java.lang.IllegalArgumentException: Property Name and value not valid for the MBean. Value myserver for parameter[Targets].java.lang.IllegalArgumentException: Unable to convert the argument valuemyserver to class javax.management.ObjectName.java.lang.reflect.InvocationTargetException
    Can someone plzz help me in this regard.
    Thank you,
    Sowmya

  • Are the WLS 9.1 Web Service Ant Tasks ready for prime time?

    I am trying to create a Proof of Concept (POC) for Enterprise and B2B Services at Wendy's Int'l, Inc.
    As part of this POC, I created a WSDL for an in-house service and then used the wsdlc and jwsc Ant Tasks to translate this WSDL to Java classes and ultimately (I hoped) a deployable services.
    In this document, I describe the issues I encountered setting up what I consider to be a simple POC.
    I'll try to attach my WSDL file and build.xml so you can follow along.
    I'll also try to attach my CSS file so you can compare how the generated WSDL appears in the Browser to the way I want it to appear.
    If attachments are not allowed on these forums, then I will wait and see if there is interest in those documents before I paste them under this topic.
    Some preliminary information about my environment.
    Environment:
         Windows XP Pro SP2
         WebLogic 9.1
         Java 1.5.0_04
    Service Name:
         AppRelease
    Note: If I modify my WSDL (perhaps to add a new Operation or to change the definition of an element) and run wsdlc again, the AppReleaseSOAPPortImpl.java file is overwritten For this reason, I implemented my service logic in a class called AppReleaseServiceImple.java.
    Now, for the issues.
    1.     Bug:
    In the WSDL generated by wsdlc, the wsdl:part child of the wsdl:message tag is erroneously prefixed with a colon.
    This occurs whether or not I specify a prefix for the http://schemas.xmlsoap.org/wsdl/ namespace.
    Work around: Extract the wsdl from the jar file, fix it and add it back into the jar.
    2.     Bug:
    In the WSDL generated by wsdlc, the wsdl:input and wsdl:output children of the wsdl:operation child of wsdl:portType tag are erroneously prefixed with a colon. Like 1 above, this occurs whether or not I specify a prefix for the http://schemas.xmlsoap.org/wsdl/ namespace.
    Work around: Extract the wsdl from the jar file, fix it and add it back into the jar.
    The error message generated by Bugs 1 and 2 is not helpful in diagnosing the problem:
    [jwsc] Error at line:46 col:7 ':' expected [?! -- [CDATA[ ]
    3.     Bug:
    In the WSDL generated by wsdlc, the documentation elements have all of my html elements stripped out, as well as my xhtml and wsdl namespace references. This completely negates one of the best features of the documentation tag, being able to present the WSDL in a browser as a nicely formatted, human friendly document which is also the underlying WSDL that can be viewed when the person views the source document.
    I label this as a bug because it greatly reduces the functionality of the resulting WSDL.
    4.     Annoyance:
    The WSDL generated by wsdlc has all of my comments stripped out, except the comments in the xsd:schema section of the wsdl:types element. I would prefer that all my comments be left in the WSDL, but if comments must be stripped out then I think all of the comments should be stripped out.
    5.     Annoyance:
    The WSDL generated by wsdlc has my CSS specification stripped.
    Work around: I don’t know if adding the CSS back will do any good because I have not yet created a deployable service (see the last issue below).
    6.     Annoyance:
    The WSDL generated by wsdlc has different namespace prefixes than the ones I specified for my application's namespace and for the http://schemas.xmlsoap.org/wsdl/soap/ namespace.
    Work around: Perform a find/replace on namespace prefixes "s0" and "s1" to return them to my prefered values.
    Another thing I can do at this point is simply replace the generated WSDL in the jar file with my original WSDL. This would address issues 1 thru 6 above.
    7.     Annoyance:
    The java source files created by wsdlc are put into a jar file. This makes it annoying when working within a traditional IDE like Eclipse because there is no way to reference the source files within the jar as working source.
    Work around: Extract the source files from the jar and identify the resulting directory structure as part of the source structure of the project.
    8.     Bug:
    The jwsc task complains if the same parameter name is used in multiple operations. I received the following Errors from jwsc:
    [jwsc] C:\IDE\workspace\Acre-WL9.1\AppReleaseSOAPPort.java 0:0
    [jwsc] [ERROR] - Parameter element "{http://acre.services.wendys.com/AppRelease/}garRequest" is not unique across document/literal bare WebService.
    Since the operation names are unique, I see no reason to also require uniqueness in the parameter names used by those operations.
    Work around: Use unique element names for the input parameters of the services operations.
    9.     Bug:
    Once items 1, 2 and 8 above are taken care of, jwsc fails with the following error:
    java.lang.AssertionError: java.lang.ClassNotFoundException: weblogic.j2ee.descriptor.ApplicationBeanImpl
    This seems to be due to the weblogic.jar file not being in the System Classpath.
    However, I should note that when I set verbose="on" and debug="on" in the jwsc ant task, there was a message from the task which stated "[jwsc] [search path for class files: [big freakin’ jar list]". In the big freakin’ jar list, I did find weblogic.jar and weblogic.jar has the required ApplicationBeanImpl. This indicates to me that the jwsc task does not fully honor either its classpathref attribute, nor an embedded classpath element.
    Work around: Make sure the weblogic.jar is in the System Classpath.
    10.     Bug:
    I fixed bug #9 by running a setDomainEnv script and then ran my ant task. This time I received the following output:
    ant build-serviceBuildfile: build.xml
    build-service:
    [jwsc] 1 JWS files will be processed.
    [jwsc] Processing JWS: C:\IDE\workspace\Acre-WL9.1\src\com\wendys\services\acre\AppReleaseServiceImpl.java
    [jwsc] JWS: C:\IDE\workspace\Acre-WL9.1\src\com\wendys\services\acre\AppReleaseServiceImpl.java Validated.
    [AntUtil.deleteDir] Deleting directory <some temporary directory>
    BUILD FAILED
    java.lang.ExceptionInInitializerError
    At this point, I am completely stymied about how to proceed.
    I wonder what new issues await once this 10th issue is addressed.
    Really, is this tool set ready for prime time?

    <i>Sorry to hear you are having so many issues with using the WLS 9.1 web service Ant tasks, inside of Eclipse.
    I generally create a User Library for the couple weblogic jars needed, and use it (the User Library) in my Eclipse projects that I create JWSes in.</i><br>
    I also have a separate WebLogic Library in Eclipse (actually 2 libraries since I work with WL 8.1 and now WL 9.1). As you may know, one of the long-standing issues with the Ant integration within Eclipse is the fact that Ant, being an External Tool, does not receive the Project-specific Paths/Libraries. However, since most Java-relevant Ant tasks can take classpath and classpathref attributes, this is usually not an issue. In the case of the BEA-supplied wsdlc Ant task, it is apparent from the verbose/debug console output that wsdlc can see the jars in its classpathref, but it ignores those references when resolving class references and instead only uses the system classpath.
    <p>
    <i>I've only needed the weblogic.jar and xbean.jar, not all the ones you mentioned in an earlier thread of this post.</i><br>
    I have not tried to winnow down exactly which jars are required. I simply included all the jars that exist and were added to the system classpath by the setDomainEnv.bat file created by WebLogic 9.1.
    <p>
    <i>Afterwards, I create an Ant Builder to build the JWS Web Service EAR, as opposed to fiddlin' with Eclipse.</i><br>
    I too use Ant to build my deployable archives. Eclipse is simply my IDE of choice. I validated that all the issues I listed occurred when running Ant from the command line.
    <p>
    <i>If you are interested in how I do it, send me an e-mail (to [email protected]), and I'll send you a zip of one of these JWS projects. The build.xml script for the project, takes care of a lot of the "annoyances" you mentioned, one of which I think is not accurate. I have never had a situation where the wsdlc Ant task "overwrote" my XXXImpl.java file..</i><br>
    Since I'm doing a POC to determine how we want to proceed with developing Web Services and an SOA in general, I tried to perform the same tasks using Axis 2 1.0, the WebLogic 9.1 tools, and XFire 1.1. Overwriting the Impl class is a common failing in the tools which take a WSDL and create Java source files for all three frameworks.
    <p>
    Try my scenario. Add another operation to an existing WSDL, and run the wsdlc Ant Task. The old IMPL class will be over-written.
    <p>
    Because of this, I have a separate Impl class and I make sure that all its methods and annotations match the methods and annotations in the Skeleton Impl class created by wsdlc.
    <p>
    <i>Maybe that's because I use the <exec> Ant task with jar.exe (the xvf options) in my build.xml, to only get what I need out of the .jar/.zip the wsdlc generates. I'm typically only interest in the interface class that my XXXImpl.java file needs to implements, because I use XMLBeans for the input args (and return values) of my web service operations.</i><br>
    Perhaps. I am not using XMLBeans in any of the three frameworks because the resulting service seems to be lighter-weight in all three frameworks if XMLBeans is not used. I'm sure there will be scenarios where XMLBeans is preferred, but I have not encountered that case in this POC.
    <p>
    <i>Regards,
    Mike Wooten</i>
    Thanks for the follow-up.
    Mike McAngus

  • FU Ant task failure: java.util.concurrent.ExecutionException: could not close client/server socket

    We sometimes see this failure intermitently when using the FlexUnit Ant task to run tests in a CI environment. The Ant task throws this exception:
    java.util.concurrent.ExecutionException: could not close client/server socket
    I have seen this for a while now, and still see it with the latest 4.1 RC versions.
    Here is the console output seen along with the above exception:
    FlexUnit player target: flash
    Validating task attributes ...
    Generating default values ...
    Using default working dir [C:\DJTE\commons.formatter_swc\d3flxcmn32\extracted\Source\Flex]
    Using the following settings for the test run:
    FLEX_HOME: [C:\dev\vert-d3flxcmn32\302100.41.0.20110323122739_d3flxcmn32]
    haltonfailure: [false]
    headless: [false]
    display: [99]
    localTrusted: [true]
    player: [flash]
    port: [1024]
    swf: [C:\DJTE\commons.formatter_swc\d3flxcmn32\extracted\build\commons.formatter.tests.unit.sw f]
    timeout: [1800000ms]
    toDir: [C:\DJTE\commons.formatter_swc\d3flxcmn32\reports\xml]
    Setting up server process ...
    Entry  [C:\DJTE\commons.formatter_swc\d3flxcmn32\extracted\build] already  available in local trust file at  [C:\Users\user\AppData\Roaming\Macromedia\Flash  Player\#Security\FlashPlayerTrust\flexUnit.cfg].
    Executing 'rundll32' with arguments:
    'url.dll,FileProtocolHandler'
    'C:\DJTE\commons.formatter_swc\d3flxcmn32\extracted\build\commons.formatter.tests.unit.swf '
    The ' characters around the executable and arguments are
    not part of the command.
    Starting server ...
    Opening server socket on port [1024].
    Waiting for client connection ...
    Client connected.
    Setting inbound buffer size to [262144] bytes.
    Receiving data ...
    Sending acknowledgement to player to start sending test data ...
    Stopping server ...
    End of test data reached, sending acknowledgement to player ...
    When the problem occurs, it is not always during the running of any particular test (that I am aware of). Recent runs where this failure was seen had the following number of tests executed (note: the total number that should be run is 45677): 18021, 18, 229.
    Here is a "good" run when the problem does not occur:
    Setting inbound buffer size to [262144] bytes.
    Receiving data ...
    Sending acknowledgement to player to start sending test data ...
    Stopping server ...
    End of test data reached, sending acknowledgement to player ...
    Closing client connection ...
    Closing server on port [1024] ...
    Analyzing reports ...
    Suite: com.formatters.help.TestGeographicSiteUrls
    Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.008 sec
    Suite: com.formatters.functionalUnitTest.testCases.TestNumericUDF
    Tests run: 13, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.071 sec
    Results :
    Tests run: 45,677, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 201.186 sec
    Has anyone else ran across this problem?
    Thanks,
    Trevor

    I am not sure if this information will help everyone, but here goes...
    For us, these problems with FlexUnit tests crashing the Flash Player appear to be related to couple of factors. Recently, we moved up from Flex 3.2 to Flex 4.1 as our development baseline.  Many people complained that their development environment (Flash Builder, etc.) was much more unstable.  Apparently, 4.1 produces SWFs that require more memory to run than 3.2 does?  Anyway, we still had Flash Player 10.1 as our runtime baseline.  Apparently, that version of the player was not as capable of running larger FlexUnit test SWFs, and would crash (as I posted months earlier).  I upgraded to the latest 10.3 standalone player versions, and the crashes have now ceased.  It would be nice to know exactly what was causing the crashes, but memory management (or lack of) is my best guess.
    So, if you are seeing these issues, try upgrading to the latest Flash Player version.
    Regards,
    Trevor

  • Ant task to include Halo theme

    Hi,
    I recently migrated from Flex 3.4 to Flex 4. Everything works fine when I compile the application using Flash Builder 4. But I am having issues making our automated ant builds pick up the Halo theme over the Spark theme.
    In FB4, I just used the "Flex Theme" options under Project -> Properties to define the Halo theme as the default theme.Before that I used the -theme compiler argument. Both work fine.
    For our ant task, I tried adding:
      <compiler.theme dir="${FLEX_HOME}/frameworks" append="false">
                 <include name="/themes/Halo/halo.swc" />
      </compiler.theme>
    Unfortunately that does not seem to work and the result still shows the Spark theme. I also tried making "theme" a task attribute and the other options according to Flex 4 docs ( http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf69084-7a63.html ), but to no avail.
    I have very limited experience with ant and would appreciate some input.
    Thanks!

    I just ran into this same issue yesterday, Here's what worked for me, placed between the <mxmlc>   </mxmlc> tags
    <theme dir="${FLEX_HOME}/frameworks/themes/Halo">
           <include name="halo.swc" />
    </theme>

  • MXMLC ANT task not including AIR libraries

    Hi Guys,
    This is the MXMLC ant task which I am using the compile my test app. If i set the static-link-runtime-shared-libraries="true" , the AIR libraries gets merged into my output swf. But when this attribute is set to false, I dont see the AIR libraries added to my SWF file. As a result when I run the AIR version fo my project, I dont see the application launch right. I have so many RSL in my project and I wanted to have static-link-runtime-shared-libraries="false". Is there a way to have AIR libraries include in my output file and still have this static-link-runtime-shared-libraries="false".
    <mxmlc
        file="${project.name}/src/Test.mxml"
        output="${build.mxmlc.dir}/Test.swf"
        static-link-runtime-shared-libraries="true"
        >
         <load-config filename="${air.config}"/>
         <source-path path-element="${project.name}/src" />
         <source-path path-element="${flex.frameworks.dir}/libs/air"/>
        <runtime-shared-library-path path-element="${flex.frameworks.dir}/libs/framework.swc">
                    <url rsl-url="${rsl.dir}/framework_3.2.0.3958.swz"/>
                    <url rsl-url="${rsl.dir}/framework_3.2.0.3958.swf"/>
        </runtime-shared-library-path>
        <runtime-shared-library-path path-element="${flex.frameworks.dir}/libs/datavisualization.swc">
                    <url rsl-url="${rsl.dir}/datavisualization_3.2.0.3958.swf"/>
        </runtime-shared-library-path>
       </mxmlc>
    My RSL are compiled using COMPC task and the AIR libraries are included into them using the below attributes of compc task.
    <source-path path-element="${basedir}/src" />
    <source-path path-element="${flex.frameworks.dir}/projects/airframework/src" />
    <source-path path-element="${flex.frameworks.dir}/projects/air/ServiceMonitor/src" />
    I am really stuck with this problem and not able to get my release build launch right. Again, any light on this problem will be of great help.!

        <mxmlc
             file="${project.name}/src/Test.mxml"
             output="${build.mxmlc.dir}/Test.swf"
             static-link-runtime-shared-libraries="true"
        >
              <load-config filename="${air.config}"/>
              <source-path path-element="${project.name}/src" />
             <runtime-shared-library-path path-element="${flex.frameworks.dir}/libs/framework.swc">
                    <url rsl-url="${rsl.dir}/framework_3.2.0.3958.swz"/>
                    <url rsl-url="${rsl.dir}/framework_3.2.0.3958.swf"/>
             </runtime-shared-library-path>
             <runtime-shared-library-path path-element="${flex.frameworks.dir}/libs/datavisualization.swc">
                    <url rsl-url="${rsl.dir}/datavisualization_3.2.0.3958.swf"/>
             </runtime-shared-library-path>
        </mxmlc>
    This also seems to work. AIR libraries are included in my output SWF. It all happens right when I have static-link-runtime-shared-libraries="true" . Why? Why does that not work when i have static-link-runtime-shared-libraries="false"  ??

  • Java.lang.NullPointerException running flexunit ant task in 4.1 Beta 2

    Hello,
    After trying to debug this all day, I thought I would ask the community.
    I am trying out the new FU4.1 Beta 2 (3.5) from the downloads page.  We have a working CI system set up with 4.0, and I thought trying out 4.1 beta 2 would simply be a matter of replacing the binaries in my lib folder and re-running the ant script.  Evidently not, or else I am missing something.
    After updating to the 4.1 Beta 2 binaries, if I re-run a sample project in Eclipse, the build fails with a java NullPointerException when the <flexunit> ant task is invoked. We have an involved setup that uses the groovy AntBuilder and other esoteric constructs, so I thought I would create a very simple test script similar to the sample CI project to see if that would work.  Unfortunately, I am still seeing the NPE.  The worst part is that there is absolutely no debug information provided - no message, no traceback.  I even attached the Ant source and debugged it. I could see the NPE being caught, but it contained a null message and null traceback.
    Here is the simplified ant script:
    <project name="tests" basedir=".">
        <target name="test-init" depends="">
            <mkdir dir="${build.dir}"/>
            <mkdir dir="${reports.dir}"/>
            <mkdir dir="${reports.xml}"/>
            <mkdir dir="${reports.html}"/>
            <!-- Setup Flex and FlexUnit ant tasks -->
            <!-- You can set this directly so mxmlc will work correctly, or set
            <taskdef resource="flexUnitTasks.tasks" classpath="${lib}/flexUnitTasks-4.1.0-beta2.18.jar" />
        </target>
        <target name="run-flex-tests" depends="test-init">
          <sequential>
            <!-- Execute TestRunner.swf as FlexUnit tests and publish reports -->
            <flexunit
                swf="${build.dir}/TestRunner.swf"
                toDir="${reports.xml}"
                haltonfailure="false"
                verbose="true"
                localTrusted="true"
                timeout="60000"/>
            <!-- Generate readable JUnit-style reports -->
            <junitreport todir="${reports.xml}">
                <fileset dir="${reports.xml}">
                    <include name="TEST-*.xml" />
                </fileset>
                <report format="frames" todir="${reports.html}" />
            </junitreport>
          </sequential>   
        </target>
    </project>
    The output is:
    Buildfile: C:\EclipseWorkspace\tests\Source\Flex\build_test.xml
    test-init:
    run-flex-tests:
    [flexunit] Validating task attributes ...
    BUILD FAILED
    C:\EclipseWorkspace\tests\Source\Flex\build_test.xml:23: java.lang.NullPointerException
    Total time: 297 milliseconds
    Is there something obvious I am missing?
    Thanks for any help!
    Trevor

    Brian,
    OK, a colleague worked with me (thanks, John!) to debug the problem a little further, and I think we found the fundamental problem.  I wanted to post that info to save you some time...
    Aside: One thing we did have to do was to rebuild the flexUnitTasks.jar to include debug information, since the binary in the 4.1 beta 2 package did not have debug=true.  I'd suggest that we might want to change the build script to build the binaries with debug moving forward.
    Back to the problem.
    The NullPointerException is thrown in TaskConfiguration::validateSharedProperties(), when equals() is invoked. Here is the code snippet:
       //if we can't find the FLEX_HOME and we're using ADL or compilation
       if((flexHome == null || !flexHome.exists()) && (testRunConfiguration.getPlayer().equals("air") || shouldCompile()))
          throw new BuildException("Please specify, or verify the location for, the FLEX_HOME property.  "
                + "It is required when testing with 'air' as the player or when using the 'testSource' element.  "
                + "It should point to the installation directory for a Flex SDK.");
    In my case, I do not have a FLEX_HOME property set in Ant currently.  I'll bet most folks have this set, so the logic would run differently for them. For my case, the (flexHome == null) check is true.  That means that the testRunConfiguration.getPlayer().equals("air")check will occur next, and here is the problem. The "player" member is not set in the testRunConfiguration yet at this point, so testRunConfiguration.getPlayer() returns null. testRunConfiguration.setPlayer() is called in generateDefaults().  But generateDefaults() is not called until after validateSharedProperties() is called.  So, if properties initialization could be improved here and I think this code will run more robustly.
    I can work-around my issue temporarily by just setting a FLEX_HOME property in Ant.  But I hope you will agree that the initialization issue with "player" still should be addressed. Would you like me to open a bug report, or is this thread enough?
    Thanks,
    Trevor

Maybe you are looking for

  • How do I get my Audio book back on my Ipad?

    How do I get my Audio book back?

  • How come my apply device on this apple forum can't display the 'and' character?

    I'm sure it dose it at some other places, and I'm sure it's something silly I'm doing wrong. But when I type the &  (numeric then J) instead of typing AND, it dose them extra bits after I hit 'post message'

  • Project Management duties on Web Developer Project

    As a Project Managment Leader in a Web Developers work shop what are the main duties of a Project Manager? Here is what I have so far: 1st Step - Gather Requirements 2nd Step - List the Tasks which would include the Database design, Data Modeling, Sc

  • Filter list by term

    Hej, i'm trying to set up an internal documentation site. We defined several groups and topics to categorize our documents, lists and tasks. The idea was to set up a site with a managed navigation based on the previously defined taxonomy. Our taxonom

  • About oem 9ir2

    Hi, I installed oracle 9ir2 database and create oem repository on windows 2000 server. I can discover everything(db, http, listener, ...etc) on nodeA that I installed database and oem repository. But after discover nodeB that I installed oralce 9ir2