dunglas / doctrine-json-odm

An object document mapper for Doctrine ORM using JSON types of modern RDBMS.
https://dunglas.fr
MIT License
589 stars 66 forks source link

Unrecognized option "property_info" under "framework" #28

Closed DVelbeck closed 6 years ago

DVelbeck commented 7 years ago

Hi,

I have just installed your bundle in my symfony 2.7 project, added you bundle class in the AppKernel.php file to load it in my project but I get the following error message :

InvalidConfigurationException in ArrayNode.php line 312: Unrecognized option "property_info" under "framework"

The project runs with PHP 7.1, Symfony Framework 2.7

Is there something missing in my configuration, some parameters in the config.yml file ?

Here is the composer.json file :

{
    "description": "VE Cloud website",
    "autoload": {
        "psr-0": { "": "src/" }
    },
    "require": {
        "php": ">=5.3.3",
        "symfony/symfony": "2.7.14",
        "twig/twig": "^1.0",
        "doctrine/orm": "2.5.x-dev",
        "doctrine/dbal": "2.5.x-dev",
        "doctrine/doctrine-bundle": "~1.4",
        "symfony/assetic-bundle": "~2.3",
        "symfony/swiftmailer-bundle": "~2.3",
        "symfony/monolog-bundle": "~2.4",
        "symfony/serializer": "^2.8",
        "sensio/distribution-bundle": "~4.0",
        "sensio/framework-extra-bundle": "v3.0.16",
        "incenteev/composer-parameter-handler": "~2.0",

        "twig/extensions": "~1.0",
        "doctrine/doctrine-fixtures-bundle": "dev-master",
        "beberlei/DoctrineExtensions": "dev-master",
        "apy/datagrid-bundle": "dev-master",
        "craue/twigextensions-bundle": "dev-master",
        "stof/doctrine-extensions-bundle": "dev-master",
        "gedmo/doctrine-extensions": "v2.4.1", 
        "phpforce/common": "dev-master",
        "phpforce/soap-client": "dev-master",
        "phpforce/salesforce-bundle": "dev-master",
        "guzzlehttp/guzzle" : "v6.1.1",
        "liuggio/ExcelBundle": "v1.0.6",
        "besimple/soap-client": "0.3.*@dev",
        "ob/highcharts-bundle": "1.*",
        "eluceo/ical": "0.1.3",
        "zendframework/zend-json": "v2.6.1",
        "box/spout": "dev-master",
        "cocur/slugify": "dev-master",
        "verint/enterprise-feedback-bundle" : "dev-master",
        "symfony/var-dumper": "3.4.*@dev",
        "dunglas/doctrine-json-odm" : "v0.1.0",
        "syslogic/doctrine-json-functions":"~2.0",
        "soundasleep/html2text": "~0.5"

    },
    "require-dev": {
        "sensio/generator-bundle": "v2.3.5",
        "raulfraile/ladybug-bundle": "~1.0",
        "elao/web-profiler-extra-bundle": "dev-master",
        "leaseweb/version-information-bundle": "dev-master"
    },
    "scripts": {
        "post-install-cmd": [
            "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::removeSymfonyStandardFiles"
        ],
        "post-update-cmd": [
            "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::removeSymfonyStandardFiles"
        ]
    },
    "config": {
        "bin-dir": "bin",
        "vendor-dir": "vendor_2.7"
    },
    "minimum-stability": "dev",
    "extra": {
        "symfony-assets-install": "symlink",
        "symfony-app-dir": "app",
        "symfony-web-dir": "web",
        "incenteev-parameters": {
            "file": "app/config/parameters.yml"
        },
        "branch-alias": {
            "dev-master": "2.7-dev"
        }
    }
}

Here is my AppKernel.php :

<?php

use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\Config\Loader\LoaderInterface;

class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = array(
            // Symfony Standard Edition bundles
            new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
            new Symfony\Bundle\SecurityBundle\SecurityBundle(),
            new Symfony\Bundle\TwigBundle\TwigBundle(),
            new Symfony\Bundle\MonologBundle\MonologBundle(),
            new Symfony\Bundle\SwiftmailerBundle\SwiftmailerBundle(),
            new Symfony\Bundle\AsseticBundle\AsseticBundle(),
            new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
            new Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle(),

            // 3rd party vendor bundles
            new Dunglas\DoctrineJsonOdm\Bundle\DunglasDoctrineJsonOdmBundle(),
            new Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle(),
            new APY\DataGridBundle\APYDataGridBundle(),
            new Craue\TwigExtensionsBundle\CraueTwigExtensionsBundle(),
            new Liuggio\ExcelBundle\LiuggioExcelBundle(),
            new Stof\DoctrineExtensionsBundle\StofDoctrineExtensionsBundle(),
            //new Zenstruck\SlugifyBundle\ZenstruckSlugifyBundle(),
            new Ob\HighchartsBundle\ObHighchartsBundle(),
            new Verint\FeedbackBundle\VerintFeedbackBundle(),

//            new LanKit\DatatablesBundle\LanKitDatatablesBundle(),
//
            //  Systems vendor bundles
            new Systems\AuditBundle\SystemsAuditBundle(),
            new Systems\DirectoryBundle\SystemsDirectoryBundle(),
            new Systems\GitlabBundle\SystemsGitlabBundle(),
            new Systems\SparkBundle\SystemsSparkBundle(),
            new Systems\MenuBundle\SystemsMenuBundle( $this ),

            // Application bundles
            new AdminToolsBundle\AdminToolsBundle(),
            new AuditBundle\AuditBundle(),
            new CompanyBundle\CompanyBundle(),
            new DataGridBundle\DataGridBundle(),
            new DirectoryBundle\DirectoryBundle(),
            new EmployeeBundle\EmployeeBundle(),
            new EntitlementBundle\EntitlementBundle(),
            new FeedbackBundle\FeedbackBundle(),
            new FsatBundle\FsatBundle(),
            new GitlabBundle\GitlabBundle(),
            new HIPBundle\HIPBundle(),
            new IcdrBundle\IcdrBundle(),
            new IssueReportBundle\IssueReportBundle(),
            new MetricsBundle\MetricsBundle(),
            new SalesForceBundle\SalesForceBundle(),
            new SecurityBundle\SecurityBundle(),
            new SharedAccountBundle\SharedAccountBundle(),
            new UsageBundle\UsageBundle(),
            new WebsiteBundle\WebsiteBundle(),
            new ProfileBundle\ProfileBundle(),
            new MessageBundle\MessageBundle(),
            new GroupCalendarBundle\GroupCalendarBundle(),
            new SparkBundle\SparkBundle(),
            new ReportsBundle\ReportsBundle(),
            new AgentCaseOriginBundle\AgentCaseOriginBundle(),
            new ScoreCardsBundle\ScoreCardsBundle(),
        );

        if (in_array($this->getEnvironment(), array('dev', 'test'))) {
            // Bundles used for development and testing
            $bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle();
            $bundles[] = new Sensio\Bundle\DistributionBundle\SensioDistributionBundle();
            $bundles[] = new Sensio\Bundle\GeneratorBundle\SensioGeneratorBundle();
            $bundles[] = new RaulFraile\Bundle\LadybugBundle\RaulFraileLadybugBundle();
            //$bundles[] = new Lsw\VersionInformationBundle\LswVersionInformationBundle();
            $bundles[] = new Elao\WebProfilerExtraBundle\WebProfilerExtraBundle();
        }

        return $bundles;
    }

    public function registerContainerConfiguration(LoaderInterface $loader)
    {
        $loader->load(__DIR__.'/config/config_'.$this->getEnvironment().'.yml');
    }
}

And the config.yml file :

imports:
    - { resource: parameters.yml }
    - { resource: security.yml }
    - { resource: '@WebsiteBundle/Resources/config/listener.yml' }

# Craue Twig Extensions bundle
craue_twig_extensions:  ~

# Framework Configuration
framework:
    secret:       '%secret%'
    router:
        resource: '%kernel.root_dir%/config/routing.yml'
        strict_requirements: '%kernel.debug%'
    csrf_protection: false
    form:
        csrf_protection:
            enabled: false
    validation:      { enable_annotations: true }
    templating:      { engines: ['twig'] } #assets_version: SomeVersionScheme
    default_locale:  '%locale%'
    trusted_proxies: ~
    fragments: { path: /_proxy }
    session:
        cookie_domain: '%website.domain%'
        handler_id:    session.handler.pdo

parameters:
    templating.helper.assets.class: WebsiteBundle\Twig\AssetsHelper
# Switch User Listener
    security.authentication.switchuser_listener.class: SecurityBundle\Authentication\SwitchUserListener
# Session configuration
    pdo.db_options:
        db_table:     websitesession
        db_id_col:    session_id
        db_data_col:  session_value
        db_time_col:  session_time
        db_lifetime_col: session_lifetime
    formtype.audit.class: AuditBundle\Form\Type\AuditType

services:
    pdo:
        class: PDO
        arguments:
            - 'mysql:host=%database_host%;dbname=%database_name%'
            - '%database_user%'
            - '%database_password%'
        calls:
            - [setAttribute, [3, 2]]
    session.handler.pdo:
        class: Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler
        arguments:
            - '@pdo'
            - '%pdo.db_options%'

# Twig Configuration
twig:
    debug:            '%kernel.debug%'
    strict_variables: '%kernel.debug%'
    form_themes:
        - 'WebsiteBundle:Form:theme.html.twig'
        - 'FeedbackBundle:Form:theme.html.twig'
        - '::checkbox_layout.html.twig'
#    globals:
#        currentUser:  '@context.user'
#        currentEmployee:  '@context.employee'

# Assetic Configuration
assetic:
    debug:          '%kernel.debug%'
    use_controller: false
    bundles:        [ ]
    #java: /usr/bin/java
    filters:
        cssrewrite: ~
        #closure:
        #    jar: %kernel.root_dir%/Resources/java/compiler.jar
        #yui_css:
        #    jar: %kernel.root_dir%/Resources/java/yuicompressor-2.4.7.jar

# Swiftmailer Configuration
swiftmailer:
    transport: '%mailer_transport%'
    host:      '%mailer_host%'
    username:  '%mailer_user%'
    password:  '%mailer_password%'
    spool: { type: memory }

# Doctrine configuration
doctrine:
    dbal:
        default_connection: default
        connections:
            default:
                driver:   '%database_driver%'
                host:     '%database_host%'
                dbname:   '%database_name%'
                user:     '%database_user%'
                password: '%database_password%'
                charset:  UTF8
    orm:
        auto_generate_proxy_classes: '%kernel.debug%'
        resolve_target_entities:
            Systems\AuditBundle\Model\UserInterface: SecurityBundle\Entity\User
            Systems\AuditBundle\Model\ReferenceInterface: SalesForceBundle\Entity\SfdcCase
            Systems\AuditBundle\Model\MetadataInterface: AuditBundle\Entity\Metadata

        entity_managers:
            default:
                auto_mapping: true
                # metadata_cache_driver: apc
                # query_cache_driver: apc
                # result_cache_driver: apc
                dql:
                    string_functions:
                        GROUP_CONCAT: DoctrineExtensions\Query\Mysql\GroupConcat
                        IFNULL:       DoctrineExtensions\Query\Mysql\IfNull
                        YEAR:         DoctrineExtensions\Query\Mysql\Year
                        MONTH:        DoctrineExtensions\Query\Mysql\Month
                        DAY:          DoctrineExtensions\Query\Mysql\Day
                        RAND:         DoctrineExtensions\Query\Mysql\Rand
                        TIMESTAMPDIFF: DoctrineExtensions\Query\Mysql\TimestampDiff
                        WEEK:         DoctrineExtensions\Query\Mysql\Week
                        HOUR:         DoctrineExtensions\Query\Mysql\Hour
                        CONCAT_R1R5:  MetricsBundle\CustomSql\ConcatR1R5
                        SUBSTR_INDEX: MetricsBundle\CustomSql\SubStringIndex
                        DATE_FORMAT:  MetricsBundle\CustomSql\DateFormat
                        ROUND:        MetricsBundle\CustomSql\Round
                        LEFT:         MetricsBundle\CustomSql\Left
                        FLOOR:        MetricsBundle\CustomSql\Floor
                        FULL_GROUP_CONCAT: MetricsBundle\CustomSql\FullGroupConcat
                        SECTOTIME:    MetricsBundle\CustomSql\SecondToTime
                        JSON_EXTRACT: Syslogic\DoctrineJsonFunctions\Query\AST\Functions\Mysql\JsonExtract
                        JSON_SEARCH: Syslogic\DoctrineJsonFunctions\Query\AST\Functions\Mysql\JsonSearch

# Doctrine Extensions
stof_doctrine_extensions:
    orm:
        default:
            timestampable: true
            sluggable: true
            sortable: true

#zenstruck_slugify:
#    twig: true # enable twig filter
#    mode: array # iconv or array mode

#  Company Bundle
_company:
    fiscal_period:
        first_fiscal_month:
            name: November
            year: 2011
            start: '2010-10-31'
#verint EFM Feedback Bundle
verint_feedback:
    wsdlurl:  http://efm.services.vovici.com/ws/projectdata.asmx?wsdl
    userid:   veadmin
    password: API7

Thanks, DuncanV

dunglas commented 6 years ago

You need a more recent version of Symfony to use this bundle. Maybe 2.8 will be ok.

Toflar commented 6 years ago

Closing due to no further feedback.