Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Add documentation for the query string #27

Merged
merged 10 commits into from
Feb 22, 2024
Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
use flake
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -116,4 +116,6 @@ helm-chart/renku-graph/charts/*tgz
# MAc
.DS_Store

.direnv/
.direnv/
*.qcow2
.tmp
44 changes: 33 additions & 11 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ lazy val root = project
.in(file("."))
.withId("renku-search")
.enablePlugins(DbTestPlugin)
.disablePlugins(RevolverPlugin)
.settings(
publish / skip := true,
publishTo := Some(
Expand Down Expand Up @@ -92,12 +93,12 @@ lazy val commons = project
}.taskValue
)
.enablePlugins(AutomateHeaderPlugin)
.disablePlugins(DbTestPlugin)
.disablePlugins(DbTestPlugin, RevolverPlugin)

lazy val http4sBorer = project
.in(file("modules/http4s-borer"))
.enablePlugins(AutomateHeaderPlugin)
.disablePlugins(DbTestPlugin)
.disablePlugins(DbTestPlugin, RevolverPlugin)
.withId("http4s-borer")
.settings(commonSettings)
.settings(
Expand All @@ -114,7 +115,7 @@ lazy val httpClient = project
.in(file("modules/http-client"))
.withId("http-client")
.enablePlugins(AutomateHeaderPlugin)
.disablePlugins(DbTestPlugin)
.disablePlugins(DbTestPlugin, RevolverPlugin)
.settings(commonSettings)
.settings(
name := "http-client",
Expand All @@ -141,6 +142,7 @@ lazy val redisClient = project
Dependencies.redis4CatsStreams
)
.enablePlugins(AutomateHeaderPlugin)
.disablePlugins(RevolverPlugin)
.dependsOn(
commons % "test->test"
)
Expand All @@ -157,6 +159,7 @@ lazy val renkuRedisClient = project
Dependencies.redis4CatsStreams
)
.enablePlugins(AutomateHeaderPlugin)
.disablePlugins(RevolverPlugin)
.dependsOn(
events % "compile->compile;test->test",
redisClient % "compile->compile;test->test"
Expand All @@ -166,6 +169,7 @@ lazy val solrClient = project
.in(file("modules/solr-client"))
.withId("solr-client")
.enablePlugins(AvroCodeGen, AutomateHeaderPlugin)
.disablePlugins(RevolverPlugin)
.settings(commonSettings)
.settings(
name := "solr-client",
Expand All @@ -183,22 +187,25 @@ lazy val searchSolrClient = project
.in(file("modules/search-solr-client"))
.withId("search-solr-client")
.enablePlugins(AvroCodeGen, AutomateHeaderPlugin)
.disablePlugins(RevolverPlugin)
.settings(commonSettings)
.settings(
name := "search-solr-client",
libraryDependencies ++=
Dependencies.catsCore ++
Dependencies.catsEffect
Dependencies.catsEffect ++
Dependencies.luceneQueryParser
)
.dependsOn(
avroCodec % "compile->compile;test->test",
solrClient % "compile->compile;test->test",
commons % "compile->compile;test->test"
commons % "compile->compile;test->test",
searchQuery % "compile->compile;test->test"
)

lazy val avroCodec = project
.in(file("modules/avro-codec"))
.disablePlugins(DbTestPlugin)
.disablePlugins(DbTestPlugin, RevolverPlugin)
.settings(commonSettings)
.settings(
name := "avro-codec",
Expand All @@ -210,7 +217,7 @@ lazy val avroCodec = project
lazy val http4sAvro = project
.in(file("modules/http4s-avro"))
.enablePlugins(AutomateHeaderPlugin)
.disablePlugins(DbTestPlugin)
.disablePlugins(DbTestPlugin, RevolverPlugin)
.withId("http4s-avro")
.settings(commonSettings)
.settings(
Expand All @@ -235,11 +242,12 @@ lazy val events = project
avroCodec % "compile->compile;test->test"
)
.enablePlugins(AutomateHeaderPlugin, AvroSchemaDownload)
.disablePlugins(DbTestPlugin)
.disablePlugins(DbTestPlugin, RevolverPlugin)

lazy val configValues = project
.in(file("modules/config-values"))
.withId("config-values")
.disablePlugins(RevolverPlugin)
.settings(commonSettings)
.settings(
name := "config-values",
Expand All @@ -255,6 +263,7 @@ lazy val configValues = project
lazy val searchQuery = project
.in(file("modules/search-query"))
.withId("search-query")
.disablePlugins(RevolverPlugin)
.settings(commonSettings)
.settings(
name := "search-query",
Expand All @@ -266,6 +275,18 @@ lazy val searchQuery = project
)
.enablePlugins(AutomateHeaderPlugin)

lazy val searchQueryDocs = project
.in(file("modules/search-query-docs"))
.withId("search-query-docs")
.dependsOn(searchQuery)
.enablePlugins(SearchQueryDocsPlugin)
.settings(
name := "search-query-docs",
publish := {},
publishLocal := {},
publishArtifact := false
)

lazy val searchProvision = project
.in(file("modules/search-provision"))
.withId("search-provision")
Expand All @@ -281,7 +302,7 @@ lazy val searchProvision = project
searchSolrClient % "compile->compile;test->test",
configValues % "compile->compile;test->test"
)
.enablePlugins(AutomateHeaderPlugin, DockerImagePlugin)
.enablePlugins(AutomateHeaderPlugin, DockerImagePlugin, RevolverPlugin)

lazy val searchApi = project
.in(file("modules/search-api"))
Expand All @@ -300,9 +321,10 @@ lazy val searchApi = project
commons % "compile->compile;test->test",
http4sBorer % "compile->compile;test->test",
searchSolrClient % "compile->compile;test->test",
configValues % "compile->compile;test->test"
configValues % "compile->compile;test->test",
searchQueryDocs % "compile->compile;test->test"
)
.enablePlugins(AutomateHeaderPlugin, DockerImagePlugin)
.enablePlugins(AutomateHeaderPlugin, DockerImagePlugin, RevolverPlugin)

lazy val commonSettings = Seq(
organization := "io.renku",
Expand Down
61 changes: 61 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

107 changes: 107 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/release-23.11";
flake-utils.url = "github:numtide/flake-utils";
};

outputs = inputs @ {
self,
nixpkgs,
flake-utils,
}:
{
overlays.default = final: prev: {
solr = self.packages.${prev.system}.solr;
};
nixosConfigurations = let
selfOverlay = {
lib,
config,
...
}: {
nixpkgs.overlays = [
self.overlays.default
];
system.stateVersion = "23.11";
};
in {
dev-vm = nixpkgs.lib.nixosSystem {
system = flake-utils.lib.system.x86_64-linux;
specialArgs = {inherit inputs;};
modules = [
selfOverlay
./nix/dev-vm.nix
];
};

container = nixpkgs.lib.nixosSystem {
system = flake-utils.lib.system.x86_64-linux;
modules = [
({pkgs, ...}: {
boot.isContainer = true;
networking.useDHCP = false;
})
selfOverlay
./nix/solr-module.nix
./nix/services.nix
];
};
};
}
// flake-utils.lib.eachDefaultSystem (system: let
pkgs = nixpkgs.legacyPackages.${system};
selfPkgs = self.packages.${system};
in {
formatter = pkgs.alejandra;
packages =
((import ./nix/dev-scripts.nix) {inherit (pkgs) concatTextFile writeShellScriptBin;})
// {
solr = pkgs.callPackage (import ./nix/solr.nix) {};
};

devShells = rec {
default = container;
container = pkgs.mkShell {
RS_SOLR_URL = "http://rsdev:8983/solr";
RS_REDIS_HOST = "rsdev";
RS_REDIS_PORT = "6379";
RS_CONTAINER = "rsdev";
RS_LOG_LEVEL = "3";

buildInputs = with pkgs;
with selfPkgs; [
redis
jq

redis-push
recreate-container
start-container
solr-create-core
solr-delete-core
solr-recreate-core
];
};
vm = pkgs.mkShell {
RS_SOLR_URL = "http://localhost:18983/solr";
RS_REDIS_HOST = "localhost";
RS_REDIS_PORT = "16379";
VM_SSH_PORT = "10022";
RS_LOG_LEVEL = "3";

buildInputs = with pkgs;
with selfPkgs; [
redis
jq

redis-push
vm-build
vm-run
vm-ssh
vm-solr-create-core
vm-solr-delete-core
vm-solr-recreate-core
];
};
};
});
}
Loading
Loading