Upgrade to Pro — share decks privately, control downloads, hide ads and more …

PHP5.5、いつやるか?今でしょ!

Keisuke SATO
September 14, 2013

 PHP5.5、いつやるか?今でしょ!

オープンソースカンファレンス2013 Hokkaido
https://www.ospn.jp/osc2013-do/modules/eguide/event.php?eid=29

w/ Sapporo.php

Keisuke SATO

September 14, 2013
Tweet

More Decks by Keisuke SATO

Other Decks in Programming

Transcript

  1. ͪͳΈʹࠓ౦ژͰ͸ • MySQL Admin͕ݟͨDevsͷৗࣝɺDBA͸ඇৗࣝ • 15෼Ͱग़དྷΔPHPͱJavaScript MVCϑϨʔϜϫʔΫ Ͱ࡞ΔϓϩτλΠϓ • PHP

    5.5ωʔςΟϒΩϟογϡͷ࿩ • ϑϩϯτΤϯυ੍࡞޲͚ϏϧυπʔϧGruntΛPHP όοΫΤϯυ։ൃͰར༻͢Δ • PHP։ൃऀͷͨΊͷΫϥ΢υ؀ڥ -ೖ໳ฤ-
  2. ڈ೥ • CGI ϞʔυͰಈ࡞͢Δ PHP ʹίϚϯυϥΠϯ Φϓγϣϯ͕ΫΤϦετϦϯάͰࢦఆͰ͖ͯ ͠·͏੬ऑੑ͕ • .../hoge.php?-s

    • ιʔείʔυ͕γϯλοΫεϋΠϥΠτ͞Ε ͯݟ͑ͪΌ͍ͬͯͨ • ͪͳΈʹ Facebook ʹ -s ͚ͭͯΞΫηε͢Δͱٻਓ৘ใͷ URL ͕࢓ ࠐ·Εͨ php ίʔυΛදࣔͯ͠·ͨ͠ɻ
  3. ᠘ • apc ͕ΠϚΠν • ฐࣾαʔϏε΋Α͘ apc ͷ͍ͤͰίέ·͢ • OPcache

    Λ࢖͏ͱ҆ఆͦ͠͏ͳ༧ײ • ςετ؀ڥͰ͸໰୊ͳ͘ಈ͍͍ͯΔ • ·ͩ production ʹ͸͍Εͯ·ͤΜ • ͋ͱͰ·ͨઆ໌͠·͢Ͷ
  4. OPcache extension • Zend Optimizer+ ͷΦϖίʔυΩϟογϡ • ΋ͱ΋ͱ༗ྉͰఏڙ͞Εͯͨ΍ͭͰ͢ • ։ൃ൛Ͱ͸

    apc ΑΓ਺% ʙ 20 % ΄Ͳߴ଎ • apc ͸ 5.5 ޲͚ʹ͸ఏڙ͞Ε͍ͯ·ͤΜ • apc_store, apc_fetch ͳͲͷ KVS ػೳ͚ͩ Λఏڙ͢Δ apcu extension ͕͋Γ·͢
  5. Deprecated • preg_replace ͷ /e म০ࢠ • ͔ΘΓʹ preg_replace_callback Λ

    • ҙ֎ͱϋϚΓͲ͜ΖɻErrorException Ͱɻ • ext/mysql extension • ͔ΘΓʹ mysqli ͔ pdo_mysql Λ
  6. Composer • PHP 5.3.2 ͔Β࢖͑Δύοέʔδ؅ཧπʔϧ • Ruby Ͱ͍͏ Bundler, node

    Ͱ͍͏ npm త ͳ΍ͭ • composer.json / autoload.php • Symfony, Zend Framework, PHPUnit, ... • git ͸ඞਢ͔΋ɻ • ϩΰ͕͍ͩ͞
  7. php-fig members "HBWJ %BWJE;ÛMLF !E[VFMLF "NB[PO8FC4FSWJDFT4%, 3ZBO1BSNBO !4LZ[ZY "QBDIFMPHQIQ *WBO)BCVOFL

    !JIBCVOFL "TTFUJDBOE#V[[ ,SJT8BMMTNJUI !LSJTXBMMTNJUI "VSB1SPKFDUBOE4PMBS'SBNFXPSL 1BVM.+POFT !QNKPOFT $BLF1)1 -BSSZ.BTUFST !1IQ/VU $PNQPTFSBOE1BDLBHJTU +PSEJ#PHHJBOP !TFMEBFL %PDUSJOF (VJMIFSNF#MBODP !HVJMIFSNFCMBODP %SVQBM -BSSZ(BSpFME !$SFMM F;1VCMJTI "OESF3PNDLF !BOESFSPN 5:10'MPX ,BSTUFO%BNCFLBMOT !LEBNCFLBMOT +BDLBMPQF -VLBT,BIXF4NJUI !MTNJUI +PPNMB %PO(JMCFSU !EJMCFSUMJGF -BSBWFM 5BZMPS0UXFMM !UBZMPSPUXFMM -JUIJVN /BUF"CFMF !OBUFBCFMF 1&"3 #SFUU#JFCFS !TBMUZCFBHMF QIQ## /JMT"EFSNBOO !OBEFSNBO QIQ%PDVNFOUPS .JLFWBO3JFM !NWSJFM 11* 1BVM%SBHPPOJT !ESHPPOJT 1SPQFM 8JMMJBN%VSBOE !DPVBD 1ZSP$.4 1IJM4UVSHFPO !QIJMTUVSHFPO 4BCSF%"7 &WFSU1PU !FWFSUQ 4VHBS$3. +PIO.FSUJD !KNFSUJD 4ZNGPOZ 'BCJFO1PUFODJFS !GBCQPU 5IFDPNNVOJUZBUMBSHF $BM&WBOT !$BM&WBOT ;FOE'SBNFXPSL 1ÂESBJD#SBEZ !QBESBJDC ;JLVMB ,BSNB%PSESBL ![JLVMBESBL
  8. PSR • PSR-0 • ϑΝΠϧ໊ͱΫϥε໊ͷن໿ • PSR-1 • ίʔσΟϯάن໿ •

    PSR-2 • ίʔσΟϯάελΠϧن໿ • PSR-3 • ϩΨʔͷΠϯλϑΣʔεن໿
  9. Sapporo.php • PHP ๺ւಓ with LOCAL • LOCAL PHP෦ •

    sapporo-php.net • 2 ϲ݄ʹҰ౓͘Β͍ษڧձ౳
  10. ຊ೔ͷ·ͱΊ • php5.3 Ҏલͷόʔδϣϯ͸΋͏ݹ͍ • φ΢͍ύοέʔδґଘ؅ཧ͸ Composer • ͦͯ͠ Packagist

    ͰͲΜͲΜެ։ • ίʔσΟϯάن໿͸ PSR Ͱ • ೔ຊޠ༁͸ Infinite loop ͞Μ
  11. Any question ? • ʮྑ͍࣭໰Ͱ͢Ͷʯ͕ग़Δͱ PHP Matsuri Tγ ϟπ͋͛·͢ •

    ྑ͍࣭໰͗͢Δͱ๻͕౴͑ΒΕͳ͍Մೳੑ͕ ͋Γ·͢