You are viewing a plain text version of this content. The canonical link for it is here.
Posted to submarine-dev@hadoop.apache.org by "Xun Liu (Jira)" <ji...@apache.org> on 2019/09/11 07:51:00 UTC

[jira] [Created] (SUBMARINE-182) Refactoring QueryResult class

Xun Liu created SUBMARINE-182:
---------------------------------

             Summary: Refactoring QueryResult class
                 Key: SUBMARINE-182
                 URL: https://issues.apache.org/jira/browse/SUBMARINE-182
             Project: Hadoop Submarine
          Issue Type: Sub-task
            Reporter: Xun Liu


Submarine server put QueryResult into JsonResponse, return to Submarine web front-end.

QueryResult java class is template class,
{code:java}
public class QueryResult<T> {
  private List<T> records;
  private long total;
{code}
now, QueryResult.java has a problem; records is List<T>.
 1. every return JsonResponse, Submarine web front-end always received a list object.
 2. QueryResult param is <T>, but records is List<T>. The two are not uniform.

So, I think we need to change
{code:java}
  private List<T> records;
{code}
TO
{code:java}
  private T records;
{code}



--
This message was sent by Atlassian Jira
(v8.3.2#803003)