Advertisement
Guest User

Untitled

a guest
Mar 7th, 2016
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.50 KB | None | 0 0
  1.  
  2. indexer
  3. {
  4. }
  5.  
  6. searchd
  7. {
  8. listen = 127.0.0.1:9307:mysql41
  9. log = /vagrant/rlu/log/test.searchd.log
  10. query_log = /vagrant/rlu/log/test.searchd.query.log
  11. pid_file = /vagrant/rlu/log/test.sphinx.pid
  12. workers = threads
  13. binlog_path = /vagrant/rlu/tmp/binlog/test
  14. }
  15.  
  16. source answer_core_0
  17. {
  18. type = pgsql
  19. sql_host = localhost
  20. sql_user = developer
  21. sql_pass = developer
  22. sql_db = rlu_test
  23. sql_query_pre = SET TIME ZONE UTC
  24. sql_query = SELECT "answers"."id" * 8 + 0 AS "id", "answers"."body" AS "body", "users"."email" AS "author", "answers"."id" AS "sphinx_internal_id", 'Answer' AS "sphinx_internal_class", 0 AS "sphinx_deleted", "answers"."user_id" AS "user_id", extract(epoch from "answers"."created_at")::int AS "created_at", extract(epoch from "answers"."updated_at")::int AS "updated_at" FROM "answers" LEFT OUTER JOIN "users" ON "users"."id" = "answers"."user_id" WHERE ("answers"."id" BETWEEN $start AND $end) GROUP BY "answers"."id", "answers"."body", "users"."email", "answers"."id", "answers"."user_id", "answers"."created_at", "answers"."updated_at"
  25. sql_query_range = SELECT COALESCE(MIN("answers"."id"), 1), COALESCE(MAX("answers"."id"), 1) FROM "answers"
  26. sql_attr_uint = sphinx_internal_id
  27. sql_attr_uint = sphinx_deleted
  28. sql_attr_uint = user_id
  29. sql_attr_timestamp = created_at
  30. sql_attr_timestamp = updated_at
  31. sql_attr_string = sphinx_internal_class
  32. sql_field_string = author
  33. }
  34.  
  35. index answer_core
  36. {
  37. type = plain
  38. path = /vagrant/rlu/db/sphinx/test/answer_core
  39. docinfo = extern
  40. source = answer_core_0
  41. }
  42.  
  43. source comment_core_0
  44. {
  45. type = pgsql
  46. sql_host = localhost
  47. sql_user = developer
  48. sql_pass = developer
  49. sql_db = rlu_test
  50. sql_query_pre = SET TIME ZONE UTC
  51. sql_query = SELECT "comments"."id" * 8 + 1 AS "id", "comments"."body" AS "body", "users"."email" AS "author", "comments"."id" AS "sphinx_internal_id", 'Comment' AS "sphinx_internal_class", 0 AS "sphinx_deleted", "comments"."user_id" AS "user_id", extract(epoch from "comments"."created_at")::int AS "created_at", extract(epoch from "comments"."updated_at")::int AS "updated_at" FROM "comments" LEFT OUTER JOIN "users" ON "users"."id" = "comments"."user_id" WHERE ("comments"."id" BETWEEN $start AND $end) GROUP BY "comments"."id", "comments"."body", "users"."email", "comments"."id", "comments"."user_id", "comments"."created_at", "comments"."updated_at"
  52. sql_query_range = SELECT COALESCE(MIN("comments"."id"), 1), COALESCE(MAX("comments"."id"), 1) FROM "comments"
  53. sql_attr_uint = sphinx_internal_id
  54. sql_attr_uint = sphinx_deleted
  55. sql_attr_uint = user_id
  56. sql_attr_timestamp = created_at
  57. sql_attr_timestamp = updated_at
  58. sql_attr_string = sphinx_internal_class
  59. sql_field_string = author
  60. }
  61.  
  62. index comment_core
  63. {
  64. type = plain
  65. path = /vagrant/rlu/db/sphinx/test/comment_core
  66. docinfo = extern
  67. source = comment_core_0
  68. }
  69.  
  70. source question_core_0
  71. {
  72. type = pgsql
  73. sql_host = localhost
  74. sql_user = developer
  75. sql_pass = developer
  76. sql_db = rlu_test
  77. sql_query_pre = SET TIME ZONE UTC
  78. sql_query = SELECT "questions"."id" * 8 + 2 AS "id", "questions"."title" AS "title", "questions"."body" AS "body", "users"."email" AS "author", "questions"."id" AS "sphinx_internal_id", 'Question' AS "sphinx_internal_class", 0 AS "sphinx_deleted", "questions"."user_id" AS "user_id", extract(epoch from "questions"."created_at")::int AS "created_at", extract(epoch from "questions"."updated_at")::int AS "updated_at" FROM "questions" LEFT OUTER JOIN "users" ON "users"."id" = "questions"."user_id" WHERE ("questions"."id" BETWEEN $start AND $end) GROUP BY "questions"."id", "questions"."title", "questions"."body", "users"."email", "questions"."id", "questions"."user_id", "questions"."created_at", "questions"."updated_at"
  79. sql_query_range = SELECT COALESCE(MIN("questions"."id"), 1), COALESCE(MAX("questions"."id"), 1) FROM "questions"
  80. sql_attr_uint = sphinx_internal_id
  81. sql_attr_uint = sphinx_deleted
  82. sql_attr_uint = user_id
  83. sql_attr_timestamp = created_at
  84. sql_attr_timestamp = updated_at
  85. sql_attr_string = sphinx_internal_class
  86. sql_field_string = title
  87. sql_field_string = author
  88. }
  89.  
  90. index question_core
  91. {
  92. type = plain
  93. path = /vagrant/rlu/db/sphinx/test/question_core
  94. docinfo = extern
  95. source = question_core_0
  96. }
  97.  
  98. source user_core_0
  99. {
  100. type = pgsql
  101. sql_host = localhost
  102. sql_user = developer
  103. sql_pass = developer
  104. sql_db = rlu_test
  105. sql_query_pre = SET TIME ZONE UTC
  106. sql_query = SELECT "users"."id" * 8 + 3 AS "id", "users"."email" AS "author", "users"."id" AS "sphinx_internal_id", 'User' AS "sphinx_internal_class", 0 AS "sphinx_deleted", "users"."id" AS "user_id", extract(epoch from "users"."created_at")::int AS "created_at", extract(epoch from "users"."updated_at")::int AS "updated_at" FROM "users" WHERE ("users"."id" BETWEEN $start AND $end) GROUP BY "users"."id", "users"."email", "users"."id", "users"."id", "users"."created_at", "users"."updated_at"
  107. sql_query_range = SELECT COALESCE(MIN("users"."id"), 1), COALESCE(MAX("users"."id"), 1) FROM "users"
  108. sql_attr_uint = sphinx_internal_id
  109. sql_attr_uint = sphinx_deleted
  110. sql_attr_uint = user_id
  111. sql_attr_timestamp = created_at
  112. sql_attr_timestamp = updated_at
  113. sql_attr_string = sphinx_internal_class
  114. sql_field_string = author
  115. }
  116.  
  117. index user_core
  118. {
  119. type = plain
  120. path = /vagrant/rlu/db/sphinx/test/user_core
  121. docinfo = extern
  122. source = user_core_0
  123. }
  124.  
  125. index answer
  126. {
  127. type = distributed
  128. local = answer_core
  129. }
  130.  
  131. index comment
  132. {
  133. type = distributed
  134. local = comment_core
  135. }
  136.  
  137. index question
  138. {
  139. type = distributed
  140. local = question_core
  141. }
  142.  
  143. index user
  144. {
  145. type = distributed
  146. local = user_core
  147. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement