Skip to content

Commit 7efc765

Browse files
committed
chore: review
1 parent 146454f commit 7efc765

File tree

6 files changed

+8
-7
lines changed

6 files changed

+8
-7
lines changed

templates/csharp/guides/ingestion/pushSetup.mustache

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,15 @@ using System.Collections.Generic;
55
{{> snippets/import}}
66

77
using Action = Algolia.Search.Models.Ingestion.Action;
8+
using PushTaskRecords = Algolia.Search.Models.Ingestion.PushTaskRecords;
89

910
class PushSetup
1011
{
1112
public static async Task Main(string[] args)
1213
{
1314
string jsonContent = File.ReadAllText("/my-raw-records.json");
1415
15-
var records = JsonSerializer.Deserialize<List<Algolia.Search.Models.Ingestion.PushTaskRecords>>(jsonContent);
16+
var records = JsonSerializer.Deserialize<List<PushTaskRecords>>(jsonContent);
1617
1718
// use the region matching your applicationID
1819
{{> snippets/init}}

templates/java/guides/ingestion/pushSetup.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public class pushSetup {
1616
RunResponse run = {{#dynamicSnippet}}pushSetup{{/dynamicSnippet}};
1717

1818
// use runID in the Observability debugger
19-
System.out.println(run);
19+
System.out.println(run.runID);
2020

2121
client.close();
2222
}

templates/php/guides/ingestion/pushSetup.mustache

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
require(__DIR__."/vendor/autoload.php");
33
{{> snippets/import}}
44

5-
$records = json_decode(file_get_contents("/my-raw-records.json");, true);
5+
$records = json_decode(file_get_contents("/my-raw-records.json"), true);
66

77
// use the region matching your applicationID
88
{{> snippets/init}}
99

10-
$run = {{#dynamicSnippet}}pushSetup{{/dynamicSnippet}}
10+
$run = {{#dynamicSnippet}}pushSetup{{/dynamicSnippet}};
1111

1212
// use runID in the Observability debugger
1313
print($run);

templates/python/guides/ingestion/pushSetup.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ async def main():
1313
run = {{#dynamicSnippet}}pushSetup{{/dynamicSnippet}}
1414

1515
# use runID in the Observability debugger
16-
print(run.to_dict()["runID"])
16+
print(run.run_id)
1717

1818
asyncio.run(main())

templates/ruby/guides/ingestion/pushSetup.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@ records = JSON.parse(File.read('/my-raw-records.json'))
99
run = {{#dynamicSnippet}}pushSetup{{/dynamicSnippet}}
1010

1111
# use runID in the Observability debugger
12-
puts(run)
12+
puts run.run_id

templates/scala/guides/ingestion/pushSetup.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ object PushSetup {
2727
)
2828

2929
// use runID in the Observability debugger
30-
println(run)
30+
println(run.runID)
3131
} catch {
3232
case e: Exception => println(e)
3333
}

0 commit comments

Comments
 (0)