Zend FR

Consultez la FAQ sur le ZF avant de poster une question

Vous n'êtes pas identifié.

#1 02-03-2012 22:22:07

bakura
Administrateur
Date d'inscription: 30-01-2010
Messages: 353

Zend Framework 2.0 beta3

La bêta 3 du Zend Framework 2 vient de sortir et peut-être récupérée ici : https://github.com/zendframework/zf2/zi … 2.0.0beta3

Les principales nouveautés : un tout nouveau view layer, et les composants Config et Db qui ont été réécrits. Sans compter la résolution de plusieurs dizaines de bugs.

A noter également que, suite à certaines discussions au sein de l'équipe, le view layer n'échappe plus automatiquement les variables comme c'était le cas depuis quasiment le début du développement de ZF2, et il est nécessaire, comme sur ZF1, d'appeler le view helper Escape.

Le changelog complet :

- Refactored Config component (Ben Scholzen, Artur Bodera, Enrico Zimuel, Evan Coury)
  - All readers moved under Zend\Config\Reader
    - JSON and YAML readers removed until beta4
    - New API:
      $xml = new Zend\Config\Reader\Xml();
      $config = new Zend\Config\Config($xml->fromFile($filename);

      or:
      $xml     = new Zend\Config\Reader\Xml();
      $config = $xml->fromFile($filename, true);

      or, simpler:
      $config = Zend\Config\Factory::fromFile($filename);
    - All constant injection removed from readers
      - New Processor API allows processing the retrieved configuration to do
        optional injection/manipulation of configuration values.
    - Ability to import other configuration files within a configuration file
      added.
  - Factory added, to simplify retrieving configuration from any configuration
    format supported.
- New View layer (Matthew Weier O'Phinney)
  - View layer is now:
    - Models, for aggregating and representing data to render; models may be
      nested to represent complex view hierarchies
    - Renderers, which render templates, using either variables provided or
      Models
    - Resolvers, which resolve template names to resources a renderer may
      consume
    - View, which allows attaching strategies for determining the renderer to
      use, as well as how to inject the response when done.
  - Old Zend_View is now Zend\View\Renderer\PhpRenderer
    - Composes a Resolver, a PluginBroker (for helpers), a Variables container
      (for aggregating variables to pass to the view script), and a FilterChain
      (for output filtering).
    - render() now accepts View\Models
    - allows rendering stacks of templates under the same variable scope, via
      the addTemplate() mechanism
    - moves escaping to an Escape view helper; no auto-escaping is enabled
  - MVC integration
    - Strategy listeners for:
      - Handling and returning 404 pages
      - Handling and returning error pages due to exceptions
      - RAD support for creation and injection of view models from action
        controller return values
    - Addition of a "render" event, executing after "dispatch" and before
      "finish"
- New Db layer (Ralph Schindler)
  - Complete rewrite from the ground up.
  - New architecture features low-level drivers, which also provide access to
    the PHP resource being consumed; adapters, which provide basic abstraction
    for common CRUD operations; new SQL abstraction layer, with full predicate
    support; abstraction for ResultSet's, with the ability to cast rows to
    specific object types; abstraction for SQL metadata; and a revised Table and
    Row Data Gateway.
- New Zend\Service\AgileZen component (Enrico Zimuel)
  - Support for the full AgileZen (http://www.agilezen.com) API
  - Developed for use with http://framework.zend.com/zf2/board
- PHP 5.4 support
  - A number of issues when running ZF2 under PHP 5.4 were identified and
    corrected.
- Other components that received attention:
  - Zend\GData (Maks3w)
  - Zend\Navigation (Kyle Spraggs, Frank Brückner)
  - Zend\Session (Mike Willbanks)
  - Zend\Service\Technorati (Maks3w)
  - Zend\Service\StrikeIron (Maks3w)
  - Zend\Service\Twitter (Maks3w)
  - Zend\Http\Header\Accept* (Matthew Weier O'Phinney, Enrico Zimuel)
    - Adds support for q priority, level identifiers, and wildcard media and
      submedia types
  - Zend\Ldap (Maks3w, Stefah Gehrig)
  - Zend\Oauth (bakura10)
  - Zend\Mvc and Zend\Module (Evan Coury, many others)

Around 200 pull requests for a variety of features and bugfixes were handled
since beta2.

La prochaine bêta devrait notamment inclure un gros morceau : Zend\Form.

N'hésitez pas à tester et à nous donner vos retours !

Hors ligne

 

#2 27-03-2012 01:04:34

Doubleslash
Membre
Date d'inscription: 28-05-2010
Messages: 10

Re: Zend Framework 2.0 beta3

La prochaine bêta devrait également assouplir le composant DI et optimiser le temps d'exécution. Là, pour une application de base avec une simple connexion MySQL de base et un formulaire, on se retrouve avec des pages entre 400 et 600ms hors cache. La gestion des BDD semble plus souple sur des exemples de base, mais je n'ai pas poussé la recherche très loin (j'ai bidouillé à ma sauce le tuto de Rob Allen)

Avec le cache par contre, on tombe dans des résultats très bons de quelques 30/40ms sur système de fichier. Il reste évidemment à voir ce que ça donne en production. Si d'autres personnes on un retour à partager sur cette bêta 3 ?

Hors ligne

 

Pied de page des forums

Propulsé par PunBB
© Copyright 2002–2005 Rickard Andersson
Traduction par punbb.fr

Graphisme réalisé par l'agence Rodolphe Eveilleau
Développement par Kitpages