sabman wrote:
> I did not copy the jar file in the WEB-INF/lib folder. I did that now but its
> still the same.
Did you restart geoserver after you did?
> 
> There is no information related to the exception in the log file.  There are
> some errors messages in eclipse which I am listing below:
Yeah, there probably won't be an exception, just nothing in the log 
file. It could also be that your applicationContext.xml file is in the 
wrong place. Is it under src/main/java in the root of your plugin source?

Can you do a "jar tvf hello_rest.jar" to give us a listing of the files. 
Thanks.
> 
> 1) In the HelloResource.java file, 
>  For this piece of code: 
>       protected Map<String, DataFormat> createSupportedFormats(Request 
> request,
> Response response) {
> 
>          HashMap formats = new HashMap();
>          formats.put( "txt", new StringFormat( MediaType.TEXT_PLAIN ));
> 
>          return formats;
>       }
> 
> These are the errors:
> @ Map<String, DataFormat> Multiple markers at this line
>       - The return type is incompatible with
> AbstractResource.createSupportedFormats(Request, 
>        Response)
>       - implements org.geoserver.rest.AbstractResource.createSupportedFormats 
> 
> @HashMap Multiple markers at this line
>       - HashMap cannot be resolved 
>        to a type
>       - HashMap cannot be resolved 
>        to a type
> 
> @StringFormat and @MediaType Multiple markers at this line
>       - StringFormat cannot be resolved 
>        to a type
>       - MediaType cannot be resolved
These are because the rest module is not on the classpath of your 
module. Can you run a mvn eclipse:eclipse in the root of your module and 
  then refresh the project in eclipse. I think the tutorial is lackign 
that step.
> 
> 2)  When i start geoserver from eclipse by running the Start.java file I see
> the following warning messages in the console:
> 
> Jun 22, 2009 11:14:11 AM it.geosolutions.imageio.gdalframework.GDALUtilities
> loadGDAL
> WARNING: Native library load failed.java.lang.UnsatisfiedLinkError: no
> gdaljni in java.library.path
> ..
> ..
> log4j:WARN File option not set for appender [geoserverlogfile].
> log4j:WARN Are you using FileAppender instead of ConsoleAppender?
That is normal, you can ignore that.
> 
> 
> 
> 
> 
> aaime wrote:
>> sabman ha scritto:
>>   > I followed the instructions for the REST services available
>>> http://docs.geoserver.org/1.7.x/developer/programming-guide/rest-services/implementing.html
>>> here . The only changes I had to make was in the pom.xml file where i
>>> changed the org.geoserver versions to "1.7.5-SNAPSHOT" from
>>> "1.7.3-SNAPSHOT"
>>> (i compared it with the other pom.xml files). The hello_rest module
>>> compiled
>>> successfully. I then tried testing the rest service by going to the URL:
>>>
>>> http://localhost:8080/geoserver/rest/hello.txt
>>> http://localhost:8080/geoserver/rest/hello_rest/hello.txt
>>> http://localhost:8080/geoserver/rest/hello_rest
>>>
>>> I was not sure which one is correct so I tried all in the browser. And
>>> all I
>>> see is this:
>>>
>>> Geoserver Configuration API
>>>
>>>     * exception
>>>
>>> What am I doing wrong here? 
>> Did you actually include your jar/project in the GeoServer application
>> classpath? E.g, took the hello_rest jar and drop it into 
>> geoserver/WEB-INF/lib?
>>
>> Can you look in $GEOSERVER_DATA_DIR/logs/geoserver.log and see what 
>> exception (with full strack trace) is thrown when you try to access 
>> those URL's?
>>
>> Cheers
>> Andrea
>>
>>
>>
>> ------------------------------------------------------------------------------
>> Are you an open source citizen? Join us for the Open Source Bridge
>> conference!
>> Portland, OR, June 17-19. Two days of sessions, one day of unconference:
>> $250.
>> Need another reason to go? 24-hour hacker lounge. Register today!
>> http://ad.doubleclick.net/clk;215844324;13503038;v?http://opensourcebridge.org
>> _______________________________________________
>> Geoserver-devel mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/geoserver-devel
>>
>>
> 


-- 
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

------------------------------------------------------------------------------
Are you an open source citizen? Join us for the Open Source Bridge conference!
Portland, OR, June 17-19. Two days of sessions, one day of unconference: $250.
Need another reason to go? 24-hour hacker lounge. Register today!
http://ad.doubleclick.net/clk;215844324;13503038;v?http://opensourcebridge.org
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to