Yaroslav Rogov
20904d867d
refactor: Rewrite pm_party reduce and merge in a generic fashion ( #8 )
...
* refactor: Rewrite pm_party reduce and merge in a generic fashion
* fix: Fix Selector struct checking
* refactor: Refactor generic code
* fix: Fix typos
* fix: Fix selector
* fix: Fix is_selector
* refactor: redo generic struct checking to case variant
* fix: Fix typo
* fix: Switch to more type-safe is_terms
* refactor: Move spec to appropriate place
* refactor: Switch to thrift reflection for is_predicate
* refactor: Add commect regarding is_terms impl
* refactor: remix merge_terms clauses
* refactor: Use new genlib_range
* fmt: Fix formatting
* ref: Refactor to type-driven generic implementation
* fix: Fix selector check
* fmt: Fix formatting
* Update apps/party_management/src/pm_party.erl
Co-authored-by: Andrew Mayorov <a.mayorov@rbkmoney.com>
* ref: Remove leftover
Co-authored-by: Andrew Mayorov <a.mayorov@rbkmoney.com>
2021-09-07 15:52:20 +03:00
Yaroslav Rogov
1431cc385e
ED-190/deps: Update dmt_client ( #4 )
...
* ED-190/deps: Update dmt_client
* ED-190/deps: Update dmt_client
* ED-190/fix: remove explicit dmt_client_cache update
* ED-190/deps: update dmt_client
* ED-190/fix: leftovers
* ED-190/fix: Fix commit ops and tests
* ED-190/refactor: fix formatting
* ED-190/refactor: fix formatting
2021-08-25 14:13:31 +03:00
yuri-bukhalenkov
9a8cd55d2d
updated damsel ( #10 )
2021-08-20 14:26:12 +03:00
Yaroslav Rogov
f161a8103b
ED-207/fix: Fix reduction of payment_system for payment_institution ( #9 )
2021-08-20 13:42:10 +03:00
Yaroslav Rogov
1496493835
feat: Add dictionaries and BinData support ( #7 )
...
* feat: Add dictionaries and BinData support
* ED-207/refactor(ternary): Remove with_defined, add docs and tests
* ED-207/fix: Return ternary_while for correct behaviour
* ED-207/deps: Update damsel for BinData
* ED-207/fix: Add reverse-compatibility to crypto-currency
* ED-207/test: Fix dialyzer error
* ED-207/fix: Fix varset decoding
* ED-207/refactor: minor refactoring
* ED-207/deps: Update wdeps deps
* ED-207/test: Add tests for dictionary payment methods
* ED-207/refactor: Fix dialyzer warnings
* Revert "ED-207/fix: Add reverse-compatibility to crypto-currency"
This reverts commit 56db16b9f5443e59e002a770df48c00467e067ea.
* ED-207/fix: Add clause for crypto cond version mismatch
* ED-207/refactor: Fix formatting
2021-08-19 13:49:12 +03:00
Andrew Mayorov
935c91235f
Fix msgpack unmarshalling over nil
s ( #6 )
2021-08-04 16:26:04 +03:00
yuri-bukhalenkov
45184ecf6e
Ed 97/feat/sync from hg ( #3 )
...
* * Adapt party machine transmutations facilities to support it
* Encode party state snapshots as thrift binary
* Avoid excessive party event decoding
* Removed pm_event_provider
* Fix get revision w/ empty index
* reduced calling machinegun to O(log(N)) while getting history
2021-06-28 15:46:02 +03:00
yuri-bukhalenkov
52f3bbe920
changed workdir according a wetkitty:service-erlang.sls.tpl ( #1 )
...
* changed workdir according a wetkitty:service-erlang.sls.tpl
* fixed: formatter
* used SERVICE_NAME variable to setup paths and docker image name
* fixed tests
2021-06-18 15:02:32 +03:00
Yuri Bukhalenkov
89139a5043
renamed service
2021-05-24 17:27:46 +03:00
Yuri Bukhalenkov
3a47946b40
removed unused functions in pm_ct_helper
2021-05-24 16:22:08 +03:00
Yuri Bukhalenkov
ea4db6cd79
removed unused pm_client_api parameter (root_url)
2021-05-24 16:12:03 +03:00
Yuri Bukhalenkov
9d0e765920
moved party_management to a separated microservice
2021-05-24 14:30:10 +03:00
Boris
db678139e8
ED-145: Handle exception ProvisionTermSetUndefined ( #565 )
2021-05-13 16:02:22 +03:00
George Belyakov
277a436440
ED-101: party management terms calculation ( #561 )
...
* add reduce_if_defined to reduce_provider in pm_provider
* check provider terminal terms reducing for both provider/terminal are undefined
* dialyzer
* format
* test try (throw instead of error)
* add test to undefined provider-terminal terms fix
* rework try/catch+assertMatch in compute_terminal_terms test
Co-authored-by: ndiezel0 <ndiezel0@gmail.com>
2021-04-28 14:53:01 +03:00
yuri-bukhalenkov
9f2e3a36e4
ED-135: removed global_ref param from pm_party_client:compute_globals ( #562 )
...
* updated damsel
* removed global_ref param from pm_party_client:compute_globals
* fixed review issue
2021-04-28 11:19:35 +03:00
Sergey Yelin
cf737ec445
ED-102: Update damsel ( #558 )
...
* ED-102: Update damsel
* Fix lint errors
* ED-102: Add new CryptoCurrency
* Remove unused create_from_method/1
* Remove unused test_condition/3
2021-04-06 15:14:02 +03:00
Boris
10d5ad74bc
merge PaymentsProvisionTerms.turnover_limits ( #553 )
2021-03-19 13:04:05 +03:00
dinama
f6fef9983c
upgrade: +image +deps +endpoints ( #535 )
2021-01-31 17:39:04 +03:00
dinama
108f39c88d
+upgrade all +fix after upgrade ( #531 )
2020-12-24 12:12:05 +03:00
Andrew Mayorov
a64217d9b3
Avoid warnings spam w/ incompatible cash ranges ( #516 )
...
Prefer to return well-specified error tuple instead.
Also Bump invoice lifetimes up in customer tests.
2020-12-04 17:27:30 +03:00
George Belyakov
aabb57ab14
hitch up all routing rules damsel changes ( #507 )
2020-11-16 10:55:56 +03:00
Toporkov Igor
241c870fd0
HG-555: Refactor PM ComputeShopTerms ( #498 )
...
* Hadle varset that might be sent in future
* Leave a comment about the migration process
* Update damsel & party_client
* Use party_client to call PM, add Varset to ComputeShopTerms args
* Add Varset to pm_client and tests
* Use Varset in party management
2020-11-15 22:45:09 +03:00
Sergey Yelin
044076c404
Add risk coverage to provider ( #505 )
...
* Add risk_coverage handling
* Pass RiskScore to provider acceptor
* Make risk coverage selector optional
* Remove dead code
* Add tests for routing
* Routing tests cleanup
* Fix dialyzer
* Localize varset/0 type
* Formatting
* Remove comment
* Add tests to rule sets
* Make provider cover operation with lower risk score
* Rewrite risk compirision logic
* Formatting
* Update dominant
2020-11-12 17:29:09 +03:00
Roman Pushkov
3ba836ffb5
HG-560: routing with pm ( #495 )
...
* add collect routes handler
* add compute provider handling
* remove collect routes handler
* add faulty config test
* return undefined cash range check result
* fix logger call
* run fmt
2020-11-12 11:18:16 +03:00
Toporkov Igor
adfe44a84b
Revert "Revert "HG-555: update ComputeShopTerms clients ( #497 )" ( #503 )" ( #504 )
...
This reverts commit 72f6fd5c3d9800b2e1bda1bf5e273edac8d7e72c.
2020-11-09 13:50:16 +03:00
Toporkov Igor
1b113aa752
Revert "HG-555: update ComputeShopTerms clients ( #497 )" ( #503 )
...
This reverts commit 9a8ad47008752b8af573ce8bcaa784377650e082.
2020-11-05 12:09:36 +03:00
Toporkov Igor
0ba6ce3736
HG-555: update ComputeShopTerms clients ( #497 )
...
* Hadle varset that might be sent in future
* Leave a comment about the migration process
* Update damsel & party_client
* Use party_client to call PM, add Varset to ComputeShopTerms args
* Add Varset to pm_client and tests
2020-10-30 14:54:58 +03:00
Toporkov Igor
8469a2995d
HG-555: Handle Varset in ComputeShopTerms ( #496 )
...
* Hadle varset that might be sent in future
* Leave a comment about the migration process
2020-10-30 11:58:59 +03:00
ndiezel0
9849c12150
HG-557: Add logging of cache hit/miss ( #489 )
2020-10-19 16:11:16 +03:00
ndiezel0
e9893dcc43
HG-452: Add caching for Checkout Party ( #487 )
...
* HG-452: Add caching for Checkout Party
* HG-452: Fix dialyzer
* HG-452: Format
* HG-452: Make cache work
* HG-452: Review fix
* HG-452: Fix specs
* HG-452: Review fix
* HG-452: Fix
* HG-452: Review fix
* HG-452: Format
2020-10-16 13:41:47 +03:00
Toporkov Igor
5eed85e519
HG-547: Validate cash register claims ( #484 )
...
* Assert cash registry-assosiated shop exists in party or could claimed to be created
* Filter out cash register shopIDs
* Test new validation
* Fix typo in test case name, fix missing space
* Always check cash register claims
* Fix cash register spelling
* Format code using erlfmt
* Use sets instead of lists
* Move cash_register claims validation to pm_claim_committer
2020-10-13 14:31:57 +03:00
ndiezel0
351b790873
HG-452: Fixed party_management ( #483 )
...
* HG-452: Fixed party_management
* HG-452: Add pm_varset and encode_decode test
* HG-452: Fix merge
* HG-452: Formatter
2020-09-28 12:37:41 +03:00
Andrey Fadeev
8093d04623
Try erlfmt ( #479 )
...
Co-authored-by: Sergey Yelin <elinsn@gmail.com>
2020-09-25 18:14:03 +03:00
Sergey Yelin
52967bd114
Update woody ( #482 )
...
* Revert "Update woody and fix backward clock error (#478 )"
This reverts commit 7ee4679b1ec5954962a00b4eb84108d2274dd0ba.
* Update woody and fix backward clock error (#478 )
* Fully embrace new woody args-are-tuples convention (#480 )
* Remove HG-542 revert artefact
Co-authored-by: ndiezel0 <ndiezel0@gmail.com>
Co-authored-by: Andrew Mayorov <a.mayorov@rbkmoney.com>
2020-09-18 19:18:59 +03:00
Sergey Yelin
6588cefb0f
Revert HG-452 ( #481 )
...
* Revert "Fully embrace new woody args-are-tuples convention (#480 )"
This reverts commit d95579a0d7817e2bbb93797ee6567a80063978e1.
* Revert "HG-452: Fix pm_ruleset (#477 )"
This reverts commit 6f4433bdc789b2e65590621ed8af69f331b1fd95.
* Revert "Update woody and fix backward clock error (#478 )"
This reverts commit 7ee4679b1ec5954962a00b4eb84108d2274dd0ba.
* Revert "HG-452: Add pm methods usage (#443 )"
This reverts commit 3a9142df3ba8b43433e099655a6b5a3ec4c9fd82.
2020-09-18 16:57:01 +03:00
Andrew Mayorov
8d55ad9bda
Fully embrace new woody args-are-tuples convention ( #480 )
2020-09-17 11:45:53 +03:00
Sergey Yelin
dcfbbaee96
Add missing claim ( #476 )
...
* Add missing claim
* Fix name
* Filter out unsupported event
* Remove dead code
* Simplify filter
* Do not generate events to claim with empty changeset
* Filter out claim_modification
* Leave cash_register_modification_unit for further desisions
* Cleanup
2020-09-14 18:49:59 +03:00
ndiezel0
76b759568b
HG-452: Fix pm_ruleset ( #477 )
...
* HG-452: Fix pm_ruleset
* HG-452: Revert ComputeGlobals
* HG-452: Slim down PR
* HG-452: Remove compute_globals
* HG-452: Remove unneeded reduce_payment_routing_decisions/3 clause
2020-09-11 13:11:35 +03:00
ndiezel0
02b39461c4
Update woody and fix backward clock error ( #478 )
2020-09-10 17:58:12 +03:00
ndiezel0
470a39a76d
HG-452: Add pm methods usage ( #443 )
...
* HG-452: Add compute payment institution to hellgate
* HG-452: Fix marshalling
* HG-452: Add ComputePaymentInstitution implementation
* HG-452: Fix payment_institution tests
* HG-452: Fix lint
* HG-452: Fix marshalling error
* HG-452: Fix tests
* HG-452: Add compute_contract_terms use
* HG-452: Add compute_contract_terms more use
* HG-452: Fix dialyzer
* HG-452: Update Provider
* HG-452: Remove compute p2p and withdrawal provider methods
* HG-452: Update party client
* HG-452: Add eunit test to selector
* HG-452: Fix tests
* HG-452: Review fix
* HG-452: Review fix
* Update apps/hellgate/src/hg_invoice_payment.erl
Co-authored-by: Andrey Fadeev <me@ciiol.net>
* HG-452: Review fix
* HG-452: Remove CreatedAt
Co-authored-by: Andrey Fadeev <me@ciiol.net>
2020-09-07 16:16:34 +03:00
ndiezel0
118ff48698
HG-452: Implement ComputeGlobals and ComputePaymentRoutingRuleset ( #466 )
...
* HG-452: Update Varset
* HG-452: Add ComputeGlobals and ComputePaymentRoutingRuleset implementation
* HG-452: Fix tests
* HG-452: Fix test
* HG-452: Fix dominant config in party test
* HG-452: Fix lint
* HG-452: Fix xref and tests
* Update apps/party_management/src/pm_party_handler.erl
Co-authored-by: Andrey Fadeev <me@ciiol.net>
* HG-452: Review fix
* HG-452: Update damsel
* Update apps/party_management/test/pm_party_tests_SUITE.erl
Co-authored-by: Andrey Fadeev <me@ciiol.net>
* HG-452: Add WRONG_DMT_OBJ_ID macro to pm tests
* HG-452: Add tests
* HG-452: Fix order
Co-authored-by: Andrey Fadeev <me@ciiol.net>
2020-08-07 16:02:02 +03:00
Toporkov Igor
a5d17b2b12
DC-127: Payment methods refactoring ( #445 )
...
* Use corresponding epic damsel branch
* Bump dominant
* Migrate to new bank_card payment method representation
* Simplify guard clause
Co-authored-by: Andrew Mayorov <a.mayorov@rbkmoney.com>
* Delete invalid clauses in hg_payment_tool:get_method/1
* Remove marshaling that we don't use anymore
* Correctly unmarshal tokenization_method
* Revert "Correctly unmarshal tokenization_method"
This reverts commit 6f14eefd003e3f80d087db97ca63c4ccc85152d8.
* Do not unmarshal tokenization_method because it will never be there
* Use old (_deprecated) payment methods
* Replace has_cvv with is_cvv_empty
* Upgrade damsel
* Delete outdated comentaries
* Return ordset of payment methods
* Upgrade dominant
* Upgrade damsel
* Add tokenization_method to bank_card_deprecated
* Rename function in hg_payment_tool, create function to test if payment method is supported
* Simpilfy and rename payment methods matching
* Export hg_payment_tool:get_possible_methods/1
* Upgrade damsel
* Fix mising old bank card reference
* Bump dominant
* Fix construct_payment_method
* Upgrade deps
* Suffix with _derprecated payment methods
* Bulk update deps
* Mark deprecated pms introduced by merge
Co-authored-by: Andrew Mayorov <a.mayorov@rbkmoney.com>
2020-07-29 15:02:00 +03:00
Toporkov Igor
e91f750852
DC-122: Remove risk_coverage from Terminal ( #459 )
...
* Hard remove all risk_coverage-related code
* Upgrade dominant
* Remove risk_coverage from test terminals, rework routing tests so they pass
* Fix merge artifact
* Kek
* Remove outdated comment
* Improve test readability
* Delete trailing whitespaces
2020-07-14 16:40:04 +03:00
ndiezel0
f37f198ae9
HG-452: Update party_managements methods and tests ( #460 )
2020-07-10 16:54:31 +03:00
Andrey Fadeev
d119f39248
MSPF-561 Add new provider terms usage ( #454 )
2020-07-06 10:58:37 +03:00
Andrey Fadeev
200a93fcba
MSPF-561 Update damsel ( #455 )
...
* Update damsel
* Reduce tests flapping
* Make eventsink test suite a bit more stable
2020-06-30 17:51:13 +03:00
Andrew Mayorov
90d28c6b12
DC-120: Implement criteria in predicates ( #453 )
...
See rbkmoney/damsel#582
2020-06-23 17:00:46 +03:00
Sergey Yelin
e4ee77b3fb
P2C-8: Add attempt_limit ( #452 )
...
* P2C-8: Add attempt_limit
* Add missing merge
* Fix order
2020-06-22 18:21:22 +03:00
Toporkov Igor
d1d957e047
DC-126: Add tokenization_method field ( #449 )
...
* Support tokenization_method field and condition
* Split very long line
* Threat none same as undefined when comparing tokenization methods
* Allow whatever payment method if condition is undefined
* Handle undefined tokenization method with defined tokenization method condition
2020-06-17 09:59:23 +03:00
Boris
1e57bd4674
MSPF-562: Add bank card category, condition category_is ( #448 )
2020-06-11 17:17:05 +03:00