Re: [Dev] [DAS] DAS dashboard table-gadget column order

2015-10-08 Thread Thanuja Uruththirakodeeswaran
Hi All,

I was able to change the column order in table gadget by giving the
required columns in gadgetConfig.js file and set the columns varible inside
getColumns() in main.js file as columns = gadgetConfig.columns;

Also if want to change table column titles as we want (Ex: sometime
database table have column as 'MemberId' and in the table gadget we want it
as 'Member Id') by introducing a new property (Ex: LABEL_NAME) in
gadgetConf.js file as shown in [1] and set this property as column title as
in [2].

Complete custom table gadget can be found here [3].

[1].
https://github.com/apache/stratos/blob/stratos-4.1.x/extensions/das/metering-service/capps/stratos-metering-service/Gadget_Member_Status/Member_Status/js/gadgetconf.js

[2].
https://github.com/apache/stratos/blob/stratos-4.1.x/extensions/das/metering-service/capps/stratos-metering-service/Gadget_Member_Status/Member_Status/js/main.js#L106

[3]. 
https://github.com/apache/stratos/tree/stratos-4.1.x/extensions/das/metering-service/capps/stratos-metering-service/Gadget_Member_Status

Thanks.



On Mon, Aug 24, 2015 at 2:56 PM, Gimantha Bandara  wrote:

> Hi Dunith,
>
> Are we internally processing the columns in the schema in gadget
> generation.. Like changing the column order? Or are we simply
> iterating the columns in the schema returned by JS API  when creating
> gadgets?
>
> On 8/24/15, Thanuja Uruththirakodeeswaran  wrote:
> > Hi Gimantha,
> >
> > Is there any solution to get Table Gadget column order as Data Explorer
> > Table column order?
> >
> > Thanks.
> >
> > On Fri, Aug 14, 2015 at 8:20 PM, Thanuja Uruththirakodeeswaran <
> > thanu...@wso2.com> wrote:
> >
> >> Hi Gimantha,
> >>
> >> Yes gadget table columns are not in the order as in schema. Data
> explorer
> >> has same column order as in schema.
> >>
> >> Thanks.
> >> On 14 Aug 2015 18:18, "Gimantha Bandara"  wrote:
> >>
> >>> Columns you define in the schema, does not map to RDBMS physical
> >>> tables' columns. Are you saying that the gadget tables that you
> >>> create, do not have the column order as it is in the schema? Is it in
> >>> the same order in the Data explorer?
> >>>
> >>> On 8/14/15, Thanuja Uruththirakodeeswaran  wrote:
> >>> > Hi Gimantha,
> >>> >
> >>> > I used external HBase DB and DAS embedded H2 DB. I checked with HBase
> >>> table
> >>> > and table-gadget column order same as HBase table. I tried with H2
> >>> table,
> >>> > but I couldn't see column names as I think it was encrypted or
> >>> something.
> >>> > How can I check the column names in DAS embedded H2 database?
> >>> >
> >>> > Thanks.
> >>> >
> >>> > On Fri, Aug 14, 2015 at 1:28 PM, Gimantha Bandara  >
> >>> > wrote:
> >>> >
> >>> >> Hi Thanuja,
> >>> >> Is it same with the H2 table or only the HBase analytics table?
> >>> >>
> >>> >>
> >>> >> On Thu, Aug 13, 2015 at 6:50 PM, Thanuja Uruththirakodeeswaran <
> >>> >> thanu...@wso2.com> wrote:
> >>> >>
> >>> >>> Hi,
> >>> >>>
> >>> >>> I've persisted a event stream in event store which is a HBase
> >>> database.
> >>> >>> Then using the following query I created table in spark
> environment.
> >>> Also
> >>> >>> I
> >>> >>> used H2 database as processed store.
> >>> >>>
> >>> >>> CREATE TEMPORARY TABLE memberinfo
> >>> >>> USING CarbonAnalytics
> >>> >>> OPTIONS (tableName "MEMBER_INFO");
> >>> >>>
> >>> >>> CREATE TEMPORARY TABLE memberdetails
> >>> >>> USING CarbonAnalytics
> >>> >>> OPTIONS (tableName "MEMBER_DETAILS", schema "X STRING, Y STRING, Z
> >>> >>> STRING");
> >>> >>>
> >>> >>> INSERT OVERWRITE TABLE memberdetails select * from memberinfo;
> >>> >>>
> >>> >>> Here MEMBER_INFO - HBase database table, MEMBER_DETAILS - H2
> >>> >>> database
> >>> >>> table
> >>> >>>
> >>> >>> When I use the Data Explorer to see records in table
> >>> >>> "MEMBER_DETAILS",
> >>> >>> column order as specified in schema. But when I created a table
> >>> >>> gadget
> >>> >>> using the same table and added to dashboard, column order is not as
> >>> >>> in
> >>> >>> schema. But I think columns are in the order as in HBase database
> >>> table.
> >>> >>>
> >>> >>> What I have to do to get the columns as in schema order?
> >>> >>>
> >>> >>> Thanks.
> >>> >>>
> >>> >>> --
> >>> >>> Thanuja Uruththirakodeeswaran
> >>> >>> Software Engineer
> >>> >>> WSO2 Inc.;http://wso2.com
> >>> >>> lean.enterprise.middleware
> >>> >>>
> >>> >>> mobile: +94 774363167
> >>> >>>
> >>> >>> ___
> >>> >>> Dev mailing list
> >>> >>> Dev@wso2.org
> >>> >>> http://wso2.org/cgi-bin/mailman/listinfo/dev
> >>> >>>
> >>> >>>
> >>> >>
> >>> >>
> >>> >> --
> >>> >> Gimantha Bandara
> >>> >> Software Engineer
> >>> >> WSO2. Inc : http://wso2.com
> >>> >> Mobile : +94714961919
> >>> >>
> >>> >
> >>> >
> >>> >
> >>> > --
> >>> > Thanuja Uruththirakodeeswaran
> >>> > Software Engineer
> >>> > WSO2 Inc.;http://wso2.com
> >>> > lean.enterprise.middleware
> >>> >
> 

Re: [Dev] [DAS] DAS dashboard table-gadget column order

2015-08-24 Thread Thanuja Uruththirakodeeswaran
Hi Gimantha,

Is there any solution to get Table Gadget column order as Data Explorer
Table column order?

Thanks.

On Fri, Aug 14, 2015 at 8:20 PM, Thanuja Uruththirakodeeswaran 
thanu...@wso2.com wrote:

 Hi Gimantha,

 Yes gadget table columns are not in the order as in schema. Data explorer
 has same column order as in schema.

 Thanks.
 On 14 Aug 2015 18:18, Gimantha Bandara giman...@wso2.com wrote:

 Columns you define in the schema, does not map to RDBMS physical
 tables' columns. Are you saying that the gadget tables that you
 create, do not have the column order as it is in the schema? Is it in
 the same order in the Data explorer?

 On 8/14/15, Thanuja Uruththirakodeeswaran thanu...@wso2.com wrote:
  Hi Gimantha,
 
  I used external HBase DB and DAS embedded H2 DB. I checked with HBase
 table
  and table-gadget column order same as HBase table. I tried with H2
 table,
  but I couldn't see column names as I think it was encrypted or
 something.
  How can I check the column names in DAS embedded H2 database?
 
  Thanks.
 
  On Fri, Aug 14, 2015 at 1:28 PM, Gimantha Bandara giman...@wso2.com
  wrote:
 
  Hi Thanuja,
  Is it same with the H2 table or only the HBase analytics table?
 
 
  On Thu, Aug 13, 2015 at 6:50 PM, Thanuja Uruththirakodeeswaran 
  thanu...@wso2.com wrote:
 
  Hi,
 
  I've persisted a event stream in event store which is a HBase
 database.
  Then using the following query I created table in spark environment.
 Also
  I
  used H2 database as processed store.
 
  CREATE TEMPORARY TABLE memberinfo
  USING CarbonAnalytics
  OPTIONS (tableName MEMBER_INFO);
 
  CREATE TEMPORARY TABLE memberdetails
  USING CarbonAnalytics
  OPTIONS (tableName MEMBER_DETAILS, schema X STRING, Y STRING, Z
  STRING);
 
  INSERT OVERWRITE TABLE memberdetails select * from memberinfo;
 
  Here MEMBER_INFO - HBase database table, MEMBER_DETAILS - H2 database
  table
 
  When I use the Data Explorer to see records in table MEMBER_DETAILS,
  column order as specified in schema. But when I created a table gadget
  using the same table and added to dashboard, column order is not as in
  schema. But I think columns are in the order as in HBase database
 table.
 
  What I have to do to get the columns as in schema order?
 
  Thanks.
 
  --
  Thanuja Uruththirakodeeswaran
  Software Engineer
  WSO2 Inc.;http://wso2.com
  lean.enterprise.middleware
 
  mobile: +94 774363167
 
  ___
  Dev mailing list
  Dev@wso2.org
  http://wso2.org/cgi-bin/mailman/listinfo/dev
 
 
 
 
  --
  Gimantha Bandara
  Software Engineer
  WSO2. Inc : http://wso2.com
  Mobile : +94714961919
 
 
 
 
  --
  Thanuja Uruththirakodeeswaran
  Software Engineer
  WSO2 Inc.;http://wso2.com
  lean.enterprise.middleware
 
  mobile: +94 774363167
 


 --
 Gimantha Bandara
 Software Engineer
 WSO2. Inc : http://wso2.com
 Mobile : +94714961919




-- 
Thanuja Uruththirakodeeswaran
Software Engineer
WSO2 Inc.;http://wso2.com
lean.enterprise.middleware

mobile: +94 774363167
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DAS] DAS dashboard table-gadget column order

2015-08-24 Thread Gimantha Bandara
Hi Dunith,

Are we internally processing the columns in the schema in gadget
generation.. Like changing the column order? Or are we simply
iterating the columns in the schema returned by JS API  when creating
gadgets?

On 8/24/15, Thanuja Uruththirakodeeswaran thanu...@wso2.com wrote:
 Hi Gimantha,

 Is there any solution to get Table Gadget column order as Data Explorer
 Table column order?

 Thanks.

 On Fri, Aug 14, 2015 at 8:20 PM, Thanuja Uruththirakodeeswaran 
 thanu...@wso2.com wrote:

 Hi Gimantha,

 Yes gadget table columns are not in the order as in schema. Data explorer
 has same column order as in schema.

 Thanks.
 On 14 Aug 2015 18:18, Gimantha Bandara giman...@wso2.com wrote:

 Columns you define in the schema, does not map to RDBMS physical
 tables' columns. Are you saying that the gadget tables that you
 create, do not have the column order as it is in the schema? Is it in
 the same order in the Data explorer?

 On 8/14/15, Thanuja Uruththirakodeeswaran thanu...@wso2.com wrote:
  Hi Gimantha,
 
  I used external HBase DB and DAS embedded H2 DB. I checked with HBase
 table
  and table-gadget column order same as HBase table. I tried with H2
 table,
  but I couldn't see column names as I think it was encrypted or
 something.
  How can I check the column names in DAS embedded H2 database?
 
  Thanks.
 
  On Fri, Aug 14, 2015 at 1:28 PM, Gimantha Bandara giman...@wso2.com
  wrote:
 
  Hi Thanuja,
  Is it same with the H2 table or only the HBase analytics table?
 
 
  On Thu, Aug 13, 2015 at 6:50 PM, Thanuja Uruththirakodeeswaran 
  thanu...@wso2.com wrote:
 
  Hi,
 
  I've persisted a event stream in event store which is a HBase
 database.
  Then using the following query I created table in spark environment.
 Also
  I
  used H2 database as processed store.
 
  CREATE TEMPORARY TABLE memberinfo
  USING CarbonAnalytics
  OPTIONS (tableName MEMBER_INFO);
 
  CREATE TEMPORARY TABLE memberdetails
  USING CarbonAnalytics
  OPTIONS (tableName MEMBER_DETAILS, schema X STRING, Y STRING, Z
  STRING);
 
  INSERT OVERWRITE TABLE memberdetails select * from memberinfo;
 
  Here MEMBER_INFO - HBase database table, MEMBER_DETAILS - H2
  database
  table
 
  When I use the Data Explorer to see records in table
  MEMBER_DETAILS,
  column order as specified in schema. But when I created a table
  gadget
  using the same table and added to dashboard, column order is not as
  in
  schema. But I think columns are in the order as in HBase database
 table.
 
  What I have to do to get the columns as in schema order?
 
  Thanks.
 
  --
  Thanuja Uruththirakodeeswaran
  Software Engineer
  WSO2 Inc.;http://wso2.com
  lean.enterprise.middleware
 
  mobile: +94 774363167
 
  ___
  Dev mailing list
  Dev@wso2.org
  http://wso2.org/cgi-bin/mailman/listinfo/dev
 
 
 
 
  --
  Gimantha Bandara
  Software Engineer
  WSO2. Inc : http://wso2.com
  Mobile : +94714961919
 
 
 
 
  --
  Thanuja Uruththirakodeeswaran
  Software Engineer
  WSO2 Inc.;http://wso2.com
  lean.enterprise.middleware
 
  mobile: +94 774363167
 


 --
 Gimantha Bandara
 Software Engineer
 WSO2. Inc : http://wso2.com
 Mobile : +94714961919




 --
 Thanuja Uruththirakodeeswaran
 Software Engineer
 WSO2 Inc.;http://wso2.com
 lean.enterprise.middleware

 mobile: +94 774363167



-- 
Gimantha Bandara
Software Engineer
WSO2. Inc : http://wso2.com
Mobile : +94714961919
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DAS] DAS dashboard table-gadget column order

2015-08-14 Thread Gimantha Bandara
Hi Thanuja,
Is it same with the H2 table or only the HBase analytics table?


On Thu, Aug 13, 2015 at 6:50 PM, Thanuja Uruththirakodeeswaran 
thanu...@wso2.com wrote:

 Hi,

 I've persisted a event stream in event store which is a HBase database.
 Then using the following query I created table in spark environment. Also I
 used H2 database as processed store.

 CREATE TEMPORARY TABLE memberinfo
 USING CarbonAnalytics
 OPTIONS (tableName MEMBER_INFO);

 CREATE TEMPORARY TABLE memberdetails
 USING CarbonAnalytics
 OPTIONS (tableName MEMBER_DETAILS, schema X STRING, Y STRING, Z
 STRING);

 INSERT OVERWRITE TABLE memberdetails select * from memberinfo;

 Here MEMBER_INFO - HBase database table, MEMBER_DETAILS - H2 database table

 When I use the Data Explorer to see records in table MEMBER_DETAILS,
 column order as specified in schema. But when I created a table gadget
 using the same table and added to dashboard, column order is not as in
 schema. But I think columns are in the order as in HBase database table.

 What I have to do to get the columns as in schema order?

 Thanks.

 --
 Thanuja Uruththirakodeeswaran
 Software Engineer
 WSO2 Inc.;http://wso2.com
 lean.enterprise.middleware

 mobile: +94 774363167

 ___
 Dev mailing list
 Dev@wso2.org
 http://wso2.org/cgi-bin/mailman/listinfo/dev




-- 
Gimantha Bandara
Software Engineer
WSO2. Inc : http://wso2.com
Mobile : +94714961919
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DAS] DAS dashboard table-gadget column order

2015-08-14 Thread Thanuja Uruththirakodeeswaran
Hi Gimantha,

Yes gadget table columns are not in the order as in schema. Data explorer
has same column order as in schema.

Thanks.
On 14 Aug 2015 18:18, Gimantha Bandara giman...@wso2.com wrote:

 Columns you define in the schema, does not map to RDBMS physical
 tables' columns. Are you saying that the gadget tables that you
 create, do not have the column order as it is in the schema? Is it in
 the same order in the Data explorer?

 On 8/14/15, Thanuja Uruththirakodeeswaran thanu...@wso2.com wrote:
  Hi Gimantha,
 
  I used external HBase DB and DAS embedded H2 DB. I checked with HBase
 table
  and table-gadget column order same as HBase table. I tried with H2 table,
  but I couldn't see column names as I think it was encrypted or something.
  How can I check the column names in DAS embedded H2 database?
 
  Thanks.
 
  On Fri, Aug 14, 2015 at 1:28 PM, Gimantha Bandara giman...@wso2.com
  wrote:
 
  Hi Thanuja,
  Is it same with the H2 table or only the HBase analytics table?
 
 
  On Thu, Aug 13, 2015 at 6:50 PM, Thanuja Uruththirakodeeswaran 
  thanu...@wso2.com wrote:
 
  Hi,
 
  I've persisted a event stream in event store which is a HBase database.
  Then using the following query I created table in spark environment.
 Also
  I
  used H2 database as processed store.
 
  CREATE TEMPORARY TABLE memberinfo
  USING CarbonAnalytics
  OPTIONS (tableName MEMBER_INFO);
 
  CREATE TEMPORARY TABLE memberdetails
  USING CarbonAnalytics
  OPTIONS (tableName MEMBER_DETAILS, schema X STRING, Y STRING, Z
  STRING);
 
  INSERT OVERWRITE TABLE memberdetails select * from memberinfo;
 
  Here MEMBER_INFO - HBase database table, MEMBER_DETAILS - H2 database
  table
 
  When I use the Data Explorer to see records in table MEMBER_DETAILS,
  column order as specified in schema. But when I created a table gadget
  using the same table and added to dashboard, column order is not as in
  schema. But I think columns are in the order as in HBase database
 table.
 
  What I have to do to get the columns as in schema order?
 
  Thanks.
 
  --
  Thanuja Uruththirakodeeswaran
  Software Engineer
  WSO2 Inc.;http://wso2.com
  lean.enterprise.middleware
 
  mobile: +94 774363167
 
  ___
  Dev mailing list
  Dev@wso2.org
  http://wso2.org/cgi-bin/mailman/listinfo/dev
 
 
 
 
  --
  Gimantha Bandara
  Software Engineer
  WSO2. Inc : http://wso2.com
  Mobile : +94714961919
 
 
 
 
  --
  Thanuja Uruththirakodeeswaran
  Software Engineer
  WSO2 Inc.;http://wso2.com
  lean.enterprise.middleware
 
  mobile: +94 774363167
 


 --
 Gimantha Bandara
 Software Engineer
 WSO2. Inc : http://wso2.com
 Mobile : +94714961919

___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DAS] DAS dashboard table-gadget column order

2015-08-14 Thread Gimantha Bandara
Columns you define in the schema, does not map to RDBMS physical
tables' columns. Are you saying that the gadget tables that you
create, do not have the column order as it is in the schema? Is it in
the same order in the Data explorer?

On 8/14/15, Thanuja Uruththirakodeeswaran thanu...@wso2.com wrote:
 Hi Gimantha,

 I used external HBase DB and DAS embedded H2 DB. I checked with HBase table
 and table-gadget column order same as HBase table. I tried with H2 table,
 but I couldn't see column names as I think it was encrypted or something.
 How can I check the column names in DAS embedded H2 database?

 Thanks.

 On Fri, Aug 14, 2015 at 1:28 PM, Gimantha Bandara giman...@wso2.com
 wrote:

 Hi Thanuja,
 Is it same with the H2 table or only the HBase analytics table?


 On Thu, Aug 13, 2015 at 6:50 PM, Thanuja Uruththirakodeeswaran 
 thanu...@wso2.com wrote:

 Hi,

 I've persisted a event stream in event store which is a HBase database.
 Then using the following query I created table in spark environment. Also
 I
 used H2 database as processed store.

 CREATE TEMPORARY TABLE memberinfo
 USING CarbonAnalytics
 OPTIONS (tableName MEMBER_INFO);

 CREATE TEMPORARY TABLE memberdetails
 USING CarbonAnalytics
 OPTIONS (tableName MEMBER_DETAILS, schema X STRING, Y STRING, Z
 STRING);

 INSERT OVERWRITE TABLE memberdetails select * from memberinfo;

 Here MEMBER_INFO - HBase database table, MEMBER_DETAILS - H2 database
 table

 When I use the Data Explorer to see records in table MEMBER_DETAILS,
 column order as specified in schema. But when I created a table gadget
 using the same table and added to dashboard, column order is not as in
 schema. But I think columns are in the order as in HBase database table.

 What I have to do to get the columns as in schema order?

 Thanks.

 --
 Thanuja Uruththirakodeeswaran
 Software Engineer
 WSO2 Inc.;http://wso2.com
 lean.enterprise.middleware

 mobile: +94 774363167

 ___
 Dev mailing list
 Dev@wso2.org
 http://wso2.org/cgi-bin/mailman/listinfo/dev




 --
 Gimantha Bandara
 Software Engineer
 WSO2. Inc : http://wso2.com
 Mobile : +94714961919




 --
 Thanuja Uruththirakodeeswaran
 Software Engineer
 WSO2 Inc.;http://wso2.com
 lean.enterprise.middleware

 mobile: +94 774363167



-- 
Gimantha Bandara
Software Engineer
WSO2. Inc : http://wso2.com
Mobile : +94714961919
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DAS] DAS dashboard table-gadget column order

2015-08-14 Thread Thanuja Uruththirakodeeswaran
Hi Gimantha,

I used external HBase DB and DAS embedded H2 DB. I checked with HBase table
and table-gadget column order same as HBase table. I tried with H2 table,
but I couldn't see column names as I think it was encrypted or something.
How can I check the column names in DAS embedded H2 database?

Thanks.

On Fri, Aug 14, 2015 at 1:28 PM, Gimantha Bandara giman...@wso2.com wrote:

 Hi Thanuja,
 Is it same with the H2 table or only the HBase analytics table?


 On Thu, Aug 13, 2015 at 6:50 PM, Thanuja Uruththirakodeeswaran 
 thanu...@wso2.com wrote:

 Hi,

 I've persisted a event stream in event store which is a HBase database.
 Then using the following query I created table in spark environment. Also I
 used H2 database as processed store.

 CREATE TEMPORARY TABLE memberinfo
 USING CarbonAnalytics
 OPTIONS (tableName MEMBER_INFO);

 CREATE TEMPORARY TABLE memberdetails
 USING CarbonAnalytics
 OPTIONS (tableName MEMBER_DETAILS, schema X STRING, Y STRING, Z
 STRING);

 INSERT OVERWRITE TABLE memberdetails select * from memberinfo;

 Here MEMBER_INFO - HBase database table, MEMBER_DETAILS - H2 database
 table

 When I use the Data Explorer to see records in table MEMBER_DETAILS,
 column order as specified in schema. But when I created a table gadget
 using the same table and added to dashboard, column order is not as in
 schema. But I think columns are in the order as in HBase database table.

 What I have to do to get the columns as in schema order?

 Thanks.

 --
 Thanuja Uruththirakodeeswaran
 Software Engineer
 WSO2 Inc.;http://wso2.com
 lean.enterprise.middleware

 mobile: +94 774363167

 ___
 Dev mailing list
 Dev@wso2.org
 http://wso2.org/cgi-bin/mailman/listinfo/dev




 --
 Gimantha Bandara
 Software Engineer
 WSO2. Inc : http://wso2.com
 Mobile : +94714961919




-- 
Thanuja Uruththirakodeeswaran
Software Engineer
WSO2 Inc.;http://wso2.com
lean.enterprise.middleware

mobile: +94 774363167
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev