wolf_core 1.0.62 → 1.0.64

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f6bd213f59fcb6943c53b5f993a7b33ea688d708790fe416beab69e7c358b7d2
4
- data.tar.gz: dc2cabf5e0531065f425bb2f57a148f7466a2ccb6971908eff941a0edd0cb7d0
3
+ metadata.gz: 06d83447a855affde645405ba9475f0a44d6da3f88ffa519544bac6abdbb7882
4
+ data.tar.gz: 9ecec55c7d88a15df8dc64b69cbe127bdd1536781a40b0ea2f8b726be2f53eb4
5
5
  SHA512:
6
- metadata.gz: 947c404ac278b3cfd3d8594298459471e03cc71fe252cad3f33810995cd5f6185800f1d69d6f84fa842a2c4dd03701f3a2773b90878b87ac77d1c83640369a5d
7
- data.tar.gz: ae509caed9883708fc5c697075489aca827393684e34b94ca7b9834255d1f297a62b6331ed3c9017b4f2be5f376dfd1f18651ef8966cbc6aef22b1491c90d269
6
+ metadata.gz: 81a313e6ff35fb85c87a89c39baa3cb707bd9f3d65e11dd45a49c5759ba316b565189aad1f8a04aa8e7bfe46c0cd4dd086c1e21b8f9a602a0f6ab4834a43a2dd
7
+ data.tar.gz: 3369777bed8d92a35a936deed8266810db8ded505c131618d53625a306286a453af32b0572f192c6647aaf318c3c08e5a989bd733a4cc7b4c1f65e8c8d8b5abe
@@ -9,6 +9,7 @@ module WolfCore
9
9
  'barton/import/jobseeker' => 'BartonImportJobseeker',
10
10
  'barton/export/jobseeker' => 'BartonExportJobseeker',
11
11
  'barton/import/order' => 'BartonImportOrder',
12
+ 'barton-generate-job-description' => 'BartonGenerateJobDescription',
12
13
  'barton/export/order' => 'BartonExportOrder',
13
14
  'barton/import/order_description' => 'BartonImportOrderDescription',
14
15
  'barton/import/order_application' => 'BartonImportOrderApplication',
@@ -29,7 +30,7 @@ module WolfCore
29
30
  'barton/export/jobseeker_order_applications' => 'BartonExportJobseekerOrderApplications',
30
31
  }
31
32
 
32
- def route_event_request(path:, body:)
33
+ def route_event_request(path:, body:, invocation_type: nil)
33
34
  environment = ENV['ENVIRONMENT']
34
35
  deployable_envs = ['production', 'staging']
35
36
  if deployable_envs.include?(environment)
@@ -40,6 +41,7 @@ module WolfCore
40
41
  invoke_lambda(
41
42
  function_name: function_name,
42
43
  payload: body,
44
+ invocation_type: invocation_type,
43
45
  )
44
46
  else
45
47
  domain_url = ENV['CURRENT_SAM_URL']
@@ -23,12 +23,16 @@ module WolfCore
23
23
  def invoke(function_name:, payload:, invocation_type: nil)
24
24
  parsed_payload = JSON.generate(payload)
25
25
  invocation_type ||= 'Event'
26
- @@client.invoke({
26
+ # use invocation_type = 'Event' to make an asynchronous call
27
+ # use invocation_type = 'RequestResponse' to make a synchronous call
28
+ response = @@client.invoke({
27
29
  function_name: function_name,
28
30
  invocation_type: invocation_type,
29
31
  log_type: 'Tail',
30
32
  payload: parsed_payload
31
33
  })
34
+ return if invocation_type == 'Event'
35
+ JSON.parse(response.payload.string)
32
36
  end
33
37
  end
34
38
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module WolfCore
4
- VERSION = "1.0.62"
4
+ VERSION = "1.0.64"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wolf_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.62
4
+ version: 1.0.64
5
5
  platform: ruby
6
6
  authors:
7
7
  - Javier Roncallo
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-01-16 00:00:00.000000000 Z
11
+ date: 2025-01-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty