Repository: lens Updated Branches: refs/heads/master 58d863643 -> b805ee989
http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/fact2.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/fact2.yaml b/lens-examples/src/test/resources/yaml/fact2.yaml new file mode 100644 index 0000000..97112c8 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/fact2.yaml @@ -0,0 +1,36 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + dim1: type: INT + dim3: type: INT + measure2: type: INT + measure3: type: FLOAT + measure4: type: FLOAT +properties: + cube.fact.is.aggregated: true +storageTables: + local: + updatePeriods: HOURLY, DAILY + tableDesc: + partCols: + dt: type: STRING, comment: Time column + timePartCols: dt + external: true + tableLocation: /tmp/examples/fact2_local + fieldDelimiter: , +name: fact2 +cubeName: sample_cube +weight: 200.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/local-cluster-storage.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/local-cluster-storage.yaml b/lens-examples/src/test/resources/yaml/local-cluster-storage.yaml new file mode 100644 index 0000000..e9f4ffe --- /dev/null +++ b/lens-examples/src/test/resources/yaml/local-cluster-storage.yaml @@ -0,0 +1,19 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +properties: + storage.url: hdfs://localhost:8020/ +name: cluster1 +classname: org.apache.lens.cube.metadata.HDFSStorage http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/local-storage.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/local-storage.yaml b/lens-examples/src/test/resources/yaml/local-storage.yaml new file mode 100644 index 0000000..4835fcb --- /dev/null +++ b/lens-examples/src/test/resources/yaml/local-storage.yaml @@ -0,0 +1,19 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +properties: + storage.url: file:/// +name: local +classname: org.apache.lens.cube.metadata.HDFSStorage http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/product-local-parts.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/product-local-parts.yaml b/lens-examples/src/test/resources/yaml/product-local-parts.yaml new file mode 100644 index 0000000..bd2c543 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/product-local-parts.yaml @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +partition: + - + nonTimePartitionSpec: + category: Clothes + timePartitionSpec: + dt: 2014-03-27T12:00:00 + factOrDimensionTableName: product_table + location: examples/data/product_local_clothes + updatePeriod: HOURLY + - + nonTimePartitionSpec: + category: Food + timePartitionSpec: + dt: 2014-03-27T12:00:00 + factOrDimensionTableName: product_table + location: examples/data/product_local_food + updatePeriod: HOURLY + - + nonTimePartitionSpec: + category: Stationary + timePartitionSpec: + dt: 2014-03-27T12:00:00 + factOrDimensionTableName: product_table + location: examples/data/product_local_stationary + updatePeriod: HOURLY + - + nonTimePartitionSpec: + category: Wearables + timePartitionSpec: + dt: 2014-03-27T12:00:00 + factOrDimensionTableName: product_table + location: examples/data/product_local_wearables + updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/product.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/product.yaml b/lens-examples/src/test/resources/yaml/product.yaml new file mode 100644 index 0000000..9133a3c --- /dev/null +++ b/lens-examples/src/test/resources/yaml/product.yaml @@ -0,0 +1,36 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +attributes: + id: type: INT + SKU_number: type: INT + description: type: STRING + color: type: STRING + weight: type: FLOAT + category: type: STRING + manufacturer: type: STRING +expressions: + isHeavy: + exprSpec: + - + expr: weight > 10 + endTime: 2015-04-12T00:00:00 + - + expr: weight > 50 + startTime: 2015-04-12T00:00:00 + type: boolean +properties: + dimension.product.timed.dimension: dt +name: product http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/product_db_table.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/product_db_table.yaml b/lens-examples/src/test/resources/yaml/product_db_table.yaml new file mode 100644 index 0000000..6b9461a --- /dev/null +++ b/lens-examples/src/test/resources/yaml/product_db_table.yaml @@ -0,0 +1,36 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + id: type: INT, comment: ID + SKU_number: type: INT, comment: SKU_number + description: type: STRING + color: type: STRING + category: type: STRING, comment: Category + weight: type: FLOAT + manufacturer: type: STRING +properties: + dim4.prop: d1 +storageTables: + mydb: + tableDesc: + tableParameters: + lens.metastore.native.db.name: default + external: true + tableLocation: /tmp/db-storage.db + storageHandlerName: org.apache.lens.storage.db.DBStorageHandler +dimensionName: product +tableName: product_db_table +weight: 100.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/product_table.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/product_table.yaml b/lens-examples/src/test/resources/yaml/product_table.yaml new file mode 100644 index 0000000..54d37d8 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/product_table.yaml @@ -0,0 +1,39 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + id: type: INT, comment: ID + SKU_number: type: INT, comment: SKU_number + description: type: STRING + color: type: STRING + weight: type: FLOAT + manufacturer: type: STRING +properties: + dim4.prop: d1 + dimtable.product_table.part.cols: category +storageTables: + local: + updatePeriods: HOURLY + tableDesc: + partCols: + dt: type: STRING, comment: Time column + category: type: STRING, comment: Category + timePartCols: dt + external: true + tableLocation: /tmp/examples/product + fieldDelimiter: , +dimensionName: product +tableName: product_table +weight: 100.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/raw-local-part1.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/raw-local-part1.yaml b/lens-examples/src/test/resources/yaml/raw-local-part1.yaml new file mode 100644 index 0000000..d41683f --- /dev/null +++ b/lens-examples/src/test/resources/yaml/raw-local-part1.yaml @@ -0,0 +1,20 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +timePartitionSpec: + dt: 2014-06-25T20:00:00 +factOrDimensionTableName: rawfact +location: examples/data/raw_local1 +updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/raw-local-part2.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/raw-local-part2.yaml b/lens-examples/src/test/resources/yaml/raw-local-part2.yaml new file mode 100644 index 0000000..e25cbd3 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/raw-local-part2.yaml @@ -0,0 +1,20 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +timePartitionSpec: + dt: 2014-06-25T21:00:00 +factOrDimensionTableName: rawfact +location: examples/data/raw_local2 +updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/raw-local-part3.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/raw-local-part3.yaml b/lens-examples/src/test/resources/yaml/raw-local-part3.yaml new file mode 100644 index 0000000..42091cd --- /dev/null +++ b/lens-examples/src/test/resources/yaml/raw-local-part3.yaml @@ -0,0 +1,20 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +timePartitionSpec: + dt: 2014-06-25T22:00:00 +factOrDimensionTableName: rawfact +location: examples/data/raw_local3 +updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/raw-local-part4.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/raw-local-part4.yaml b/lens-examples/src/test/resources/yaml/raw-local-part4.yaml new file mode 100644 index 0000000..38ccaf1 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/raw-local-part4.yaml @@ -0,0 +1,20 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +timePartitionSpec: + dt: 2014-06-25T23:00:00 +factOrDimensionTableName: rawfact +location: examples/data/raw_local4 +updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/raw-local-part5.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/raw-local-part5.yaml b/lens-examples/src/test/resources/yaml/raw-local-part5.yaml new file mode 100644 index 0000000..518d543 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/raw-local-part5.yaml @@ -0,0 +1,20 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +timePartitionSpec: + dt: 2014-06-26T00:00:00 +factOrDimensionTableName: rawfact +location: examples/data/raw_local5 +updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/raw-local-part6.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/raw-local-part6.yaml b/lens-examples/src/test/resources/yaml/raw-local-part6.yaml new file mode 100644 index 0000000..65c7870 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/raw-local-part6.yaml @@ -0,0 +1,20 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +timePartitionSpec: + dt: 2014-06-26T01:00:00 +factOrDimensionTableName: rawfact +location: examples/data/raw_local6 +updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/rawfact.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/rawfact.yaml b/lens-examples/src/test/resources/yaml/rawfact.yaml new file mode 100644 index 0000000..f750192 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/rawfact.yaml @@ -0,0 +1,38 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + dim1: type: INT + dim2: type: INT + dim3: type: INT + measure1: type: BIGINT + measure2: type: INT + measure3: type: FLOAT + measure4: type: FLOAT +properties: + cube.fact.is.aggregated: false +storageTables: + local: + updatePeriods: HOURLY, DAILY + tableDesc: + partCols: + dt: type: STRING, comment: Time column + timePartCols: dt + external: true + tableLocation: /tmp/examples/rawfact + fieldDelimiter: , +name: rawfact +cubeName: sample_cube +weight: 500.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-aggr-continuous-fact.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-aggr-continuous-fact.yaml b/lens-examples/src/test/resources/yaml/sales-aggr-continuous-fact.yaml new file mode 100644 index 0000000..0e98281 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-aggr-continuous-fact.yaml @@ -0,0 +1,45 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + order_time: type: TIMESTAMP + delivery_time: type: TIMESTAMP + customer_id: type: INT + product_id: type: INT + promotion_id: type: INT + customer_city_id: type: INT + production_city_id: type: INT + delivery_city_id: type: INT + unit_sales: type: BIGINT + store_sales: type: DOUBLE + store_cost: type: DOUBLE + max_line_item_price: type: FLOAT + max_line_item_discount: type: FLOAT +properties: + cube.fact.is.aggregated: true + cube.fact.relative.start.time: now.second - 2 days +storageTables: + mydb: + updatePeriods: CONTINUOUS + tableDesc: + tableParameters: + lens.metastore.native.db.name: default + external: true + tableLocation: /tmp/db-storage.db + fieldDelimiter: , + storageHandlerName: org.apache.lens.storage.db.DBStorageHandler +name: sales_aggr_continuous_fact +cubeName: sales +weight: 50.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-aggr-fact1-local-parts.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-aggr-fact1-local-parts.yaml b/lens-examples/src/test/resources/yaml/sales-aggr-fact1-local-parts.yaml new file mode 100644 index 0000000..6fae051 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-aggr-fact1-local-parts.yaml @@ -0,0 +1,40 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +partition: + - + timePartitionSpec: + pt: 2015-04-12T00:00:00 + ot: 2015-04-11T00:00:00 + dt: 2015-04-11T00:00:00 + factOrDimensionTableName: sales_aggr_fact1 + location: examples/data/sales_aggr_fact1_local1 + updatePeriod: DAILY + - + timePartitionSpec: + pt: 2015-04-13T00:00:00 + ot: 2015-04-12T00:00:00 + dt: 2015-04-12T00:00:00 + factOrDimensionTableName: sales_aggr_fact1 + location: examples/data/sales_aggr_fact1_local2 + updatePeriod: DAILY + - + timePartitionSpec: + pt: 2015-04-13T05:00:00 + ot: 2015-04-13T00:00:00 + dt: 2015-04-13T04:00:00 + factOrDimensionTableName: sales_aggr_fact1 + location: examples/data/sales_aggr_fact1_local3 + updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-aggr-fact1-mydb-parts.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-aggr-fact1-mydb-parts.yaml b/lens-examples/src/test/resources/yaml/sales-aggr-fact1-mydb-parts.yaml new file mode 100644 index 0000000..d18b9c9 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-aggr-fact1-mydb-parts.yaml @@ -0,0 +1,24 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +partition: + - + timePartitionSpec: + pt: 2015-04-13T00:00:00 + ot: 2015-04-12T00:00:00 + dt: 2015-04-12T00:00:00 + factOrDimensionTableName: sales_aggr_fact1 + location: /tmp/examples/data/sales_aggr_fact1_local2 + updatePeriod: DAILY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-aggr-fact1.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-aggr-fact1.yaml b/lens-examples/src/test/resources/yaml/sales-aggr-fact1.yaml new file mode 100644 index 0000000..0be8cf2 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-aggr-fact1.yaml @@ -0,0 +1,60 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + order_time: type: TIMESTAMP + delivery_time: type: TIMESTAMP + customer_id: type: INT + product_id: type: INT + promotion_id: type: INT + customer_city_id: type: INT + production_city_id: type: INT + delivery_city_id: type: INT + unit_sales: type: BIGINT + store_sales: type: DOUBLE + store_cost: type: DOUBLE + max_line_item_price: type: FLOAT + max_line_item_discount: type: FLOAT +properties: + cube.fact.is.aggregated: true +storageTables: + local: + updatePeriods: HOURLY, DAILY + tableDesc: + partCols: + pt: type: STRING, comment: Process time partition + ot: type: STRING, comment: Order time partition + dt: type: STRING, comment: Delivery time partition + timePartCols: pt, ot, dt + external: true + tableLocation: /tmp/examples/aggrfact1 + fieldDelimiter: , + mydb: + updatePeriods: DAILY + tableDesc: + partCols: + pt: type: STRING, comment: Process time partition + ot: type: STRING, comment: Order time partition + dt: type: STRING, comment: Delivery time partition + tableParameters: + lens.metastore.native.db.name: default + timePartCols: pt, ot, dt + external: true + tableLocation: /tmp/db-storage.db + fieldDelimiter: , + storageHandlerName: org.apache.lens.storage.db.DBStorageHandler +name: sales_aggr_fact1 +cubeName: sales +weight: 300.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-aggr-fact2-local-parts.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-aggr-fact2-local-parts.yaml b/lens-examples/src/test/resources/yaml/sales-aggr-fact2-local-parts.yaml new file mode 100644 index 0000000..5260a4d --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-aggr-fact2-local-parts.yaml @@ -0,0 +1,40 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +partition: + - + timePartitionSpec: + dt: 2015-04-11T00:00:00 + factOrDimensionTableName: sales_aggr_fact2 + location: examples/data/sales_aggr_fact2_local1 + updatePeriod: DAILY + - + timePartitionSpec: + dt: 2015-04-12T00:00:00 + factOrDimensionTableName: sales_aggr_fact2 + location: examples/data/sales_aggr_fact2_local2 + updatePeriod: DAILY + - + timePartitionSpec: + dt: 2015-04-13T04:00:00 + factOrDimensionTableName: sales_aggr_fact2 + location: examples/data/sales_aggr_fact2_local3 + updatePeriod: HOURLY + - + timePartitionSpec: + dt: 2015-04-13T05:00:00 + factOrDimensionTableName: sales_aggr_fact2 + location: examples/data/sales_aggr_fact2_local4 + updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-aggr-fact2-mydb-parts.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-aggr-fact2-mydb-parts.yaml b/lens-examples/src/test/resources/yaml/sales-aggr-fact2-mydb-parts.yaml new file mode 100644 index 0000000..99eaddc --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-aggr-fact2-mydb-parts.yaml @@ -0,0 +1,24 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +partition: + - + timePartitionSpec: + pt: 2015-04-13T00:00:00 + ot: 2015-04-12T00:00:00 + dt: 2015-04-12T00:00:00 + factOrDimensionTableName: sales_aggr_fact2 + location: /tmp/examples/data/sales_aggr_fact2_local2 + updatePeriod: DAILY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-aggr-fact2.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-aggr-fact2.yaml b/lens-examples/src/test/resources/yaml/sales-aggr-fact2.yaml new file mode 100644 index 0000000..d1ba7fb --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-aggr-fact2.yaml @@ -0,0 +1,56 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + order_time: type: TIMESTAMP + delivery_time: type: TIMESTAMP + product_id: type: INT + promotion_id: type: INT + customer_city_id: type: INT + production_city_id: type: INT + delivery_city_id: type: INT + unit_sales: type: BIGINT + store_sales: type: DOUBLE + store_cost: type: DOUBLE +properties: + cube.fact.is.aggregated: true + cube.timedim.relation.order_time: delivery_time+[-2 hours,-1hour] +storageTables: + local: + updatePeriods: HOURLY, DAILY + tableDesc: + partCols: + dt: type: STRING, comment: Delivery time partition + timePartCols: dt + external: true + tableLocation: /tmp/examples/aggrfact2 + fieldDelimiter: , + mydb: + updatePeriods: DAILY + tableDesc: + partCols: + pt: type: STRING, comment: Process time partition + ot: type: STRING, comment: Order time partition + dt: type: STRING, comment: Delivery time partition + tableParameters: + lens.metastore.native.db.name: default + timePartCols: pt, ot, dt + external: true + tableLocation: /tmp/db-storage.db + fieldDelimiter: , + storageHandlerName: org.apache.lens.storage.db.DBStorageHandler +name: sales_aggr_fact2 +cubeName: sales +weight: 100.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-cube.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-cube.yaml b/lens-examples/src/test/resources/yaml/sales-cube.yaml new file mode 100644 index 0000000..935e3f6 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-cube.yaml @@ -0,0 +1,110 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +properties: + cube.sales.timed.dimensions.list: order_time,delivery_time + cube.timedim.partition.order_time: ot + cube.timedim.partition.delivery_time: dt + cube.timedim.relation.order_time: delivery_time+[-20 days,-1 hour] +name: sales +measures: + Unit Sales(unit_sales): type: BIGINT, defaultAggr: SUM, formatString: #,### + Store Sales(store_sales): type: DOUBLE, defaultAggr: SUM, formatString: #,###.## + Store Cost(store_cost): + type: DOUBLE + defaultAggr: SUM + formatString: #,###.00 + startTime: 2015-03-01T00:00:00 + Line item quantity(line_item_quantity): type: INT, defaultAggr: SUM + Line item product price(line_item_product_price): type: FLOAT, defaultAggr: SUM + Line item discount(line_item_discount_amount): type: FLOAT, defaultAggr: SUM + Line item tax(line_item_tax): type: FLOAT, defaultAggr: SUM + Maximum Line item price(max_line_item_price): type: FLOAT, defaultAggr: MAX + Maximum Line item discount(max_line_item_discount): type: FLOAT, defaultAggr: MAX + Rating(rating): type: FLOAT, defaultAggr: AVG +dimAttributes: + customer_id: type: INT + product_id: type: INT + promotion_id: type: INT + order_id: type: INT + order_line_number: type: INT + order_time: type: TIMESTAMP + delivery_time: type: TIMESTAMP + customer_city_id: + type: INT + startTime: 2015-03-01T00:00:00 + production_city_id: type: INT + delivery_city_id: type: INT + Customer City(customer_city_name) [City name to which the customer belongs]: + chainRefColumn: + - + chainName: customer_city + refCol: name + type: string + production_location: + hierarchy: + Production City(production_city_name) [City name in which the product was produced]: + chainRefColumn: + - + chainName: production_city + refCol: name + type: STRING + Production State(production_state) [State name in which the product was produced]: type: STRING + Production Country(production_country) [Country name in which the product was produced]: type: STRING + Delivery City(delivery_city_name) [City name to which the product was delivered]: + chainRefColumn: + - + chainName: delivery_city + refCol: name + type: STRING +expressions: + Profit(profit): + exprSpec: + - + expr: store_sales - store_cost + type: DOUBLE + Promotion sales(promotion_sales): + exprSpec: + - + expr: sum(case when promotion_id = 0 then 0 else store_sales end) + startTime: 2015-04-12T00:00:00 + - + expr: sum(case when promotion_id = -1 then 0 when promotion_id = -1 then 0 else store_sales end) + endTime: 2015-04-12T00:00:00 + type: DOUBLE +joinChains: + customer_details: + paths: + - + sales.customer_id=customer.id + product_details: + paths: + - + sales.product_id=product.id + customer_city: + paths: + - + sales.customer_city_id=city.id + - + sales.customer_id=customer.id + customer.city_id=city.id + delivery_city: + paths: + - + sales.delivery_city_id=city.id + production_city: + paths: + - + sales.production_city_id=city.id http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-raw-fact.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-raw-fact.yaml b/lens-examples/src/test/resources/yaml/sales-raw-fact.yaml new file mode 100644 index 0000000..eaf7f15 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-raw-fact.yaml @@ -0,0 +1,50 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +columns: + order_time: type: TIMESTAMP + delivery_time: type: TIMESTAMP + customer_id: type: INT + product_id: type: INT + order_id: type: INT + promotion_id: type: INT + order_line_number: type: INT + customer_city_id: type: INT + production_city_id: type: INT + delivery_city_id: type: INT + unit_sales: type: BIGINT + store_sales: type: DOUBLE + store_cost: type: DOUBLE + line_item_quantity: type: INT + line_item_product_price: type: INT + line_item_discount_amount: type: INT + line_item_tax: type: INT +properties: + cube.fact.is.aggregated: false +storageTables: + local: + updatePeriods: HOURLY + tableDesc: + partCols: + pt: type: STRING, comment: Process time partition + ot: type: STRING, comment: Order time partition + dt: type: STRING, comment: Delivery time partition + timePartCols: pt, ot, dt + external: true + tableLocation: /tmp/examples/rawfact + fieldDelimiter: , +name: sales_raw_fact +cubeName: sales +weight: 500.0 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sales-raw-local-parts.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sales-raw-local-parts.yaml b/lens-examples/src/test/resources/yaml/sales-raw-local-parts.yaml new file mode 100644 index 0000000..2c64dd5 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sales-raw-local-parts.yaml @@ -0,0 +1,32 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +partition: + - + timePartitionSpec: + pt: 2015-04-13T05:00:00 + ot: 2015-04-13T00:00:00 + dt: 2015-04-13T04:00:00 + factOrDimensionTableName: sales_raw_fact + location: examples/data/sales_raw_local1 + updatePeriod: HOURLY + - + timePartitionSpec: + pt: 2015-04-13T06:00:00 + ot: 2015-04-13T01:00:00 + dt: 2015-04-13T05:00:00 + factOrDimensionTableName: sales_raw_fact + location: examples/data/sales_raw_local2 + updatePeriod: HOURLY http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sample-cube.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sample-cube.yaml b/lens-examples/src/test/resources/yaml/sample-cube.yaml new file mode 100644 index 0000000..3f2ffc0 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sample-cube.yaml @@ -0,0 +1,47 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +properties: + cube.sample_cube.timed.dimensions.list: dt +name: sample_cube +measures: + measure1: type: BIGINT + measure2: type: INT, defaultAggr: SUM + measure3: + type: FLOAT + defaultAggr: MAX + startTime: 2013-12-12T00:00:00 + measure4: type: DOUBLE, defaultAggr: MIN +dimAttributes: + dim1: type: INT + dim2: + type: INT + startTime: 2013-12-01T00:00:00 + dim3: type: INT +expressions: + expr_msr5: + exprSpec: + - + expr: measure3 + measure4 + startTime: 2013-12-12T00:00:00 + - + expr: measure3 + measure4 + 0.01 + endTime: 2013-12-12T00:00:00 + type: DOUBLE +joinChains: + sample_dim_chain: + paths: + - + sample_cube.dim3=sample_dim.id http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sample-db-only-dimension.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sample-db-only-dimension.yaml b/lens-examples/src/test/resources/yaml/sample-db-only-dimension.yaml new file mode 100644 index 0000000..e550881 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sample-db-only-dimension.yaml @@ -0,0 +1,32 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +attributes: + id: type: INT + name: type: STRING + detail: + type: STRING + startTime: 2013-12-01T00:00:00 + d2id: + type: INT + startTime: 2013-12-01T00:00:00 +joinChains: + sample_dim2_chain: + paths: + - + sample_db_dim.d2id=sample_dim2.id +properties: + dimension.sample_db_dim.timed.dimension: dt +name: sample_db_dim http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sample-dimension.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sample-dimension.yaml b/lens-examples/src/test/resources/yaml/sample-dimension.yaml new file mode 100644 index 0000000..f43f178 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sample-dimension.yaml @@ -0,0 +1,32 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +attributes: + id: type: INT + name: type: STRING + detail: + type: STRING + startTime: 2013-12-01T00:00:00 + d2id: + type: INT + startTime: 2013-12-01T00:00:00 +joinChains: + sample_dim2_chain: + paths: + - + sample_dim.d2id=sample_dim2.id +properties: + dimension.sample_dim.timed.dimension: dt +name: sample_dim http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-examples/src/test/resources/yaml/sample-dimension2.yaml ---------------------------------------------------------------------- diff --git a/lens-examples/src/test/resources/yaml/sample-dimension2.yaml b/lens-examples/src/test/resources/yaml/sample-dimension2.yaml new file mode 100644 index 0000000..e9dcb77 --- /dev/null +++ b/lens-examples/src/test/resources/yaml/sample-dimension2.yaml @@ -0,0 +1,24 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +attributes: + id: type: INT + name: type: STRING + detail2: + type: STRING + startTime: 2013-12-01T00:00:00 +properties: + dimension.sample_dim2.timed.dimension: dt +name: sample_dim2 http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-server/src/test/java/org/apache/lens/server/LensJerseyTest.java ---------------------------------------------------------------------- diff --git a/lens-server/src/test/java/org/apache/lens/server/LensJerseyTest.java b/lens-server/src/test/java/org/apache/lens/server/LensJerseyTest.java index a00a86b..fb757e4 100644 --- a/lens-server/src/test/java/org/apache/lens/server/LensJerseyTest.java +++ b/lens-server/src/test/java/org/apache/lens/server/LensJerseyTest.java @@ -261,6 +261,6 @@ public abstract class LensJerseyTest extends JerseyTest { } else if (mt.equals(MediaType.APPLICATION_XML_TYPE)) { return Entity.xml(o); } - return null; + return Entity.entity(o, mt); } } http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/lens-server/src/test/java/org/apache/lens/server/LensServerTestUtil.java ---------------------------------------------------------------------- diff --git a/lens-server/src/test/java/org/apache/lens/server/LensServerTestUtil.java b/lens-server/src/test/java/org/apache/lens/server/LensServerTestUtil.java index ddca12f..b651b79 100644 --- a/lens-server/src/test/java/org/apache/lens/server/LensServerTestUtil.java +++ b/lens-server/src/test/java/org/apache/lens/server/LensServerTestUtil.java @@ -100,7 +100,8 @@ public final class LensServerTestUtil { .get(LensQuery.class); QueryStatus stat = ctx.getStatus(); while (!stat.finished()) { - ctx = target.path(handle.toString()).queryParam("sessionid", lensSessionId).request(mt).get(LensQuery.class); + ctx = target.path(handle.toString()).queryParam("sessionid", lensSessionId).request(mt) + .get(LensQuery.class); stat = ctx.getStatus(); Thread.sleep(1000); } @@ -142,7 +143,8 @@ public final class LensServerTestUtil { .get(LensQuery.class); QueryStatus stat = ctx.getStatus(); while (!stat.finished()) { - ctx = target.path(handle.toString()).queryParam("sessionid", lensSessionId).request(mt).get(LensQuery.class); + ctx = target.path(handle.toString()).queryParam("sessionid", lensSessionId).request(mt) + .get(LensQuery.class); stat = ctx.getStatus(); Thread.sleep(1000); } @@ -211,7 +213,8 @@ public final class LensServerTestUtil { .get(LensQuery.class); QueryStatus stat = ctx.getStatus(); while (!stat.finished()) { - ctx = target.path(handle.toString()).queryParam("sessionid", lensSessionId).request(mt).get(LensQuery.class); + ctx = target.path(handle.toString()).queryParam("sessionid", lensSessionId).request(mt) + .get(LensQuery.class); stat = ctx.getStatus(); Thread.sleep(1000); } http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/pom.xml ---------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index bc81d81..b3afa59 100644 --- a/pom.xml +++ b/pom.xml @@ -92,6 +92,7 @@ <!-- maven plugins --> <jaxb2.plugin.version>0.13.0</jaxb2.plugin.version> <jaxb2.basics.plugin.version>0.9.5</jaxb2.basics.plugin.version> + <jaxb2.fluent.plugin.version>3.0</jaxb2.fluent.plugin.version> <jetty.plugin.version>${jetty.version}</jetty.plugin.version> <exec.plugin.version>1.2.1</exec.plugin.version> <enunciate.plugin.version>1.28</enunciate.plugin.version> http://git-wip-us.apache.org/repos/asf/lens/blob/b805ee98/src/site/apt/user/client-config.apt ---------------------------------------------------------------------- diff --git a/src/site/apt/user/client-config.apt b/src/site/apt/user/client-config.apt index 3d990a9..714db18 100644 --- a/src/site/apt/user/client-config.apt +++ b/src/site/apt/user/client-config.apt @@ -24,16 +24,18 @@ Lens client configuration *--+--+---+--+ |<<No.>>|<<Property Name>>|<<Default Value>>|<<Description>>| *--+--+---+--+ -|1|lens.client.dbname|default|Default lens database| +|1|lens.cli.json.pretty|false|Should CLI try to prettify the JSON of an object before priting.| *--+--+---+--+ -|2|lens.client.query.poll.interval|10|Interval at which query progress will be polled. Interval has to be given in milliseconds| +|2|lens.client.dbname|default|Default lens database| *--+--+---+--+ -|3|lens.client.requestfilter.ws.filter.impl|org.apache.lens.client.RequestFilter|Implementation class for Request Filter| +|3|lens.client.query.poll.interval|10|Interval at which query progress will be polled. Interval has to be given in milliseconds| *--+--+---+--+ -|4|lens.client.user.name|anonymous|Lens client user name| +|4|lens.client.requestfilter.ws.filter.impl|org.apache.lens.client.RequestFilter|Implementation class for Request Filter| *--+--+---+--+ -|5|lens.client.ws.request.filternames|requestfilter|These JAX-RS filters would be started in the specified order when lens-client starts| +|5|lens.client.user.name|anonymous|Lens client user name| *--+--+---+--+ -|6|lens.server.base.url|http://0.0.0.0:9999/lensapi|The base url for the lens server| +|6|lens.client.ws.request.filternames|requestfilter|These JAX-RS filters would be started in the specified order when lens-client starts| +*--+--+---+--+ +|7|lens.server.base.url|http://0.0.0.0:9999/lensapi|The base url for the lens server| *--+--+---+--+ The configuration parameters and their default values