Using a custom Commerce 2 Adjuster in a Craft Plugin I wrote a little commerce 2 price adjuster that works fine if i place it in 
/vendor/craftcms/commerce/src/adjusters/FriendsDiscountAdjuster.php and register it manually in /vendor/craftcms/commerce/src/services/OrderAdjustments.php 

However, i wanted to port it to a plugin, but i do fail registering the adjuster to commerce.

I placed the adjuster in my vendor/pluginName/src/adjusters/ folder 
and added it to my plugin. 

It fails with:
Cannot declare class craft\commerce\adjusters\FriendsDiscountAdjuster, because the name is already in use

this is my main plugin file Friendsdiscount.php:

&lt;?php
namespace hendrikeng\friendsdiscount;

use Craft;
use craft\base\Plugin;
use craft\services\Plugins;
use craft\events\PluginEvent;
use craft\commerce\services\OrderAdjustments;
use craft\events\RegisterComponentTypesEvent;
use hendrikeng\friendsdiscount\adjusters\FriendsDiscountAdjuster;

use yii\base\Event;

class Friendsdiscount extends Plugin
{
    public static $plugin;

    public $schemaVersion = '1.0.0';

    public function init()
    {
        parent::init();
        self::$plugin = $this;

        Event::on(
            OrderAdjustments::class,
            OrderAdjustments::EVENT_REGISTER_ORDER_ADJUSTERS,
            function(RegisterComponentTypesEvent $event) {
                $event-&gt;types[] = FriendsDiscountAdjuster::class;
            }
        );
    }
}


the src/adjusters/FriendDiscountAdjuster.php:

&lt;?php

namespace craft\commerce\adjusters;

use Craft;
use craft\commerce\base\AdjusterInterface;
use craft\commerce\elements\Order;
use craft\commerce\models\OrderAdjustment;
use craft\commerce\Plugin;

class FriendsDiscountAdjuster implements AdjusterInterface
{
  // ...Adjust something
}
the adjuster had the wrong namespace, changing it to:

namespace hendrikeng\friendsdiscount\adjusters

fixed the issue