Issues (590)

src/Sharding/ShardChoserInterface.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace Bdf\Prime\Sharding;
4
5
/**
6
 * Choose a shard using a distribution value
7
 *
8
 * @template V as scalar
9
 */
10
interface ShardChoserInterface
11
{
12
    /**
13
     * Picks a shard for the given distribution value.
14
     *
15
     * @param V $distributionValue The distribution value
0 ignored issues
show
The type Bdf\Prime\Sharding\V was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
16
     * @param ShardingConnection $connection The sharding connection
17
     *
18
     * @return string  Returns the shard id to use
19
     */
20
    public function pick($distributionValue, ShardingConnection $connection): string;
21
}
22