Code Duplication    Length = 25-26 lines in 2 locations

Command/IndexExportCommand.php 1 location

@@ 28-52 (lines=25) @@
25
    /**
26
     * {@inheritdoc}
27
     */
28
    protected function configure()
29
    {
30
        parent::configure();
31
32
        $this
33
            ->setName(self::NAME)
34
            ->setDescription('Exports a data from the ElasticSearch index.')
35
            ->addArgument(
36
                'filename',
37
                InputArgument::REQUIRED,
38
                'Define a filename to store the output'
39
            )->addOption(
40
                'chunk',
41
                null,
42
                InputOption::VALUE_REQUIRED,
43
                'Chunk size to use in the scan api',
44
                500
45
            )->addOption(
46
                'split',
47
                null,
48
                InputOption::VALUE_REQUIRED,
49
                'Split a file content in a separate parts if a line number exceeds provided value',
50
                300000
51
            );
52
    }
53
54
    /**
55
     * {@inheritdoc}

Command/IndexImportCommand.php 1 location

@@ 27-52 (lines=26) @@
24
    /**
25
     * {@inheritdoc}
26
     */
27
    protected function configure()
28
    {
29
        parent::configure();
30
31
        $this
32
            ->setName(self::NAME)
33
            ->setDescription('Imports data to elasticsearch index.')
34
            ->addArgument(
35
                'filename',
36
                InputArgument::REQUIRED,
37
                'Select file to store output'
38
            )
39
            ->addOption(
40
                'bulk-size',
41
                'b',
42
                InputOption::VALUE_REQUIRED,
43
                'Set bulk size for import',
44
                1000
45
            )
46
            ->addOption(
47
                'gzip',
48
                'z',
49
                InputOption::VALUE_NONE,
50
                'Import a gzip file'
51
            );
52
    }
53
54
    /**
55
     * {@inheritdoc}