Issue 14200

Error in Freemarker template on Occurrence search response

14200
Reporter: lfrancke
Assignee: fmendez
Type: Bug
Summary: Error in Freemarker template on Occurrence search response
Priority: Major
Resolution: WontFix
Status: Closed
Created: 2013-10-10 16:01:45.936
Updated: 2015-03-03 18:37:38.239
Resolved: 2015-03-03 18:37:38.213
        
Description: I saw a 503 on this [rather complex|http://www.gbif.org/occurrence/search?GEOMETRY=117.421875+-47.989921%2C-59.0625+-53.748710%2C-52.734375+-22.593726%2C-112.5+9.795677%2C-84.375+52.908902%2C25.3125+51.618016%2C4.21875+21.289374%2C70.3125+48.458351%2C16.875+-2.108898%2C79.453125+-3.513421%2C-16.875+-19.973348%2C-15.468749+27.059125%2C-42.890625+19.973348%2C-31.640625+-39.909736%2C108.984375+-7.013667%2C91.40625+54.572061%2C118.828125+54.977613%2C141.328125+-48.922499%2C125.156250+-61.270232%2C95.625+-58.447732%2C117.421875+-47.989921&BASIS_OF_RECORD=OBSERVATION&BASIS_OF_RECORD=LIVING_SPECIMEN&YEAR=*%2C2010] query. The underlying log shows the following error:

{quote}
ERROR [2013-10-10 15:58:14,344+0200] [http-bio-8080-exec-4058] com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor: The following has evaluated to null or missing:
==> searchResponse  [in template "WEB-INF/pages/occurrence/search.ftl" at line 286, column 6]

Tip: If the failing expression is known to be legally null/missing, either specify a default value with myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthessis: (myOptionVar.foo)!myDefault, (myOptionVar.foo)??

The failing instruction:
==> #if searchResponse.offset gte maxAllo...  [in template "WEB-INF/pages/occurrence/search.ftl" at line 286, column 1]
freemarker.core.InvalidReferenceException: The following has evaluated to null or missing:
==> searchResponse  [in template "WEB-INF/pages/occurrence/search.ftl" at line 286, column 6]

Tip: If the failing expression is known to be legally null/missing, either specify a default value with myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthessis: (myOptionVar.foo)!myDefault, (myOptionVar.foo)??

The failing instruction:
==> #if searchResponse.offset gte maxAllo...  [in template "WEB-INF/pages/occurrence/search.ftl" at line 286, column 1]
{quote}]]>
    


Author: fmendez@gbif.org
Comment: This looks like a bug in com.vividsolutions.jts.io.WKTReader or Solr Spatial components, JTS accepts the GEOMETRY as a valid shape but Solr doesn't
Created: 2015-03-03 18:37:38.237
Updated: 2015-03-03 18:37:38.237