<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
  </head>
  <body wsmode="compose" bgcolor="#FFFFFF" text="#000000">
    Hello,<br>
    <br>
    I'm currently assessing the WFS client from Geotoolkit. We would
    like to use it in a new project (also because we would like to use
    Apache SIS progressively), with the purpose to discover featuretypes
    and fetch the featureCollection data, relying on the official GeoAPI.<br>
    <br>
    I've been trying to use Geotoolkit 4.0-M2 (which AFAIK is the latest
    milestone release), and the geotk-wfs-client.<br>
    <br>
    I get the following stack trace :<br>
    <br>
    <i>déc. 08, 2014 11:11:58 PM
      org.geotoolkit.data.wfs.WebFeatureClient getCapabilities</i><i><br>
    </i><i>AVERTISSEMENT: TimeOut error, the server takes too much time
      to answer. </i><i><br>
    </i><i>Exception in thread "main" java.lang.NullPointerException</i><i><br>
    </i><i>    at
org.geotoolkit.data.wfs.WFSFeatureStore.checkTypeExist(WFSFeatureStore.java:114)</i><i><br>
    </i><i>    at
org.geotoolkit.data.wfs.WFSFeatureStore.<init>(WFSFeatureStore.java:107)</i><i><br>
    </i><i>    at org.fao.fi.wfstesting.App.main(App.java:33)</i><br>
    <br>
    <br>
    for this code:<br>
    <br>
            final WebFeatureClient wfsServer = new WebFeatureClient(new
    URL(<a class="moz-txt-link-rfc2396E" href="http://www.fao.org/figis/geoserver/ows">"http://www.fao.org/figis/geoserver/ows"</a>), "1.1.0");<br>
            final GetCapabilitiesRequest getCapa =
    wfsServer.createGetCapabilities();<br>
            <br>
            final GetFeatureRequest getFeature =
    wfsServer.createGetFeature();<br>
            //simplify WFS like a datastore<br>
            final FeatureStore store = new WFSFeatureStore(wfsServer);<br>
            <br>
            String[] typeNames = store.getTypeNames();<br>
            for(String typeName : typeNames){<br>
                FeatureType ft = store.getFeatureType(typeName);<br>
                System.out.println(ft.getName());<br>
                System.out.println("==");<br>
            }<br>
    <br>
    I admit i'm lost. I had a look to the code for which i identified
    the timeout warning.<br>
    But nothing about the exception. Any idea?<br>
    <br>
    Thanks in advance for your help<br>
    Emmanuel<br>
    <br>
  </body>
</html>