arkaitzgarro/elastic-apm-laravel

View on GitHub

Showing 176 of 176 total issues

The parameter $transaction_name is not named in camelCase.
Open

    protected function stopTransaction(string $transaction_name, int $result): void
    {
        // Stop the transaction and measure the time
        $this->agent->stopTransaction($transaction_name, ['result' => $result]);
        $this->agent->collectEvents($transaction_name);
Severity: Minor
Found in src/Collectors/CommandCollector.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $transaction_name is not named in camelCase.
Open

    protected function stopTransaction(string $transaction_name, ?int $result): void
    {
        // Stop the transaction and measure the time
        $this->agent->stopTransaction($transaction_name, ['result' => (int) $result]);
        $this->agent->collectEvents($transaction_name);

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $event_counter is not named in camelCase.
Open

    final public function __construct(Application $app, Config $config, RequestStartTime $start_time, EventCounter $event_counter, EventClock $event_clock)
    {
        $this->app = $app;
        $this->config = $config;
        $this->start_time = $start_time;
Severity: Minor
Found in src/Collectors/EventDataCollector.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The property $start_time is not named in camelCase.
Open

class RecordTransaction
{
    protected $agent;
    protected $config;
    protected $start_time;
Severity: Minor
Found in src/Middleware/RecordTransaction.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

The property $start_time is not named in camelCase.
Open

abstract class EventDataCollector implements DataCollector
{
    /** @var Application */
    protected $app;

Severity: Minor
Found in src/Collectors/EventDataCollector.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

The property $event_clock is not named in camelCase.
Open

abstract class EventDataCollector implements DataCollector
{
    /** @var Application */
    protected $app;

Severity: Minor
Found in src/Collectors/EventDataCollector.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

The parameter $event_clock is not named in camelCase.
Open

    final public function __construct(Application $app, Config $config, RequestStartTime $start_time, EventCounter $event_counter, EventClock $event_clock)
    {
        $this->app = $app;
        $this->config = $config;
        $this->start_time = $start_time;
Severity: Minor
Found in src/Collectors/EventDataCollector.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $transaction_name is not named in camelCase.
Open

    protected function startTransaction(string $transaction_name): Transaction
    {
        return $this->agent->startTransaction(
            $transaction_name,
            [],
Severity: Minor
Found in src/Collectors/JobCollector.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $start_time is not named in camelCase.
Open

    public function __construct(float $start_time)
    {
        $this->start_time = $start_time;
    }
Severity: Minor
Found in src/Collectors/RequestStartTime.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $transaction_name is not named in camelCase.
Open

    public function collectEvents(string $transaction_name): void
    {
        $transaction = $this->getTransaction($transaction_name);
        $this->collectors->each(function ($collector) use ($transaction) {
            $collector->collect()->each(function ($measure) use ($transaction) {
Severity: Minor
Found in src/Agent.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $transaction_name is not named in camelCase.
Open

    protected function shouldIgnoreTransaction(string $transaction_name): bool
    {
        $pattern = $this->config->get('elastic-apm-laravel.transactions.ignorePatterns');

        return $pattern && preg_match($pattern, $transaction_name);
Severity: Minor
Found in src/Middleware/RecordTransaction.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $start_time is not named in camelCase.
Open

    public function __construct(Agent $agent, Config $config, RequestStartTime $start_time)
    {
        $this->agent = $agent;
        $this->config = $config;
        $this->start_time = $start_time;
Severity: Minor
Found in src/Middleware/RecordTransaction.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The property $app_config is not named in camelCase.
Open

class AgentBuilder extends NipwaayoniAgentBuilder
{
    /** @var Repository */
    private $app_config;

Severity: Minor
Found in src/AgentBuilder.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

The parameter $transaction_name is not named in camelCase.
Open

    protected function shouldIgnoreTransaction(string $transaction_name): bool
    {
        $pattern = $this->config->get('elastic-apm-laravel.transactions.ignorePatterns');

        return $pattern && preg_match($pattern, $transaction_name);
Severity: Minor
Found in src/Collectors/EventDataCollector.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $transaction_name is not named in camelCase.
Open

    protected function setTransactionType(string $transaction_name): void
    {
        $this->agent->getTransaction($transaction_name)->setMeta([
            'type' => 'job',
        ]);
Severity: Minor
Found in src/Collectors/JobCollector.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $transaction_name is not named in camelCase.
Open

    protected function addMetadata(string $transaction_name, Job $job): void
    {
        $this->agent->getTransaction($transaction_name)->setCustomContext([
            'job_id' => $job->getJobId(),
            'max_tries' => $job->maxTries(),
Severity: Minor
Found in src/Collectors/JobCollector.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The property $start_time is not named in camelCase.
Open

class StartMeasuring
{
    /** @var string */
    public $name;

Severity: Minor
Found in src/Events/StartMeasuring.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

The property $source_config_path is not named in camelCase.
Open

class ServiceProvider extends BaseServiceProvider
{
    public const COLLECTOR_TAG = 'event-collector';

    private $source_config_path = __DIR__ . '/../config/elastic-apm-laravel.php';
Severity: Minor
Found in src/ServiceProvider.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

The parameter $collector_class is not named in camelCase.
Open

    public function addCollector(string $collector_class): void
    {
        if ($this->is_agent_disabled) {
            return;
        }
Severity: Minor
Found in src/Services/ApmCollectorService.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The property $is_agent_disabled is not named in camelCase.
Open

class ApmCollectorService
{
    /**
     * @var Application
     */
Severity: Minor
Found in src/Services/ApmCollectorService.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

Severity
Category
Status
Source
Language