diff options
author | Jon Bratseth <bratseth@yahoo-inc.com> | 2016-06-15 23:09:44 +0200 |
---|---|---|
committer | Jon Bratseth <bratseth@yahoo-inc.com> | 2016-06-15 23:09:44 +0200 |
commit | 72231250ed81e10d66bfe70701e64fa5fe50f712 (patch) | |
tree | 2728bba1131a6f6e5bdf95afec7d7ff9358dac50 /documentgen-test/etc |
Publish
Diffstat (limited to 'documentgen-test/etc')
-rw-r--r-- | documentgen-test/etc/complex/book.sd | 92 | ||||
-rw-r--r-- | documentgen-test/etc/complex/class.sd | 8 | ||||
-rw-r--r-- | documentgen-test/etc/complex/common.sd | 69 | ||||
-rw-r--r-- | documentgen-test/etc/complex/common2.sd | 9 | ||||
-rw-r--r-- | documentgen-test/etc/complex/music.sd | 70 | ||||
-rw-r--r-- | documentgen-test/etc/complex/music2.sd | 74 | ||||
-rw-r--r-- | documentgen-test/etc/complex/music3.sd | 8 | ||||
-rw-r--r-- | documentgen-test/etc/complex/music4.sd | 8 | ||||
-rw-r--r-- | documentgen-test/etc/complex/video.sd | 54 |
9 files changed, 392 insertions, 0 deletions
diff --git a/documentgen-test/etc/complex/book.sd b/documentgen-test/etc/complex/book.sd new file mode 100644 index 00000000000..56a9904ca8b --- /dev/null +++ b/documentgen-test/etc/complex/book.sd @@ -0,0 +1,92 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search book { + document book inherits common { + struct ss0 { + field s0 type string { } + field d0 type double { } + } + struct ss1 { + field s1 type string { } + field l1 type long { } + field i1 type int { } + field d1 type double { } + field as1 type array<string> { } + field al1 type array<long> { } + field ss01 type ss0 { } + } + struct ss2 { + field s21 type string { } + field ss02 type ss0 { } + } + field mystruct type ss1 { + + } + field mystruct2 type ss2 { + + } + field mywsfloat type weightedset<float> { + indexing: attribute + attribute: prefetch + } + field myarrayint type array<int> { + indexing: attribute + attribute: prefetch + } + field mytriplearray type array<array<array<int>>> { + + } + field stringmap type map<string, string> { + + } + field structmap type map<int, ss1> { + + } + field mysinglestructarray type array<ss1> { + + } + field author type string { + bolding: on + # index-to: default, author + indexing: summary | index + header + } + field isbn type string { + # index-to: default, isbn + indexing: summary | index + } + field year type int { + indexing: summary | index + } + field description type string { + # index-to: default, description + indexing: summary | index + summary: dynamic + body + } + field myraw type raw { + + } + } + field sw1 type float { + } + field didinteger type array<int> { + } + rank-profile default { + first-phase { + expression: nativeRank + } + } + rank-profile rp1 inherits default { + + } + rank-profile rp2 inherits default { + + } + field sw1 type float { + indexing: input weight * 6 + input w1 + input w2 | summary + } + field didinteger type array<int> { + indexing: input did | split " " | for_each { to_int } | attribute + } + +} diff --git a/documentgen-test/etc/complex/class.sd b/documentgen-test/etc/complex/class.sd new file mode 100644 index 00000000000..512acb18560 --- /dev/null +++ b/documentgen-test/etc/complex/class.sd @@ -0,0 +1,8 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search class { + document { + field classf type string { + + } + } +} diff --git a/documentgen-test/etc/complex/common.sd b/documentgen-test/etc/complex/common.sd new file mode 100644 index 00000000000..db4d920ea1c --- /dev/null +++ b/documentgen-test/etc/complex/common.sd @@ -0,0 +1,69 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search common { + document common { + field uri type string { + indexing: summary + } + field title type string { + bolding: on + # index-to: default, title + indexing: index|summary + summary-to: smallsum + body + } + field mid type int { + indexing: attribute|index|summary + } + field scorekey type string { + indexing: summary + } + field weight_src type float { + + } + field w1_src type float { + + } + field w2_src type float { + + } + field did type string { + indexing: attribute|index|summary + } + field ew type string { + indexing: index|summary + } + field content type raw { + body + } + annotation date { + field exacttime type long { } + } + annotation emptyannotation { } + annotation NodeImpl { } + annotation DocumentImpl { } + annotation NodeImplSub inherits NodeImpl { + field refToPovided type annotationreference<DocumentImpl> { } + } + annotation DocumentImplSub inherits DocumentImpl { } + } + field weight type float { + } + field w1 type float { + } + field w2 type float { + } + rank-profile default { + first-phase { + expression: nativeRank + } + } + field weight type float { + indexing: input weight_src * 10 | attribute | summary + } + field w1 type float { + indexing: input weight_src * 6 + input w1_src | summary + } + field w2 type float { + indexing: input w2_src + input weight_src | summary + } +} diff --git a/documentgen-test/etc/complex/common2.sd b/documentgen-test/etc/complex/common2.sd new file mode 100644 index 00000000000..54175e3cb44 --- /dev/null +++ b/documentgen-test/etc/complex/common2.sd @@ -0,0 +1,9 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search common2 { + document { + field com2 type string { + + } + } +} + diff --git a/documentgen-test/etc/complex/music.sd b/documentgen-test/etc/complex/music.sd new file mode 100644 index 00000000000..459e616c27d --- /dev/null +++ b/documentgen-test/etc/complex/music.sd @@ -0,0 +1,70 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search music { + document music inherits common { + field artist type string { + bolding: on + # index-to: default, artist + indexing: index|summary + } + field disp_song type string { + indexing: summary + } + field song type string { + # index-to: default, song + indexing: index + } + field isbn type string { + bolding: on + # index-to: default, isbn + indexing: index|summary + } + field year type int { + indexing: attribute|index|summary + } + annotation recordlabel {} + + annotation person { + field name type string { } + } + + annotation artist inherits person { + field instrument type int { } + } + + annotation place { + field lat type long { } + field lon type long { } + } + + annotation event { + field description type string { } + field person type annotationreference<person> { } + field date type annotationreference<date> { } + field place type annotationreference<place> { } + } + } + + field sw1 type float { + indexing { + input weight * 6 + input w1 + input w2 | summary; + } + } + + field didinteger type array<int> { + indexing: input did | split " " | attribute + } + + rank-profile default { + first-phase { + expression: nativeRank + } + } + rank-profile rp1 inherits default { + #static-rank: weight1 + } + rank-profile rp2 inherits default { + #static-rank: weight2 + } + + +} diff --git a/documentgen-test/etc/complex/music2.sd b/documentgen-test/etc/complex/music2.sd new file mode 100644 index 00000000000..722edf0c557 --- /dev/null +++ b/documentgen-test/etc/complex/music2.sd @@ -0,0 +1,74 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search music2 { + document music2 inherits common { + field artist type string { + bolding: on + # index-to: default, artist + indexing: index|summary + } + field disp_song type string { + indexing: summary + } + field song type string { + # index-to: default, song + indexing: index + } + field isbn type string { + bolding: on + # index-to: default, isbn + indexing: index|summary + } + field year type int { + indexing: attribute|index|summary + } + annotation recordlabel {} + + annotation person { + field name type string { } + } + + annotation artist inherits person { + field instrument type int { } + } + + annotation date { + field exacttime type long { } + } + + annotation place { + field lat type long { } + field lon type long { } + } + + annotation event { + field description type string { } + field person type annotationreference<person> { } + field date type annotationreference<date> { } + field place type annotationreference<place> { } + } + + } + + field sw1 type float { + indexing { + input weight * 6 + input w1 + input w2 | summary; + } + } + + field didinteger type array<int> { + indexing: input did | split " " | attribute + } + + rank-profile default { + first-phase { + expression: nativeRank + } + } + rank-profile rp1 inherits default { + #static-rank: weight1 + } + rank-profile rp2 inherits default { + #static-rank: weight2 + } + +} diff --git a/documentgen-test/etc/complex/music3.sd b/documentgen-test/etc/complex/music3.sd new file mode 100644 index 00000000000..c277266f0db --- /dev/null +++ b/documentgen-test/etc/complex/music3.sd @@ -0,0 +1,8 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search music3 { + document music3 inherits music2, common2 { + field mu3 type string { + + } + } +} diff --git a/documentgen-test/etc/complex/music4.sd b/documentgen-test/etc/complex/music4.sd new file mode 100644 index 00000000000..c272b62771f --- /dev/null +++ b/documentgen-test/etc/complex/music4.sd @@ -0,0 +1,8 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search music4 { + document music4 inherits music3 { + field mu4 type string { + + } + } +} diff --git a/documentgen-test/etc/complex/video.sd b/documentgen-test/etc/complex/video.sd new file mode 100644 index 00000000000..3106477b244 --- /dev/null +++ b/documentgen-test/etc/complex/video.sd @@ -0,0 +1,54 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +search video { + document video inherits common { + field director type string { + bolding: on + # index-to: default, director + indexing: index|summary + } + field disp_actor type string { + bolding: on + # index-to: default, disp_actor + indexing: index|summary + } + field actor type string { + bolding: on + # index-to: default, actor + indexing: index|summary + } + field fmt type string { + # index-to: default, fmt + indexing: index|summary + } + field isbn type string { + bolding: on + # index-to: default, isbn + indexing: index|summary + } + field year type int { + indexing: attribute|index|summary + } + } + + field sw1 type float { + indexing { + input weight * 6 + input w1 + input w2 | summary; + } + } + + field didinteger type array<int> { + indexing: input did | split " " | for_each { to_int } | attribute + } + + rank-profile default { + first-phase { + expression: nativeRank + } + } + rank-profile rp1 inherits default { + #static-rank: weight1 + } + rank-profile rp2 inherits default { + #static-rank: weight2 + } +} |