-
Notifications
You must be signed in to change notification settings - Fork 428
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
GraphQL - Implement last category #3651
Conversation
Codecov Report
@@ Coverage Diff @@
## feature/graphql #3651 +/- ##
===================================================
+ Coverage 81.88% 81.99% +0.10%
===================================================
Files 491 497 +6
Lines 33520 33548 +28
===================================================
+ Hits 27448 27507 +59
+ Misses 6072 6041 -31
Continue to review full report at Codecov.
|
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
724f896
to
01e22e7
Compare
This comment was marked as outdated.
This comment was marked as outdated.
01e22e7
to
f47b563
Compare
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
674d451
to
633f2d9
Compare
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
044ce30
to
2d3579d
Compare
This comment was marked as outdated.
This comment was marked as outdated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
|
||
format_deleted_users(Users) -> | ||
Users2 = [jid:to_binary(JID) || {JID, _} <- Users], | ||
io_lib:format("Deleted ~p users: ~p", [length(Users), Users2]). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this will print users with the ugly <<>>
.
This comment was marked as outdated.
This comment was marked as outdated.
ef11be8
to
549270f
Compare
This comment was marked as outdated.
This comment was marked as outdated.
Remove old users from the account admin resolver
Remove all tests using mod_last from the graphql_account_SUITE.
…guments Domain admin shouldn't be able to execute a query containing fields with optional domain arguments without providing them. Null domain argument means that the command should affect the global scope. Thus only global admin should be allowed to do it.
549270f
to
61a918c
Compare
small_tests_24 / small_tests / 61a918c small_tests_23 / small_tests / 61a918c dynamic_domains_pgsql_mnesia_23 / pgsql_mnesia / 61a918c dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / 61a918c dynamic_domains_mysql_redis_24 / mysql_redis / 61a918c muc_SUITE:hibernation:hibernated_room_can_be_queried_for_archive{error,{{assertion_failed,assert,is_groupchat_message,
[<<"Restorable message">>],
undefined,"undefined"},
[{escalus_new_assert,assert_true,2,
[{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_new_assert.erl"},
{line,84}]},
{muc_SUITE,wait_for_mam_result,3,
[{file,"/home/circleci/project/big_tests/tests/muc_SUITE.erl"},
{line,4383}]},
{muc_SUITE,'-hibernated_room_can_be_queried_for_archive/1-fun-0-',3,
[{file,"/home/circleci/project/big_tests/tests/muc_SUITE.erl"},
{line,4124}]},
{escalus_story,story,4,
[{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
{line,72}]},
{muc_SUITE,hibernated_room_can_be_queried_for_archive,1,
[{file,"/home/circleci/project/big_tests/tests/muc_SUITE.erl"},
{line,4120}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1783}]},
{test_server,run_test_case_eval1,6,
[{file,"test_server.erl"},{line,1292}]},
{test_server,run_test_case_eval,9,
[{file,"test_server.erl"},{line,1224}]}]}} dynamic_domains_mssql_mnesia_24 / odbc_mssql_mnesia / 61a918c ldap_mnesia_24 / ldap_mnesia / 61a918c internal_mnesia_24 / internal_mnesia / 61a918c ldap_mnesia_23 / ldap_mnesia / 61a918c elasticsearch_and_cassandra_24 / elasticsearch_and_cassandra_mnesia / 61a918c pgsql_mnesia_24 / pgsql_mnesia / 61a918c pgsql_mnesia_23 / pgsql_mnesia / 61a918c mysql_redis_24 / mysql_redis / 61a918c mssql_mnesia_24 / odbc_mssql_mnesia / 61a918c pep_SUITE:pep_tests:unsubscribe_after_presence_unsubscription{error,
{{badmatch,
[{xmlel,<<"message">>,
[{<<"from">>,
<<"alice_unsubscribe_after_presence_unsubscription_2084@localhost">>},
{<<"to">>,
<<"bob_unsubscribe_after_presence_unsubscription_2084@localhost/res1">>},
{<<"type">>,<<"headline">>}],
[{xmlel,<<"event">>,
[{<<"xmlns">>,
<<"http://jabber.org/protocol/pubsub#event">>}],
[{xmlel,<<"items">>,
[{<<"node">>,<<"q61Mq2tNkoes7jIf80BNpw==">>}],
[{xmlel,<<"item">>,
[{<<"id">>,<<"salmon">>}],
[{xmlel,<<"entry">>,
[{<<"xmlns">>,
<<"http://www.w3.org/2005/Atom">>}],
[]}]}]}]},
{xmlel,<<"headers">>,
[{<<"xmlns">>,<<"http://jabber.org/protocol/shim">>}],
[]}]}]},
[{pep_SUITE,'-unsubscribe_after_presence_unsubscription/1-fun-0-',2,
[{file,"/home/circleci/project/big_tests/tests/pep_SUITE.erl"},
{line,384}]},
{escalus_story,story,4,
[{file,
"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
{line,72}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1783}]},
{test_server,run_test_case_eval1,6,
[{file,"test_server.erl"},{line,1292}]},
{test_server,run_test_case_eval,9,
[{file,"test_server.erl"},{line,1224}]}]}} pep_SUITE:pep_tests:unsubscribe_after_presence_unsubscription{error,
{{badmatch,
[{xmlel,<<"message">>,
[{<<"from">>,
<<"alice_unsubscribe_after_presence_unsubscription_2098@localhost">>},
{<<"to">>,
<<"bob_unsubscribe_after_presence_unsubscription_2098@localhost/res1">>},
{<<"type">>,<<"headline">>}],
[{xmlel,<<"event">>,
[{<<"xmlns">>,
<<"http://jabber.org/protocol/pubsub#event">>}],
[{xmlel,<<"items">>,
[{<<"node">>,<<"SRCa/ATfc9d7PM2L2eBFIQ==">>}],
[{xmlel,<<"item">>,
[{<<"id">>,<<"salmon">>}],
[{xmlel,<<"entry">>,
[{<<"xmlns">>,
<<"http://www.w3.org/2005/Atom">>}],
[]}]}]}]},
{xmlel,<<"headers">>,
[{<<"xmlns">>,<<"http://jabber.org/protocol/shim">>}],
[]}]}]},
[{pep_SUITE,'-unsubscribe_after_presence_unsubscription/1-fun-0-',2,
[{file,"/home/circleci/project/big_tests/tests/pep_SUITE.erl"},
{line,384}]},
{escalus_story,story,4,
[{file,
"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
{line,72}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1783}]},
{test_server,run_test_case_eval1,6,
[{file,"test_server.erl"},{line,1292}]},
{test_server,run_test_case_eval,9,
[{file,"test_server.erl"},{line,1224}]}]}} riak_mnesia_24 / riak_mnesia / 61a918c mssql_mnesia_24 / odbc_mssql_mnesia / 61a918c |
This PR addresses MIM-1647 and adds the last category to the GraphQL API. Moreover, all the commends from the
account
category that needmod_last
to work were moved to thelast
category.The commands
list_old_users
,remove_old_users
andcount_active_users
take now a timestamp in ISO date-time format. All users with activity older than the given timestamp are considered old.Change in granting domain permissions
Domain admin shouldn't be able to execute a query containing fields with optional domain arguments without providing them.
null
domain argument means that the command should affect the global scope. Thus only global admin should be allowed to do it.