Skip to content
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

Ts3 driver user sync issue when schedule runs policies job #17

Closed
frankfish1 opened this issue Sep 18, 2019 · 6 comments
Closed

Ts3 driver user sync issue when schedule runs policies job #17

frankfish1 opened this issue Sep 18, 2019 · 6 comments
Labels
bug Something isn't working

Comments

@frankfish1
Copy link

I'm having an issue when the schedule runs "seat-connector:apply:policies" discord user roles sync fine, ts3 user roles job fails. I encounter the same failed job when running the job manually via docker-compose exec seat-app sh -c 'php artisan seat-connector:apply:policies'

I can update ts3 identities via seat, ts3 settings save fine under connector > settings, I see in my ts3 server logs the connection via serverquery from seat-connector yet it always fails to sync users for ts3.

Warlof\Seat\Connector\Jobs\DriverApplyPolicies
ID 80730
Queue high
Tags connector, teamspeak
Failed At 19-09-18 15:09:27

ERROR: Symfony\Component\Debug\Exception\FatalThrowableError: Type error: Argument 1 passed to Warlof\Seat\Connector\Drivers\Teamspeak\Driver\TeamspeakSpeaker::addSet() must implement interface Warlof\Seat\Connector\Drivers\ISet, null given, called in /var/www/seat/vendor/warlof/seat-connector/src/Jobs/DriverApplyPolicies.php on line 227 in /var/www/seat/vendor/warlof/seat-teamspeak/src/Driver/TeamspeakSpeaker.php:134

STACK TRACE:
#0 /var/www/seat/vendor/warlof/seat-connector/src/Jobs/DriverApplyPolicies.php(227): Warlof\Seat\Connector\Drivers\Teamspeak\Driver\TeamspeakSpeaker->addSet(NULL)#1 /var/www/seat/vendor/warlof/seat-connector/src/Jobs/DriverApplyPolicies.php(160): Warlof\Seat\Connector\Jobs\DriverApplyPolicies->updateUserSets(Object(Warlof\Seat\Connector\Drivers\Teamspeak\Driver\TeamspeakSpeaker), Object(Warlof\Seat\Connector\Models\User), Array, Array)#2 /var/www/seat/vendor/warlof/seat-connector/src/Jobs/DriverApplyPolicies.php(114): Warlof\Seat\Connector\Jobs\DriverApplyPolicies->applyPolicy(Object(Warlof\Seat\Connector\Drivers\Teamspeak\Driver\TeamspeakSpeaker))#3 [internal function]: Warlof\Seat\Connector\Jobs\DriverApplyPolicies->handle()#4 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(29): call_user_func_array(Array, Array)#5 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(87): Illuminate\Container\BoundMethod::Illuminate\Container{closure}()#6 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(31): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))#7 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/Container.php(549): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)#8 /var/www/seat/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php(94): Illuminate\Container\Container->call(Array)#9 /var/www/seat/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(114): Illuminate\Bus\Dispatcher->Illuminate\Bus{closure}(Object(Warlof\Seat\Connector\Jobs\DriverApplyPolicies))#10 /var/www/seat/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(102): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline{closure}(Object(Warlof\Seat\Connector\Jobs\DriverApplyPolicies))#11 /var/www/seat/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php(98): Illuminate\Pipeline\Pipeline->then(Object(Closure))#12 /var/www/seat/vendor/laravel/framework/src/Illuminate/Queue/CallQueuedHandler.php(49): Illuminate\Bus\Dispatcher->dispatchNow(Object(Warlof\Seat\Connector\Jobs\DriverApplyPolicies), false)#13 /var/www/seat/vendor/laravel/framework/src/Illuminate/Queue/Jobs/Job.php(76): Illuminate\Queue\CallQueuedHandler->call(Object(Illuminate\Queue\Jobs\RedisJob), Array)#14 /var/www/seat/vendor/laravel/framework/src/Illuminate/Queue/Worker.php(320): Illuminate\Queue\Jobs\Job->fire()#15 /var/www/seat/vendor/laravel/framework/src/Illuminate/Queue/Worker.php(270): Illuminate\Queue\Worker->process('redis', Object(Illuminate\Queue\Jobs\RedisJob), Object(Illuminate\Queue\WorkerOptions))#16 /var/www/seat/vendor/laravel/framework/src/Illuminate/Queue/Worker.php(114): Illuminate\Queue\Worker->runJob(Object(Illuminate\Queue\Jobs\RedisJob), 'redis', Object(Illuminate\Queue\WorkerOptions))#17 /var/www/seat/vendor/laravel/framework/src/Illuminate/Queue/Console/WorkCommand.php(101): Illuminate\Queue\Worker->daemon('redis', 'high,medium,low...', Object(Illuminate\Queue\WorkerOptions))#18 /var/www/seat/vendor/laravel/framework/src/Illuminate/Queue/Console/WorkCommand.php(85): Illuminate\Queue\Console\WorkCommand->runWorker('redis', 'high,medium,low...')#19 /var/www/seat/vendor/laravel/horizon/src/Console/WorkCommand.php(46): Illuminate\Queue\Console\WorkCommand->handle()#20 [internal function]: Laravel\Horizon\Console\WorkCommand->handle()#21 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(29): call_user_func_array(Array, Array)#22 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(87): Illuminate\Container\BoundMethod::Illuminate\Container{closure}()#23 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(31): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))#24 /var/www/seat/vendor/laravel/framework/src/Illuminate/Container/Container.php(549): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)#25 /var/www/seat/vendor/laravel/framework/src/Illuminate/Console/Command.php(183): Illuminate\Container\Container->call(Array)#26 /var/www/seat/vendor/symfony/console/Command/Command.php(255): Illuminate\Console\Command->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))#27 /var/www/seat/vendor/laravel/framework/src/Illuminate/Console/Command.php(170): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))#28 /var/www/seat/vendor/symfony/console/Application.php(969): Illuminate\Console\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))#29 /var/www/seat/vendor/symfony/console/Application.php(255): Symfony\Component\Console\Application->doRunCommand(Object(Laravel\Horizon\Console\WorkCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))#30 /var/www/seat/vendor/symfony/console/Application.php(148): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))#31 /var/www/seat/vendor/laravel/framework/src/Illuminate/Console/Application.php(88): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))#32 /var/www/seat/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(121): Illuminate\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))#33 /var/www/seat/artisan(37): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))#34 {main}

@frankfish1
Copy link
Author

forgot to mention "seat-connector:sync:sets" works fine, only having issues with seat-connector:apply:policies

@warlof
Copy link
Owner

warlof commented Sep 18, 2019

Hi,

Can you tell me which version of seat-connector and teamspeak-connector driver are you using?

Your driver seems to be outdated

@frankfish1
Copy link
Author

| Vendor  | Package Name           | Installed Version |
| ------- | ---------------------- | ----------------- |
| warlof  | seat-connector         | 1.3.2             |
| warlof  | seat-discord-connector | 4.0.2             |
| warlof  | seat-teamspeak         | 4.1.1             |

@warlof
Copy link
Owner

warlof commented Sep 18, 2019

Does server groups loaded into SeAT match with those from teamspeak?
Did you check the log area? Do you have anything there related to a server group not found?

@frankfish1
Copy link
Author

frankfish1 commented Sep 18, 2019

I've resolved my issue. Yes everything matches TS <> SeAT, A Public Filter type Discord driver caused Teamspeak3 policies job to fail

Connector log::
  | Error | teamspeak | registration | Unable to retrieve Server Group with ID 591600000000000000
  | Error | teamspeak | registration | Unable to retrieve Server Group with ID 591600000000000000
  | Error | teamspeak | registration | Unable to retrieve Server Group with ID 591600000000000000

MariaDB:
| id | connector_type | connector_id | name | is_public |
| 10 | discord | 591600000000000000 | AAAA | 1 |

Server Group with ID 591600000000000000 is the Discord role ID of the above mentioned Public Filter. Once I removed the filter via access management, the next scheduled Teamspeak3 policies job completed and continues to work

@warlof warlof reopened this Sep 19, 2019
@warlof
Copy link
Owner

warlof commented Sep 19, 2019

Correct, there is a missing filter in the query.
Will be fixed in tonight hotfix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants