IBM Developer is your one-stop location for getting hands-on training and learning in-demand skills on relevant technologies such as generative AI, data science, AI, and open source.
id:voluntas Comet on Mochiweb Erlang ãµã¼ã/ãã¼ã¿ãã¼ã¹ãæ¸ãçºã®è¨èª 軽éããã»ã¹ã大éã«ä½æå¯è½ é¢æ°åã¨ãããããªãç¬ç¹ãããã¦ãããªãErlangåè¨èª è¨èªèªä½ã®å¦ç¿ã³ã¹ãã¯ä½ã ãã¬ã¼ã ã¯ã¼ã¯ãã¤ãã¦ããããã£ã¡ã®å¦ç¿ã³ã¹ããé«ã 軽éããã»ã¹ééä¿¡ãç°¡å ãã¬ã¼ã ã¯ã¼ã¯ã§ç¶æ é·ç§»ã管çåºæ¥ã ã¹ã±ã¼ã©ããªãã£ãè¶ é«ã Mochiweb Erlangã§æ¸ãããWebãµã¼ã Facebookã®ãã£ããã«ä½¿ããã¦ãã Webãµã¼ãã¨ããããã好ããªWebãµã¼ããä½ãçºã®Webãµã¼ããã¬ã¼ã ã¯ã¼ã¯ ä½è ã¯MochiKitã¨ä¸ç· Comet æ¬ä¼¼çã«ãµã¼ããããã·ã¥ é常ã®Webãµã¼ãã§ã¯å®ç¾åºæ¥ãªã ã¯ã©ã¤ã¢ã³ããéã£ã¦ãããªã¯ã¨ã¹ããä¿çãã Last.fmã®äºä¾ã¨ãã¦ã¯C1000Kã¨ãããC1Mã¾ã§è¡ããã¨ã Cometã®å¯è½æ§ ãµã¼ããã¯ã©
çµè«: å®ç¨ã¯ç¡çã£ã½ã Google AppEngineã®ã¿ã¤ã ã¢ã¦ãããã°ããåã«30ç§ã«å»¶é·ãããã®ã§ããããªããªãã¨ãCometã§ããããããªããã¨ãããã¨ã§è©¦ãã«å®è£ ãã¦ã¿ã¾ãããã¤ãã§ã«Wave Gaget APIäºæã®ã¤ã³ã¿ãã§ã¼ã¹ãå®è£ ãã¦ãWave Gadgetããã®ã¾ã¾AppEngineã§åãããã«ãã¦ã¿ã¾ãããåãã¦ããã®ã¯Canvasã¬ã¸ã§ããã§ãã http://gimite-test.appspot.com/comet-test 注: ãã®ãã¡è½ã¨ãããããã¾ãããChrome 4ã¨Firefox 3.5ã§åä½ç¢ºèªãã¾ããã ãã°ãã1人ã§ç¹ãã£ã±ãªãã«ãã¦AppEngineã®Quotaãè¦å®ã£ãã®ã§ããããããããã£ã¨æ¦ç®ããã¨10人ã24æéç¹ãã£ã±ãªãã«ããã¨ããã ãã§CPUã®ç¡æQuotaã使ãå°½ããããã§ã :) ããã¯ã¡ãã£ã¨å³ããã§ããã30ç§ã§å
8. ã¾ãEntity @PersistenceCapable( GAE/Jã§ã¯å¿ é identityType = IdentityType.APPLICATION) ã¢ããªã§ 主ãã¼å®ç¾©ãã public class User { ã¨ããæå³ @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key key; @Persistent ã¢ããªã±ã¼ã·ã§ã³ã§ private String userId; å¤ãèªåçæ @Persistent private String password; ãã¨ãã£ãã¼ããã£ãã¼ãã 9. ã㧠Daoã ãã®1 public class UserDao { public void insert(PersistenceManager pm, User us
ã¹ã¿ã¼ã ã‹¤ã App Engine ã¢ã«ã¦ã³ãÂÂã«ãÂÂã°ã¤ã³ãÂÂã¾ãÂÂã App Engine SDK ãÂÂãÂÂã¦ã³ãÂÂã¼ãÂÂãÂÂã¾ãÂÂã ã¹ã¿ã¼ã ã‹¤ãÂÂãÂÂÃ¥ÂÂç §ãÂÂã¾ãÂÂã ã¢ãÂÂãªã±ã¼ã·ã§ã³ ã®ã£ã©ãªã¼ã®ãµã³ãÂÂã« ã¢ãÂÂãªã±ã¼ã·ã§ã³ãÂÂãÂÂ覧ãÂÂã ãÂÂãÂÂãÂÂ
ã´ã¼ã«ãã³ã¦ã£ã¼ã¯ã«ç¹ã«äºå®ã®ãªãã£ãçè ã¯ï¼ãã¡ã¾ãã§åã®Google App Engine for Javaï¼GAE/Jï¼ã¨Flexã§ã¹ã±ã¸ã¥ã¼ã«å ±æãã¼ã«ã§ãä½ã£ã¦ã¿ãããã¨æãç«ã¡ã¾ãããããã5æ¥éããã¦éçºãé²ããã®ã¡ï¼2009å¹´5æ6æ¥ã«ããé½å.comï¼ç»é¢1ï¼ããå ¬éãã¾ããããã®å¾ï¼ã¯ã¦ãªããã¯ãã¼ã¯ããã¥ã¼ã¹ãµã¤ããªã©ã§ãç´¹ä»ããã ãããããã§ï¼å ¬éå¾6æ¥ã§ç´2000人ã®æ¹ã«ãå©ç¨ããã ãã¦ãã¾ãã ããã§æ¬ç¨¿ã§ã¯ï¼ãã®ããé½å.comãã®éçºã§å®éã«çè ãå¾ãçµé¨ãéãã¦ï¼GAE/Jã«ããWebã¢ããªã±ã¼ã·ã§ã³éçºã®å®éã¨ãã®ããã³ã·ã£ã«ã«ã¤ãã¦ç´¹ä»ãã¾ãã ç±³Googleã2008å¹´4æã«çºè¡¨ããGoogle App Engineï¼ç»é¢2ï¼ã¯ï¼ãèªåãéçºããWebã¢ããªã±ã¼ã·ã§ã³ãGoogleã®ãã¼ã¿ã»ã³ã¿ã¼ã§éç¨ã§ããã¯ã©ã¦ãã³ã³ãã¥ã¼ãã£ã³ã°ã»ãµã¼ãã¹ãã§ã
ã¨ãã¸å¸å ´ã®æ´»æ§å㸠é«ã¾ãIoTãä¸å¿ã¨ããã¨ãã¸åéã¸ã®æå¾ OSSæ´»ç¨ãæ°ããæ代ã®ãã¸ãã¹ãæã 50å¹´ã®çµé¨ãæã¤ã¢ã¤ããããæä¾ ã¦ã¼ã¶ã¼ä¼æ¥ã®ä½¿ããããã第ä¸ã«èãã ã¯ã³ã¹ãããã§ä½¿ããããã¼ã¸ãã¯ã©ã¦ã ãªã¢ã¼ãã¯ã¼ã¯ãæåãããæ¹æ³ å¿ é ã¨ãªãã»ãã¥ãªãã£ãã©ãå¼·åããã å¿ è¦ãªå¯¾ç5ã¤ãç´¹ä» Kubernetesæ´»ç¨ã®æé©è§£ã¨ã¯ï¼ ä»ã注ç®ã®ã³ã³ãããæ´»ç¨ããæè»ãªITåºç¤ éç¨ã管çã®èª²é¡ã解決ãã¡ãªãããæ大å ãªãªã¸ãã«ã³ã³ãã³ããæºè¼ï¼ æå¤ã¨ç¥ããªãNutanix HCI ã®æ å ±ãéç´ èªãã°ãããï¼ãã¾HCIã注ç®ãããçç± é»è©±å¶æ¥ã»ã¤ã³ãµã¤ãã»ã¼ã«ã®é©æ° AIã«ããèªåæåèµ·ããã»ä¼è©±åæã é³å£°ã³ãã¥ãã±ã¼ã·ã§ã³ã®å¯è½æ§ãæã ãã¸ãã¹ã®æ¨é²ã«ã¯å¿ é ï¼ ZDNetÃãã¤ã¯ãã½ãããè´ãç¹å¥ä¼ç» ä»ãå¿ è¦ãªæ¦ç¥çã»ãã¥ãªãã£ã¨ã¬ããã³ã¹ AWSã¨Azu
Google App Engineã§ã¹ãã¬ã¼ã¸ãµã¼ãã¹ä½ã£ã¦ã¿ãã 詳ããã¯ããããã¼ã¸ã«æ¸ãããã©ãRest風ã®APIã§ãã¼ã¿ãããåãããã¿ã¤ãã®ã¹ãã¬ã¼ã¸ãµã¼ãã¹ã ãã®ãã¡ã¯ã©ã¤ã¢ã³ãç¨ã«Flexã§ããå°ç¨ã®ãã¡ã¤ã©ã§ãä½ãããã G-Storageã£ã¦ååã¯ãè¨ãã¾ã§ããªãGoogle + Storageã G-Storage http://g-storage.appspot.com/ form.enctypeã®JavaScriptã§ã®åçå¤æ´ã«ã¤ãã¦ã¯ããããåèã«ããã formã®enctypeã®å¤æ´ - babydaemonsã®æ¥è¨ http://d.hatena.ne.jp/babydaemons/20080523/1211545544 å ¬ééµæå·æ¹å¼ã使ããããã ãã©ãPythonã§ã©ãããã解ããªãã PHPã§è¨ãæã®openssl_private_decryptão
ã¯ã©ã¦ãã¯ããºã¯ã¼ãçã§ä½ãããã®ãè¯ãããããªãã¨ãã人ãå¤ããã¨ã§ãããããã®æè¦ã¯æ£ãããã¯ã©ã¦ãã¨ããè¨èã ãã ã¨ãæå³ãåºããã¦ãç¦ç¹ãã¼ããã ä¾ãã°ãåãããã«æããã¦ããAmazonã®EC2ã¨Google App Engineã¯ãã¾ã£ããéããã®ã§ãã Amazonã®ã»ãã¯æç¶çã¤ããã¼ã·ã§ã³ãGoogleã®ã»ãã¯ç ´å£çã¤ããã¼ã·ã§ã³ã EC2ã¯ãéå»ã®æè¡ããã®ã¾ã¾ä½¿ãã(æ±ç¨çãªä»®æ³åãµã¼ãã¹)ã®ã§ãé£ç¶çãªæè¡ãªã®ã§ãã ããã«å¯¾ãã¦GAE/Jã¯ãã§ãããã¨ãããªãå¶éãã¦ããããRDBMSããã¦ã¦BigTableã«ã®ããããã£ã¦ããéé£ç¶ã¶ãã ã©ã£ã¡ãããã¨ãããã®ã§ã¯ããã¾ããã ã¯ãªã¹ãã³ã»ã³ã®ã¤ããã¼ã·ã§ã³ã®ã¸ã¬ã³ã-æè¡é©æ°ã巨大ä¼æ¥ãæ» ã¼ãã¨ããèªãã¨ããã¼ã±ãããªã¼ãã¼ã§ããåªè¯ä¼æ¥ãããªãããã£ã¨æé·ãç¶ãããã¨ãã§ããã«ãç ´å£çã¤ããã¼ã·ã§ã³ã«æ» ã¼
ã¤ãã«ãªãªã¼ã¹ãããGoogle App Engineï¼GAEï¼åãã®Javaãæ¢ã«ç°å¢ã¯ç¨æããã¦ããã®ã§ãããã«éçºãéå§ã§ãããJavaã¨ããã¨ã¬ã³ã¿ã«ãµã¼ãã¬ãã«ã§ã¯éç¨ã§ãããä¼ç¤¾ã§ã¯Javaã使ãã¤ã¤ãå人ã§ã¯ä½¿ããªãã¨ãã人ãå¤ãã£ãã®ã§ã¯ãªãã ããããããã§éçºè ã®è£¾éãä¸æ°ã«åºãã£ãã ããã GAEã§åä½ããJRuby on Rails製ããã°ã·ã¹ãã PythonãJavaã¨ãã¦ä»ã®è¨èªãå人çã«ã¯Rubyã¯ã©ããªã®ã ããã¨æã£ããããããJRubyããã£ããããã«ããå¯è½æ§ãããã«åºãã£ãã ä»åç´¹ä»ããããªã¼ã¦ã§ã¢ã¯Yet Another Ruby BlogãJRuby on Railsã§éçºãããGAEåãããã°ã·ã¹ãã ã ãã½ã¼ã¹ã¯å ¬éããã¦ãããã©ã¤ã»ã³ã¹ã¯æè¨ããã¦ããªãã£ãã®ã§ã注æããã ãããã Yet Another Ruby Blogã¯GAEã®ä¸ã§åä½
ãã¾ããæ³¨è¨ $JRUBY_HOME/binã¯PATHã®æå¾ã«è¿½å ãã¦ãruby絡ã¿ã®ã³ãã³ããjrubyã§ä½¿ãã¨ãã¯jruby -Sããã®ãæ£è§£ã½ãã§ãã set $PATH=$PATH:$JRUBY_HOME/binã§ãä¾ãã°ãããªæã jruby -S gem install rails http://itrain.appspot.com/ åºæ¬çã«ã¯æ¨æ¥ã®ã¨ã³ããªã«æ¸ãã¦ããéãã ãã©ãããã¡ãã£ã¨ã ã詳細ã«æ¸ãã¦ã¿ããå®éã«è©¦ããããªãæ¨æ¥ã®ãããã£ã¡è¦ãæ¹ãããã¨æãããã ãDataStoreãUsersServiceããªãã§åã«ã³ã³ããã¼ã©ã¼ã§render :text=>'hoge'ããã ãã ã¾ãJRubyã¤ã³ã¹ãã¼ã« ãªãã¸ããªããææ°ãåã£ã¦æ¥ã¦å ¥ãããã¨ãæãæãã¦å¤ãã®å ¥ããã¨ãã¶ãåããªãã $ svn co http://svn.codehaus.org/jru
WEBã·ã¹ãã éçº æè¡çåå¿é²ï¼é称 æå¿é²ï¼ æè¡çåå¿é²ã«ãã¦ãæ å ±ã®å ±æãã§ããã°å¹¸ãã Eclipse(Pleiades) , CakePHP , ã¢ã¸ã£ã¤ã« ããããäºå®ã Google App Engine for JAVAï¼GAE/Jï¼ã§ãããã¤ã¥ãã¦ï¼°ï¼¨ï¼°ã«ã対å¿ãã¦ãããããã¨æ å ±ãé£ã³è¾¼ãã§ããã ããã¯ãããï¼ã¨æãã調ã¹ã¦ã¿ãããJAVAç°å¢ä¸ã§ï¼°ï¼¨ï¼°ãåããã¨ãããã¨ã®ããã ã£ãã ãããã«ãããããã®ããã¾ãããã»ã»ã»(^^;; ãããOKãªããããããªè¨èªã«å¯¾å¿ã§ãã¾ããã ã§ãããã§æãåºãããããããJRuby ã£ã¦ãã£ãããªãJAVA ä¸ã§åãã Rubyã ããã¦ãRuby ã¨ããã°ãRuby on Railsã åãäºãèãã¦ãã人ã¯ããã¯ãããããã§ã詳ããã¯ãã¡ããã ããã¯é¢ç½ãï¼GAEã§JRuby on Railsï¼ãYet Another
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}