Error on unmarshalling JSON content: wrong format.

When start with Distributed mode, OSerializtionException happened.
Error on unmarshalling JSON content: wrong format. Use <field> : <value>.
Exception happened at ORecordSerializerJSON.java Method : fromString 
    if (fields.size() % 2 != 0)
      throw new OSerializationException("Error on unmarshalling JSON content: wrong format. Use <field> : <value>");
Due to "," at the end of json, this fields number is 9 not 8. Easiest solution, remove "," before end of json object


Write some simple test code to verify. 

  public static void testloadDatabaseConfiguration(final String filePath) {
	    File file = new File(filePath);
	    if (!file.exists() || file.length() == 0)
	      return;
	    FileInputStream f = null;
	    try {
	      f = new FileInputStream(file);
	      final byte[] buffer = new byte[(int) file.length()];
	      f.read(buffer);
	      System.out.println("<loadDatabaseConfiguration> : " + new String(buffer));
	      ODocument doc = (ODocument) new ODocument().fromJSON(new String(buffer), "noMap");
	    } catch (Exception e) {
	    } finally {
	      if (f != null)
	        try {
	          f.close();
	        } catch (IOException e) {
	        }
	    }
	  }
support compress response content
NPE

NPE checking
sync with trunk
Support gzip compression for response data
Support gzip compression for response data
gzip compression
Merge branch 'master' of git://github.com/nuvolabase/orientdb
For embedded json object
get request source
get request source
Merge branch 'master' of git://github.com/nuvolabase/orientdb
Merge branch 'master' of https://github.com/henryzhao81/orientdb
1. Enhancement  -  If I/O exception will be thrown data consistency will not be compromised. Issue #1404.
 2. Build fix.
Issue #1404. Magic numbers were removed.
Issue #1404. LRU cache was replaced by 2Q cache. Cache API was refactored to provide more robust approach for cache management.
Issue #1404. LRU cache was replaced by 2Q cache. Cache API was refactored to provide more robust approach for cache management.  Thanks to @logart !
MVRBTreeRID: fixed bugs on removing last persistent items

Before this patch it removed also all the new items because it called
clear(). Now tests about the size of the tree. Fixed also other parts
where the size() was asked but the real tree size is needed.
Configuration (mvrbtree.ridNodePageSize): enlarged node page size from 16 to 64 items for MVRBTree RID sets
Fixed bug on reusing of iterators