diff --git a/csharp/runner/SnippetRunner/Program.cs b/csharp/runner/SnippetRunner/Program.cs index ec7f529..ad20d99 100644 --- a/csharp/runner/SnippetRunner/Program.cs +++ b/csharp/runner/SnippetRunner/Program.cs @@ -263,7 +263,7 @@ SortedDictionary> snippetsMap string source = properties[sourceKey]; source = source.Trim(); Console.WriteLine("Adding data source: " + source); - config.AddDataSource(source); + config.RegisterDataSource(source); } string snippetConfig = config.Export(); diff --git a/csharp/snippets/configuration/README.md b/csharp/snippets/configuration/README.md index 5537d31..c921983 100644 --- a/csharp/snippets/configuration/README.md +++ b/csharp/snippets/configuration/README.md @@ -1,11 +1,12 @@ # Deleting Data -The configuration snippets outline how to modify the Senzing configuration, register the modified configuration with a configuration ID and update the default configuration ID for the repository. + +The configuration snippets outline how to modify the Senzing configuration, register the modified configuration with a configuration ID and update the default configuration ID for the repository. You may either `setDefaultConfigId()` or `replaceDefaultConfigId()`. Initially, the the default config ID must be set since there is no existing config ID to replace. However, when updating you may use `replaceDefaultConfigId()` to guard against race conditions of multiple threads or processes updating at the same time. ## Snippets -* **AddDataSources.java** - * Gets the current default config, creates a modified config with additional data sources, registers that modified config and then replaces the default config ID. -* **InitDefaultConfig.java** - * Initializes the repository with a default config ID using the template configuration provided by Senzing. +* **RegisterDataSources.java** + * Gets the current default config, creates a modified config with additional data sources, registers that modified config and then replaces the default config ID. +* **InitDefaultConfig.java** + * Initializes the repository with a default config ID using the template configuration provided by Senzing. diff --git a/csharp/snippets/configuration/AddDataSources/GlobalSuppressions.cs b/csharp/snippets/configuration/RegisterDataSources/GlobalSuppressions.cs similarity index 100% rename from csharp/snippets/configuration/AddDataSources/GlobalSuppressions.cs rename to csharp/snippets/configuration/RegisterDataSources/GlobalSuppressions.cs diff --git a/csharp/snippets/configuration/AddDataSources/Program.cs b/csharp/snippets/configuration/RegisterDataSources/Program.cs similarity index 95% rename from csharp/snippets/configuration/AddDataSources/Program.cs rename to csharp/snippets/configuration/RegisterDataSources/Program.cs index a94493a..1b674ea 100644 --- a/csharp/snippets/configuration/AddDataSources/Program.cs +++ b/csharp/snippets/configuration/RegisterDataSources/Program.cs @@ -48,7 +48,7 @@ // loop through the array and add each data source foreach (string dataSource in dataSources) { - config.AddDataSource(dataSource); + config.RegisterDataSource(dataSource); } // prepare an in-memory config to be modified and get the handle diff --git a/csharp/snippets/configuration/AddDataSources/AddDataSources.csproj b/csharp/snippets/configuration/RegisterDataSources/RegisterDataSources.csproj similarity index 100% rename from csharp/snippets/configuration/AddDataSources/AddDataSources.csproj rename to csharp/snippets/configuration/RegisterDataSources/RegisterDataSources.csproj diff --git a/csharp/snippets/information/CheckDatastorePerformance/CheckDatastorePerformance.csproj b/csharp/snippets/information/CheckRepositoryPerformance/CheckRepositoryPerformance.csproj similarity index 100% rename from csharp/snippets/information/CheckDatastorePerformance/CheckDatastorePerformance.csproj rename to csharp/snippets/information/CheckRepositoryPerformance/CheckRepositoryPerformance.csproj diff --git a/csharp/snippets/information/CheckDatastorePerformance/GlobalSuppressions.cs b/csharp/snippets/information/CheckRepositoryPerformance/GlobalSuppressions.cs similarity index 100% rename from csharp/snippets/information/CheckDatastorePerformance/GlobalSuppressions.cs rename to csharp/snippets/information/CheckRepositoryPerformance/GlobalSuppressions.cs diff --git a/csharp/snippets/information/CheckDatastorePerformance/Program.cs b/csharp/snippets/information/CheckRepositoryPerformance/Program.cs similarity index 91% rename from csharp/snippets/information/CheckDatastorePerformance/Program.cs rename to csharp/snippets/information/CheckRepositoryPerformance/Program.cs index 0ff6447..eddbdb2 100644 --- a/csharp/snippets/information/CheckDatastorePerformance/Program.cs +++ b/csharp/snippets/information/CheckRepositoryPerformance/Program.cs @@ -30,7 +30,7 @@ { SzDiagnostic diagnostic = env.GetDiagnostic(); - string result = diagnostic.CheckDatastorePerformance(SecondsToRun); + string result = diagnostic.CheckRepositoryPerformance(SecondsToRun); Console.WriteLine(result); diff --git a/csharp/snippets/information/GetDatastoreInfo/GetDatastoreInfo.csproj b/csharp/snippets/information/GetRepositoryInfo/GetRepositoryInfo.csproj similarity index 100% rename from csharp/snippets/information/GetDatastoreInfo/GetDatastoreInfo.csproj rename to csharp/snippets/information/GetRepositoryInfo/GetRepositoryInfo.csproj diff --git a/csharp/snippets/information/GetDatastoreInfo/GlobalSuppressions.cs b/csharp/snippets/information/GetRepositoryInfo/GlobalSuppressions.cs similarity index 100% rename from csharp/snippets/information/GetDatastoreInfo/GlobalSuppressions.cs rename to csharp/snippets/information/GetRepositoryInfo/GlobalSuppressions.cs diff --git a/csharp/snippets/information/GetDatastoreInfo/Program.cs b/csharp/snippets/information/GetRepositoryInfo/Program.cs similarity index 92% rename from csharp/snippets/information/GetDatastoreInfo/Program.cs rename to csharp/snippets/information/GetRepositoryInfo/Program.cs index 6c61f93..d88b6ac 100644 --- a/csharp/snippets/information/GetDatastoreInfo/Program.cs +++ b/csharp/snippets/information/GetRepositoryInfo/Program.cs @@ -30,7 +30,7 @@ { SzDiagnostic diagnostic = env.GetDiagnostic(); - string result = diagnostic.GetDatastoreInfo(); + string result = diagnostic.GetRepositoryInfo(); Console.WriteLine(result); diff --git a/csharp/snippets/information/README.md b/csharp/snippets/information/README.md index 6e9eff8..a45dac5 100644 --- a/csharp/snippets/information/README.md +++ b/csharp/snippets/information/README.md @@ -4,9 +4,9 @@ The information snippets outline the retrieval of different informational aspect ## Snippets -- **CheckDatastorePerformance** +- **CheckRepositoryPerformance** - Run an insert test against the Senzing repository to gauge performance -- **GetDatastoreInfo** +- **GetRepositoryInfo** - Return basic information about the Senzing repository(s) - **GetLicense** - Return the currently in use license details diff --git a/java/pom.xml b/java/pom.xml index 82901df..0a12f4a 100644 --- a/java/pom.xml +++ b/java/pom.xml @@ -18,7 +18,7 @@ com.senzing sz-sdk - 4.0.0-beta.3.0 + 4.0.0-beta.4.0 system ${SENZING_PATH}/er/sdk/java/sz-sdk.jar diff --git a/java/runner/java/com/senzing/runner/SnippetRunner.java b/java/runner/java/com/senzing/runner/SnippetRunner.java index 618788a..c53b600 100644 --- a/java/runner/java/com/senzing/runner/SnippetRunner.java +++ b/java/runner/java/com/senzing/runner/SnippetRunner.java @@ -187,7 +187,7 @@ public static void main(String[] args) { String source = properties.getProperty(sourceKey); source = source.trim(); System.out.println("Adding data source: " + source); - config.addDataSource(source); + config.registerDataSource(source); } String snippetConfig = config.export(); diff --git a/java/snippets/configuration/README.md b/java/snippets/configuration/README.md index ac8118e..c921983 100644 --- a/java/snippets/configuration/README.md +++ b/java/snippets/configuration/README.md @@ -6,7 +6,7 @@ You may either `setDefaultConfigId()` or `replaceDefaultConfigId()`. Initially, ## Snippets -* **AddDataSources.java** +* **RegisterDataSources.java** * Gets the current default config, creates a modified config with additional data sources, registers that modified config and then replaces the default config ID. * **InitDefaultConfig.java** * Initializes the repository with a default config ID using the template configuration provided by Senzing. diff --git a/java/snippets/configuration/AddDataSources.java b/java/snippets/configuration/RegisterDataSources.java similarity index 95% rename from java/snippets/configuration/AddDataSources.java rename to java/snippets/configuration/RegisterDataSources.java index c6baf19..8e583cc 100644 --- a/java/snippets/configuration/AddDataSources.java +++ b/java/snippets/configuration/RegisterDataSources.java @@ -6,7 +6,7 @@ /** * Provides a simple example of adding records to the Senzing repository. */ -public class AddDataSources { +public class RegisterDataSources { public static void main(String[] args) { // get the senzing repository settings String settings = System.getenv("SENZING_ENGINE_CONFIGURATION_JSON"); @@ -16,7 +16,7 @@ public static void main(String[] args) { } // create a descriptive instance name (can be anything) - String instanceName = AddDataSources.class.getSimpleName(); + String instanceName = RegisterDataSources.class.getSimpleName(); // initialize the Senzing environment SzEnvironment env = SzCoreEnvironment.newBuilder() @@ -44,7 +44,7 @@ public static void main(String[] args) { // loop through the array and add each data source for (String dataSource : dataSources) { - config.addDataSource(dataSource); + config.registerDataSource(dataSource); } // export the modified config to JSON text diff --git a/java/snippets/information/CheckDatastorePerformance.java b/java/snippets/information/CheckRepositoryPerformance.java similarity index 89% rename from java/snippets/information/CheckDatastorePerformance.java rename to java/snippets/information/CheckRepositoryPerformance.java index 1a482ff..c1675c5 100644 --- a/java/snippets/information/CheckDatastorePerformance.java +++ b/java/snippets/information/CheckRepositoryPerformance.java @@ -7,7 +7,7 @@ * Provides an example of checking database performance via the * diagnostic hub. */ -public class CheckDatastorePerformance { +public class CheckRepositoryPerformance { public static void main(String[] args) { // get the senzing repository settings String settings = System.getenv("SENZING_ENGINE_CONFIGURATION_JSON"); @@ -17,7 +17,7 @@ public static void main(String[] args) { } // create a descriptive instance name (can be anything) - String instanceName = CheckDatastorePerformance.class.getSimpleName(); + String instanceName = CheckRepositoryPerformance.class.getSimpleName(); // initialize the Senzing environment SzEnvironment env = SzCoreEnvironment.newBuilder() @@ -29,7 +29,7 @@ public static void main(String[] args) { try { SzDiagnostic diagnostic = env.getDiagnostic(); - String result = diagnostic.checkDatastorePerformance(SECONDS_TO_RUN); + String result = diagnostic.checkRepositoryPerformance(SECONDS_TO_RUN); System.out.println(result); diff --git a/java/snippets/information/GetDatastoreInfo.java b/java/snippets/information/GetRepositoryInfo.java similarity index 91% rename from java/snippets/information/GetDatastoreInfo.java rename to java/snippets/information/GetRepositoryInfo.java index f6373e5..dfe8211 100644 --- a/java/snippets/information/GetDatastoreInfo.java +++ b/java/snippets/information/GetRepositoryInfo.java @@ -7,7 +7,7 @@ * Provides an example of obtaining the datastore information * from the diagnostic hub. */ -public class GetDatastoreInfo { +public class GetRepositoryInfo { public static void main(String[] args) { // get the senzing repository settings String settings = System.getenv("SENZING_ENGINE_CONFIGURATION_JSON"); @@ -17,7 +17,7 @@ public static void main(String[] args) { } // create a descriptive instance name (can be anything) - String instanceName = GetDatastoreInfo.class.getSimpleName(); + String instanceName = GetRepositoryInfo.class.getSimpleName(); // initialize the Senzing environment SzEnvironment env = SzCoreEnvironment.newBuilder() @@ -29,7 +29,7 @@ public static void main(String[] args) { try { SzDiagnostic diagnostic = env.getDiagnostic(); - String result = diagnostic.getDatastoreInfo(); + String result = diagnostic.getRepositoryInfo(); System.out.println(result); diff --git a/java/snippets/information/README.md b/java/snippets/information/README.md index 11c2b95..1170a06 100644 --- a/java/snippets/information/README.md +++ b/java/snippets/information/README.md @@ -4,9 +4,9 @@ The information snippets outline the retrieval of different informational aspect ## Snippets -- **CheckDatastorePerformance.java** +- **CheckRepositoryPerformance.java** - Run an insert test against the Senzing repository to gauge performance -- **GetDatastoreInfo.java** +- **GetRepositoryInfo.java** - Return basic information about the Senzing repository(s) - **GetLicense.java** - Return the currently in use license details