<?xml version="1.0" encoding="utf-8"?><?xml-stylesheet href='http://feed.feedsky.com/styles/temp01.xsl' type='text/xsl' ?><!--这是一个由Feedsy提供技术支持的Feed，为了提高读者阅读的体验，以及满足用户美化自己Feed的需要，我们设计了多种精美的Feed模板，提供给大家选择，所有最终呈现出来的样式，皆由用户自愿选择使用，未经许可，任何团体和个人，请不要擅自修改样式或者盗用，这是对于用户选择权的尊重。--><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:fs="http://www.feedsky.com/namespace/feed" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link href="http://feed.feedsky.com/xuming" type="application/rss+xml" rel="self"></atom:link><fs:self_link href="http://feed.feedsky.com/xuming" type="application/rss+xml"></fs:self_link><lastBuildDate>Thu, 07 Jul 2011 04:54:38 GMT</lastBuildDate><title>徐明的博客</title><description>徐明的个人博客</description><image><url>http://www.feedsky.com/feed/xuming/sc/gif</url><title>徐明的博客</title><link>http://blog.xuming.net</link></image><link>http://blog.xuming.net</link><sy:updatePeriod>daily</sy:updatePeriod><sy:updateFrequency>1</sy:updateFrequency><language>zh-cn</language><pubDate>Thu, 07 Jul 2011 04:54:38 GMT</pubDate><item><title>IDP申请成功，开始转战Apple阵营</title><link>http://blog.xuming.net/2011/07/idp.html</link><content:encoded>&lt;p&gt;今天，我申请的IDP（Apple Developer Program Enrollment）终于成功的通过了审核。&lt;/p&gt;
&lt;p&gt;相对来说，整个过程还算比较顺利，鉴于网上教程很多，就不详细说明了。&lt;/p&gt;
&lt;p&gt;简单描述一下：&lt;/p&gt;
&lt;p&gt;6月27日开始申请，网上按流程填写注册信息到信用卡信息输入后要求发送Purchase Order Form，下载pdf,用photoshop,输入文字，将相机拍摄的个人签名ps到需要签名的地方（拍摄的签名如果不是纯白背景，可以用ps使用黑白效果，或调准明暗度处理一下）。&lt;/p&gt;
&lt;p&gt;将pdf转换成jpg格式，通过邮件发送到chinadev@asia.apple.com，请他们帮忙提交申请。&lt;/p&gt;
&lt;p&gt;当然，如果有条件发国际传真，就直接填好pdf发传真好了，不需要这样折腾。&lt;/p&gt;
&lt;p&gt;然后就是等待。。。&lt;/p&gt;
&lt;p&gt;7月5日，信用卡成功扣款99美元后收到激活邮件。但点击链接过去，发现提示&amp;ldquo;We are unable to activate your Apple Developer Program membership&amp;nbsp;because&amp;nbsp;we are unableto successfully verify&amp;nbsp;your&amp;nbsp;identity.&amp;rdquo;，意思是不能确定我的身份。&lt;/p&gt;
&lt;p&gt;赶紧又给chinadev@asia.apple.com发信说明情况。&lt;/p&gt;
&lt;p&gt;7月6日晚，收到反馈，已经去除限制，请激活。&lt;/p&gt;
&lt;p&gt;至此，申请成功。&lt;/p&gt;
&lt;p&gt;历时十天。&lt;/p&gt;
&lt;p&gt;又有的折腾了！&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2011/07/idp.html&quot;&gt;http://blog.xuming.net/2011/07/idp.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927615/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/07/idp.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927615/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/07/idp.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>程序/技术/交流</category><pubDate>Thu, 07 Jul 2011 12:54:38 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2011/07/idp.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1696804</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2011/07/idp.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927615/5135673</fs:itemid></item><item><title>Apple Tv 2 1.4.3完美越狱及xbmc搭建家庭影院</title><link>http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html</link><content:encoded>&lt;p&gt;受这篇文章《&lt;a href=&quot;http://bbs.weiphone.com/read-htm-tid-2135414.html&quot;&gt;TV2+普通路由+移动硬盘 打造最廉价客厅多媒体中心+家庭网络存储NAS+脱机下载方案+网络》&lt;/a&gt;影响&lt;/p&gt;
&lt;p&gt;出售败了一款apple tv。接下来就是艰苦的越狱过程。&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;h2&gt;越狱篇&lt;/h2&gt;
&lt;p&gt;Apple tv不越狱，在国内等于砖头一块。&lt;/p&gt;
&lt;p&gt;越狱前准备：&lt;a href=&quot;http://baike.baidu.com/view/1851541.htm&quot;&gt;micro usb cable&lt;/a&gt;&amp;nbsp;线一根。&lt;/p&gt;
&lt;p&gt;&lt;span style=&quot;border-collapse: collapse; color: #333333; font-family: simsun; line-height: 26px;&quot;&gt;A。4.21（显示4.11）越狱（参照&lt;a style=&quot;text-decoration: none; color: #014c90; outline-style: none; outline-width: initial; outline-color: initial;&quot; href=&quot;http://bbs.weiphone.com/read-htm-tid-1690956.html&quot; target=&quot;_blank&quot;&gt;http://bbs.weiphone.com/read-htm-tid-1690956.html&lt;/a&gt;&amp;nbsp;或&amp;nbsp;&lt;a style=&quot;text-decoration: none; color: #014c90; outline-style: none; outline-width: initial; outline-color: initial;&quot; href=&quot;http://bbs.weiphone.com/read-htm-tid-1986167.html&quot; target=&quot;_blank&quot;&gt;http://bbs.weiphone.com/read-htm-tid-1986167.html&lt;/a&gt;&amp;nbsp;）&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial; color: #000000;&quot;&gt;B。4.31(显示4.21)完美越狱&lt;/span&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial; color: #ff0000;&quot;&gt;，解决XBMC声卡问题。（&lt;/span&gt;参照&lt;a style=&quot;text-decoration: none; color: #014c90; outline-style: none; outline-width: initial; outline-color: initial;&quot; href=&quot;http://bbs.weiphone.com/read-htm-tid-1988553.html&quot; target=&quot;_blank&quot;&gt;http://bbs.weiphone.com/read-htm-tid-1988553.html&lt;/a&gt;&amp;nbsp;） &lt;!--more--&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;目前针对apple tv的越狱工具有很多，个人总结主要有下面三款：&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;greenpois0n.com越狱参考教程：&lt;a href=&quot;http://bbs.weiphone.com/read-htm-tid-1986167.html&quot;&gt;http://bbs.weiphone.com/read-htm-tid-1986167.html&lt;/a&gt;&lt;br /&gt; 本人测试，没有成功，貌似不支持目前最新的ios 1.4.3(apple tv 1.2.2)版本，&amp;nbsp;照教程的说法是要先降级，所以不推荐。&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://support.firecore.com/entries/387605-jailbreaking-101-seas0npass&quot;&gt;Seas0nPass&amp;nbsp;&lt;br /&gt;&lt;/a&gt;越狱参考教程：&lt;a href=&quot;http://support.firecore.com/entries/387605-jailbreaking-101-seas0npass&quot;&gt;http://support.firecore.com/entries/387605-jailbreaking-101-seas0npass&lt;br /&gt;&lt;/a&gt;使用这种方式和上面的方式相比，需要先下载最新的apple tv固件，然后将破解的软件加入到固件中，使用itunes的固件恢复功能，刷入apple tv ,相对来说成功率会比上面的高。本人使用此方式成功越狱,这种方式关键是进入dfu比较困难，安装软件的提示，很难成功进入。&amp;nbsp;&lt;br /&gt;我的经验是：  
&lt;ul&gt;
&lt;li&gt;先断开电源和usb&lt;/li&gt;
&lt;li&gt;连接USB&lt;/li&gt;
&lt;li&gt;３秒内接上电源&lt;/li&gt;
&lt;li&gt;apple tv2按住menu+play 7秒左右&lt;/li&gt;
&lt;li&gt;&amp;nbsp;进入DFU一定是机器前面的白色小灯一闪一闪（不是快速煽动）才行的。&lt;/li&gt;
&lt;li&gt;如果不行，先在电视上启动机器，然后拔掉电源后，再连接micro USB到电脑操作&lt;/li&gt;
&lt;li&gt;这是个技术活，要有耐心&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;sn0wbreeze&lt;br /&gt;参考教程：&lt;a href=&quot;http://bbs.weiphone.com/read-htm-tid-2059730.html&quot;&gt;http://bbs.weiphone.com/read-htm-tid-2059730.html&lt;br /&gt;&lt;/a&gt;目前最新版本是2.7.3　&lt;span style=&quot;color: #008800; font-family: Arial, 'Microsoft Yahei', Simsun, sans-serif; white-space: nowrap; line-height: normal;&quot;&gt;http://filetram.com/direct/download/file/8806955585/sn0wbreeze-v2-3-zip&lt;/span&gt;&amp;nbsp;&lt;br /&gt;优点是不用每次都下载apple tv固件&lt;br /&gt;按照教程没有成功&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;总的来说越狱不是特别难，但需要耐心和运气。&lt;/p&gt;
&lt;h2&gt;安装篇&lt;/h2&gt;
&lt;p&gt;&lt;span style=&quot;border-collapse: collapse; color: #333333; font-family: Arial; line-height: 26px;&quot;&gt;&lt;strong&gt;&lt;span style=&quot;outline-style: none; outline-width: initial; outline-color: initial; color: #ff0000;&quot;&gt;nitoTV安装&lt;/span&gt;&lt;/strong&gt;：（装完后可以安装其他软件)&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;使用 ssh 连上 ATV2，自行安裝 nitoTV。&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;1.使用 putty&amp;nbsp;&amp;nbsp;连接apple tv连上 ATV2&amp;nbsp;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;2.使用下列的指令&amp;nbsp;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;apt-get install wget&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;wget&amp;nbsp;&lt;a style=&quot;outline-style: none; outline-width: initial; outline-color: initial; text-decoration: none; color: #014c90;&quot; href=&quot;https://dl.dropbox.com/u/16129573/com.nito.deb&quot; target=&quot;_blank&quot;&gt;https://dl.dropbox.com/u/16129573/com.nito.deb&lt;/a&gt; --no-check-certificate&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;dpkg -i com.nito.deb&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;apt-get update&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;apt-get install com.nito.nitotv&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style=&quot;border-collapse: collapse; color: #333333; line-height: 26px;&quot;&gt;&lt;strong&gt;&lt;span style=&quot;color: #ff0000;&quot;&gt;XBMC&lt;/span&gt;&lt;span style=&quot;font-family: simsun;&quot;&gt;：&lt;/span&gt;&lt;/strong&gt;&lt;span style=&quot;font-family: simsun;&quot;&gt;强大的多煤体软件，TV看网上电影（优酷，奇艺），看本地电脑，NAS视频。必装软件。&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;font-family: simsun;&quot;&gt;4.21用XBMC官方正式版10.07，&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;font-family: simsun;&quot;&gt;4.31用官方论坛最新测试版&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;font-family: simsun;&quot;&gt;上面的越狱贴子都有下载地址和安装方法。&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;附：&lt;/p&gt;
&lt;p&gt;&lt;span style=&quot;border-collapse: collapse; color: #444444; font-family: Tahoma, 'Microsoft Yahei', Simsun; line-height: 21px;&quot;&gt;安装xmbc的nightly版本（&lt;span style=&quot;color: #333333; font-family: simsun; line-height: 26px;&quot;&gt;最新测试版）&lt;/span&gt;&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;&lt;a style=&quot;word-wrap: break-word; color: #336699; text-decoration: underline;&quot; href=&quot;http://forum.xbmc.org/showthread.php?t=96725&quot; target=&quot;_blank&quot;&gt;http://forum.xbmc.org/showthread.php?t=96725&lt;/a&gt;&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;具体方法，先用nito装xmbc正式版&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;然后SSH执行:&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;apt-get install wget&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;wget -O-&amp;nbsp;&lt;a style=&quot;word-wrap: break-word; color: #336699; text-decoration: underline;&quot; href=&quot;http://apt.awkwardtv.org/awkwardtv.pub&quot; target=&quot;_blank&quot;&gt;http://apt.awkwardtv.org/awkwardtv.pub&lt;/a&gt;&amp;nbsp;| apt-key add -&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;echo &quot;deb&amp;nbsp;&lt;a style=&quot;word-wrap: break-word; color: #336699; text-decoration: underline;&quot; href=&quot;http://apt.awkwardtv.org/&quot; target=&quot;_blank&quot;&gt;http://apt.awkwardtv.org/&lt;/a&gt;&amp;nbsp;stable main&quot; &amp;gt; /etc/apt/sources.list.d/awkwardtv.list&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;echo &quot;deb&amp;nbsp;&lt;a style=&quot;word-wrap: break-word; color: #336699; text-decoration: underline;&quot; href=&quot;http://mirrors.xbmc.org/apt/atv2/&quot; target=&quot;_blank&quot;&gt;http://mirrors.xbmc.org/apt/atv2/&lt;/a&gt;&amp;nbsp;./&quot; &amp;gt; /etc/apt/sources.list.d/xbmc.list&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;apt-get update&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;cd /private/var/tmp&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;wget&amp;nbsp;&lt;a style=&quot;word-wrap: break-word; color: #336699; text-decoration: underline;&quot; href=&quot;http://hadm.net/~keith/xbmc_atv2/latest_atv2.deb&quot; target=&quot;_blank&quot;&gt;http://hadm.net/~keith/xbmc_atv2/latest_atv2.deb&lt;/a&gt;&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;dpkg -i latest_atv2.deb&lt;br style=&quot;word-wrap: break-word;&quot; /&gt;rm -rf latest_atv2.deb&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style=&quot;border-collapse: collapse; color: #333333; line-height: 26px;&quot;&gt;&lt;span style=&quot;font-family: simsun;&quot;&gt;XBMC使用常见问题及解决方法：&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;font-family: simsun; word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial; color: #000000;&quot;&gt;1. 4.2 1中的nitoTV装不上XBMC&lt;/span&gt;&lt;span style=&quot;font-family: simsun;&quot;&gt;：&lt;/span&gt;&lt;span style=&quot;color: #000000;&quot;&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;4.21只能用SSH命今装，方法见上面越狱贴，如中断，掉线就重打命今，实在不行就换一个时间。没办法国外服务器。&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;2.4.31中安装XBMC：&lt;/span&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;论坛测试版才支持4.31，方法见上面越狱贴。&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;3.设置中文：&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;系统---用户界面，先把皮肤字体设为Arial, 再把语言设为 chinese simple,此时界面字体全成方块了。再回去把字体再次设为Arial,就变成中文了&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;/span&gt;4.设置正确的时间：&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;cd /private/var/db/timezone&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;rm localtime&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;ln -s /usr/share/zoneinfo/Asia/Shanghai localtime&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;killall AppleTV&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;/span&gt;5.安装中文插件（优酷之类的）：&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;来源请百度（HTPC1），安装方法见4.21越狱贴。注意有时安装后不能用，可以删除再安装一次就行了。有时出现脚本错误是网络问题。&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;6.过扫描解决方法（电视画片被放大，四周有约2CM的地方显示不出来）：&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;系统设置--系统设置--视频输出--屏幕校准&amp;nbsp;&amp;nbsp;&amp;nbsp;或在视频中长按确认键，调出屏幕校准选项&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;/span&gt;7.常自动退出/闪退：&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》. ATV进入主菜单&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》. 进入 NITO TV菜单&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》. 选择SETTING&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》.&amp;nbsp;&amp;nbsp;选择ABOUT，查看你的NITO TV 版本，目前最新是0.66&amp;nbsp;&amp;nbsp;&amp;nbsp;如果你的版本低于这个，请先升级（选择上面的 NITO TV UPDATE&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》. 升级完NITO TV&amp;nbsp;&amp;nbsp;重启 ATV2&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》.&amp;nbsp;&amp;nbsp;再次进入 NITO TV菜单&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》.&amp;nbsp;&amp;nbsp;选择 INSTALL SOFTWORE&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》.&amp;nbsp;&amp;nbsp;选择第一个项目进行更新。&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;》.&amp;nbsp;&amp;nbsp;更新后重启。&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;/span&gt;8.禁用苹果提示固件更新：&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;同7&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;9.设置与电脑或网络储存或NAS连接：&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;a: SMB(方便 )，&lt;/span&gt;&lt;br style=&quot;outline-style: none; outline-width: initial; outline-color: initial;&quot; /&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;b:UPNP（效率高，看1080P不卡） ，在电脑或NAS设置UPNP共享就行，在XBMC中的源里就能到。&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span style=&quot;border-collapse: collapse; color: #333333; line-height: 26px;&quot;&gt;&lt;span style=&quot;color: #000000;&quot;&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;资源大多来自网络，留此备忘！&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style=&quot;border-collapse: collapse; color: #333333; line-height: 26px;&quot;&gt;&lt;span style=&quot;color: #000000;&quot;&gt;&lt;span style=&quot;word-wrap: normal; word-break: normal; line-height: 21px; outline-style: none; outline-width: initial; outline-color: initial;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;

&lt;h4&gt;相关阅读&lt;/h4&gt;
&lt;ul&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2011/01/newyear.html&quot;&gt;2011新年快乐&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1336801&quot;&gt;近期计划&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1312801&quot;&gt;期待GAE SDK 1.4.0发布&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1248801&quot;&gt;Micolog源代码托管切换到Github&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/11/macos-t61.html&quot;&gt;黑苹果笔记-Ubuntu/Windows/Snow Leopard三系统共存&lt;/a&gt;&lt;/li&gt;
    
&lt;/ul&gt;
&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html&quot;&gt;http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927616/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927616/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>程序/技术/交流</category><category>生活点滴</category><pubDate>Sat, 21 May 2011 15:13:38 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1670814</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927616/5135673</fs:itemid></item><item><title>GAE 1.5.0 发布，再出猛料</title><link>http://blog.xuming.net/2011/05/gae-update1.html</link><content:encoded>&lt;p&gt;Google I/o 大会正在如火如荼的进行之中，值此盛会之际GAE又更新了，目前最新版本是1.5.0.　这次更新为我们（或许不包括我们）带来了什么新的东东呢？&lt;/p&gt;
&lt;p&gt;瞄了一眼release notes ,貌似东西不少。（眼馋哪！）&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;新增Backends，允许应用程序在后台执行&lt;/li&gt;
&lt;li&gt;Task Queues ,增加pull mode，借助&lt;a href=&quot;http://code.google.com/appengine/docs/python/taskqueue/rest.html&quot;&gt;Task Queue REST API&lt;/a&gt; ，可以实现站外启动或删除Task&lt;/li&gt;
&lt;li&gt;增加了task queues的配额&lt;/li&gt;
&lt;li&gt;HTTP 请求和应答大小限制增加到32m&lt;/li&gt;
&lt;li&gt;去除了requests, datastore operations, memcache , &amp;nbsp;image API的操作配额限制&lt;/li&gt;
&lt;li&gt;High Replication Datastore作为默认存储方式&lt;/li&gt;
&lt;li&gt;增加了get_async(), put_async(), delete_async()等异步数据操作函数&lt;/li&gt;
&lt;li&gt;支持go语言（go语言或许会是今后gae的主打语言，目前提供的功能还比较简陋）&lt;/li&gt;
&lt;li&gt;... ...&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;身在天朝，一声长叹！&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;h4&gt;相关阅读&lt;/h4&gt;
&lt;ul&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2009/12/gae.html&quot;&gt;Google App Engine 1.3.0发布，新增 BlobStore Service&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/06/gae-zipme.html&quot;&gt;Google App Engine 文件代码备份&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/06/lax.html&quot;&gt;LAX - Logilab App engine eXtension&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/06/gae-0.html&quot;&gt;开始Google App Engine之前应该做的事&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/06/gae-image-memcache.html&quot;&gt;Google App Engine SDK 新版本支持图像处理和缓存&lt;/a&gt;&lt;/li&gt;
    
&lt;/ul&gt;
&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2011/05/gae-update1.html&quot;&gt;http://blog.xuming.net/2011/05/gae-update1.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927617/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/05/gae-update1.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927617/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/05/gae-update1.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>Google App Engine</category><pubDate>Wed, 11 May 2011 15:42:09 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2011/05/gae-update1.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1669811</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2011/05/gae-update1.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927617/5135673</fs:itemid></item><item><title>再谈GAE</title><link>http://blog.xuming.net/?p=1640808</link><content:encoded>&lt;p&gt;在这个时候，再谈GAE，或许有点不合时宜。&lt;/p&gt;
&lt;p&gt;因为众所周知的原因，在我们伟大的党国，Google已经被当作&amp;ldquo;资本主义亡我之心不死&amp;rdquo;的大毒草，彻底的批滥批臭，灰溜溜的滚出了国门。&lt;/p&gt;
&lt;p&gt;而Google旗下的app engine 作为其颠覆中国的工具之一，长期被有效的阻挡在长城之外！&lt;/p&gt;
&lt;p&gt;什么是糖衣炮弹，这就是糖衣炮弹，谷歌提供免费的服务，其别有用心之情形昭然若揭。&lt;/p&gt;
&lt;p&gt;今天，我们只谈技术，莫谈国是。&lt;/p&gt;
&lt;p&gt;其实，最近一直很&quot;忙&quot;,也有一段时间没有关注GAE了，今天又重新审视了一遍，发现依然有了一些新的变化。下面，就我个人的一些见解，和大家探讨一下。&lt;/p&gt;
&lt;p&gt;目前，GAE的最新版本是1.4.3,距离我上次关注，已经提升了２个小点，从版本的变化看，应该没有特别大的架构上的变动，更多的是一些功能上的提升。（注意：本文只描述1.4.0版本以后的Python版本的变化，java版本的变化不在本人关注范围之内)&lt;/p&gt;
&lt;h3&gt;Webapp Framework开始支持django1.2&lt;/h3&gt;
&lt;p&gt;django0.96确实太老了，现在gae终于开始支持django1.2，虽然django的模板系统并不是十分的高效，但作为GAE原生支持的框架，能与时俱进，更新版本，对我们来说还是不错的消息。而且据说，以后1.2版本，将成为默认的版本，所以，该升就升，该改就改吧！&lt;/p&gt;
&lt;p&gt;micolog目前尚不支持django 1.2.5版本，想要升级的同学可以参考这篇文章&amp;nbsp;&lt;strong&gt;&lt;a href=&quot;http://blog.spbk.net/Micolog%E5%8D%87%E7%BA%A7%E9%BB%98%E8%AE%A40_96%E7%89%88%E6%9C%ACDjango%E8%87%B3Django1_2&quot;&gt;Micolog升级默认0.96版本Django至Django1.2&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;h3&gt;&lt;strong&gt;数据服务更加高效&lt;/strong&gt;&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;&lt;span style=&quot;font-family: arial, sans-serif; -webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-weight: normal; line-height: normal;&quot;&gt;在创建应用程序时，可以选择使用: High Replication 或者 Master/Slave.方式，关于这两种方式，我曾经写过一篇博文&amp;nbsp;&lt;/span&gt;&lt;/strong&gt;&lt;a title=&quot;Permanent Link to GAE新特性－高性能数据存储 (Python)&quot; rel=&quot;bookmark&quot; href=&quot;/2010/12/gae-High-Replication.html&quot;&gt;GAE新特性－高性能数据存储 (Python)&lt;/a&gt;&amp;nbsp;。Google 的官方文档中，对这两种方式进行了&lt;a href=&quot;http://code.google.com/intl/en/appengine/docs/python/datastore/hr/&quot;&gt;深入的对比&lt;/a&gt;。从对比结果，我们可以发现，使用high Replication方式，需要占用更多的存储空间和cpu时间，但并不能带来性能的提升，唯一的好处是能够保证数据的完整性。所以，对于我们并发数并不高的一样，实在是没有必要使用。而目前，&lt;span style=&quot;font-family: arial, sans-serif; -webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; line-height: normal;&quot;&gt;Master/Slave还是默认的数据存储方式，我们只能在创建应用程序的时候选择存储方式，一经选择，就&lt;br /&gt; 不能再修改。&lt;br /&gt; &amp;nbsp;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt; &lt;span style=&quot;font-family: arial, sans-serif; -webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; line-height: normal;&quot;&gt;提供了数据在不同应用之间迁移的功能&lt;br /&gt; 你可以在管理后台，使用Datastore Admin选项也，进行数据的复制或删除。数据复制功能可以在同一用户的不同应用之间进行，这为我们备份或迁移数据提供了一个思路，比如说，对于Micolog的升级，我们可以创建一个新的应用，然后把旧的Micolog数据，通过数据复制功能，复制到新的应用中去。&lt;/span&gt;&lt;img style=&quot;border: gray thin solid;&quot; src=&quot;http://code.google.com/appengine/docs/images/datastore_admin.png&quot; alt=&quot;&quot; /&gt;&lt;/li&gt;
&lt;li&gt;支持元数据查询&amp;nbsp;&lt;br /&gt; 可以用来从数据存储中检索，命名空间(namespaces), (类型)kinds, (属性) properties，有了这些Api，我们就可以创建自己的管理后台了。不过要注意的是，元数据查询，会比普通的查询消耗更多的资源，所以嘛，好像也没什么必要使用。不过，在某些特殊情况下，这个东东还是很有用的。&lt;/li&gt;
&lt;li&gt;可以将数据存储设置为只读模式&lt;br /&gt; 在这种模式下，任何对数据写的要求，都会触发异常。设置为只读模式，可以帮助我们在迁移或合并数据时，保证数据的一致性！&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;服务功能的增强&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;UrlFecth的后台抓取超时时间扩大到了10分钟，这样一来，能够抓取很大的数据包了。&lt;/li&gt;
&lt;li&gt;Task queue允许每秒钟执行100个任务,并且支持用程序来删除队列。&lt;/li&gt;
&lt;li&gt;Images API增加了quality参数，可以在做图像处理时指定图像质量&lt;/li&gt;
&lt;li&gt;cron job 允许指定开始和结束时间&lt;/li&gt;
&lt;li&gt;Prospective Search API: 允许Python使用者在写入数据时进行检测，一旦符合特定条件时便加以处理.可以参考一下这篇文章：&lt;a href=&quot;http://www.keakon.net/2011/03/31/GAE%20SDK%201.4.3%E7%89%88%E5%8F%91%E5%B8%83&quot;&gt;http://www.keakon.net/2011/03/31/GAE%20SDK%201.4.3%E7%89%88%E5%8F%91%E5%B8%83&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Testbed Unit Test Framework: Python 测试套件，为在整合测试中使用App Engine API 提供一个简单的接口。&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;相关阅读&lt;/h4&gt;
&lt;ul&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/12/gae-High-Replication.html&quot;&gt;GAE新特性－高性能数据存储 (Python)&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/11/gae-rollback.html&quot;&gt;解决GAE工程无法提交问题&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/10/gae_ip_block.html&quot;&gt;又一个Google的IP光荣了&lt;/a&gt;&lt;/li&gt;
    
&lt;/ul&gt;
&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/?p=1640808&quot;&gt;http://blog.xuming.net/?p=1640808&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927618/xuming/feedsky/s.gif?r=http://blog.xuming.net/?p=1640808&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>在这个时候，再谈GAE，或许有点不合时宜。
&amp;lt;br /&amp;gt;
&amp;lt;br /&amp;gt;因为众所周知的原因，在我们伟大的党国，Google已经被当作“资本主义亡我之心不死”的大毒草，彻底的批滥批臭，灰溜溜的滚出了国门。
&amp;lt;br /&amp;gt;
&amp;lt;br /&amp;gt;而Google旗下的app engine 作为其颠覆中国的工具之一，长期被有效的阻挡在长城之外！
&amp;lt;br /&amp;gt;
&amp;lt;br /&amp;gt;什么是糖衣炮弹，这就是糖衣炮弹，谷歌提供免费的服务，其别有用心之情形昭然若揭。
&amp;lt;br /&amp;gt;
&amp;lt;br /&amp;gt;今天，我们只谈技术，莫谈国是。&lt;img src=&quot;http://www1.feedsky.com/t1/639927618/xuming/feedsky/s.gif?r=http://blog.xuming.net/?p=1640808&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>Python</category><category>Google App Engine</category><pubDate>Thu, 21 Apr 2011 16:13:27 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/?p=1640808#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1640808</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/?p=1640808</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927618/5135673</fs:itemid></item><item><title>域名忘记续费，Micolog服务被中断几天</title><link>http://blog.xuming.net/?p=1601801</link><content:encoded>&lt;p&gt;各位，同学，不好意思：&lt;/p&gt;
&lt;p&gt;因为，个人原因，xuming.net域名忘记续费，导致Micolog官网，徐明的博客，Micolog论坛，全线无法访问，对此表示歉意！&lt;/p&gt;
&lt;p&gt;老实话，好多天没有使用Micolog了，所以挂掉了也不知道。&lt;/p&gt;
&lt;p&gt;今天，访问xuming.net发现竟然无法访问，第一反应是，靠被墙了？？？不至于吧，事实证明，我还没那么强大,经过简单的技术判断，判别是域名出了问题，赶紧去godaddy续费！&lt;/p&gt;
&lt;p&gt;一切恢复正常，希望大家继续支持！&lt;/p&gt;

&lt;h4&gt;相关阅读&lt;/h4&gt;
&lt;ul&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/12/update.html&quot;&gt;Micolog更新到0.74&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/05/micologrc2.html&quot;&gt;Micolog 0.7 RC2发布&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=497803&quot;&gt;手机测试&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/02/micolog-update.html&quot;&gt;Micolog英文主页发布&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/01/google_exit.html&quot;&gt;Micolog何去何从&lt;/a&gt;&lt;/li&gt;
    
&lt;/ul&gt;
&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/?p=1601801&quot;&gt;http://blog.xuming.net/?p=1601801&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927619/xuming/feedsky/s.gif?r=http://blog.xuming.net/?p=1601801&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927619/xuming/feedsky/s.gif?r=http://blog.xuming.net/?p=1601801&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>东拉西扯</category><pubDate>Fri, 11 Mar 2011 13:39:55 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/?p=1601801#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1601801</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/?p=1601801</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927619/5135673</fs:itemid></item><item><title>2011新年快乐</title><link>http://blog.xuming.net/2011/01/newyear.html</link><content:encoded>&lt;p&gt;2011年到了，祝大家新年快乐。&lt;/p&gt;
&lt;p&gt;希望Micolog能在新的年度更上一层楼，&lt;/p&gt;
&lt;p&gt;希望能有更多的朋友喜欢和使用Micolog.&lt;/p&gt;
&lt;p&gt;希望大家身体好，吃得饱，穿的暖。&lt;/p&gt;
&lt;p&gt;希望宝宝茁壮成长。&lt;/p&gt;
&lt;p&gt;希望家庭和睦，国家和谐。&lt;/p&gt;
&lt;p&gt;希望世界和平。&lt;/p&gt;
&lt;p&gt;顺祝：G。F。W早日倒塌！&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;h4&gt;相关阅读&lt;/h4&gt;
&lt;ul&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2011/05/apple-tv-2-143xbmc.html&quot;&gt;Apple Tv 2 1.4.3完美越狱及xbmc搭建家庭影院&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1336801&quot;&gt;近期计划&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1312801&quot;&gt;期待GAE SDK 1.4.0发布&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1248801&quot;&gt;Micolog源代码托管切换到Github&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/11/macos-t61.html&quot;&gt;黑苹果笔记-Ubuntu/Windows/Snow Leopard三系统共存&lt;/a&gt;&lt;/li&gt;
    
&lt;/ul&gt;
&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2011/01/newyear.html&quot;&gt;http://blog.xuming.net/2011/01/newyear.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927620/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/01/newyear.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927620/xuming/feedsky/s.gif?r=http://blog.xuming.net/2011/01/newyear.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>东拉西扯</category><pubDate>Sat, 01 Jan 2011 09:51:02 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2011/01/newyear.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1473801</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2011/01/newyear.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927620/5135673</fs:itemid></item><item><title>Micolog更新到0.74</title><link>http://blog.xuming.net/2010/12/update.html</link><content:encoded>&lt;p&gt;做了一点小更新，主要是&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;修复了Tinymce图片相对链接问题&lt;/li&gt;
&lt;li&gt;修改了一下wordpress插件，更好的支持wordpress数据的导入&lt;/li&gt;
&lt;li&gt;增加live import插件，用于将Live space备份的space.zip文件导入到Micolog&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;下载：&lt;a href=&quot;http://micolog.googlecode.com/files/micolog0.74.zip&quot;&gt;http://micolog.googlecode.com/files/micolog0.74.zip&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;h4&gt;相关阅读&lt;/h4&gt;
&lt;ul&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1601801&quot;&gt;域名忘记续费，Micolog服务被中断几天&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/05/micologrc2.html&quot;&gt;Micolog 0.7 RC2发布&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=497803&quot;&gt;手机测试&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/02/micolog-update.html&quot;&gt;Micolog英文主页发布&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2010/01/google_exit.html&quot;&gt;Micolog何去何从&lt;/a&gt;&lt;/li&gt;
    
&lt;/ul&gt;
&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2010/12/update.html&quot;&gt;http://blog.xuming.net/2010/12/update.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927621/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/update.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927621/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/update.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>micolog</category><pubDate>Tue, 07 Dec 2010 21:03:20 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2010/12/update.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1359802</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2010/12/update.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927621/5135673</fs:itemid></item><item><title>使用livespace插件将你的Live spaces空间转移到Micolog</title><link>http://blog.xuming.net/2010/12/live-space-import.html</link><content:encoded>&lt;p&gt;前段时间，微软宣布了将终止Live Space的博客服务，并且推荐大家将博客转移到Wordpress,但因为一些大家都知道的原因，在我国，wordpress的网站是不可访问的。所以，最近不断有朋友问我，能不能方便的将Live Space中的文章转移到Micolog上来。&lt;/p&gt;
&lt;p&gt;为此，我特意制作了用于导入MSN Live Space文章的插件：&lt;a href=&quot;http://micolog.xuming.net/media/agdtaWNvbG9ncikLEgZQbHVnaW4iEkxpdmUgU3BhY2UgSW1wb3J0IAwLEgVNZWRpYRgBDA/Live%20Space%20Import%20.zip?a=download&quot;&gt;live space import plugin&lt;/a&gt;。使用该插件可以完美的将Space.zip中的文章，评论，图片导入到Micolog中，并且Space.zip文件大小不受限制！&lt;/p&gt;
&lt;p&gt;您可以按照下面的步骤进行操作：&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;span style=&quot;font-family: Helvetica, Arial, Verdana, sans-serif; line-height: 16px;&quot;&gt;去你的Live Space空间，将文章导出为Space.zip&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://micolog.xuming.net/%E5%AE%89%E8%A3%85&quot;&gt;安装Micolog&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;下载并安装&lt;a href=&quot;http://micolog.xuming.net/media/agdtaWNvbG9ncikLEgZQbHVnaW4iEkxpdmUgU3BhY2UgSW1wb3J0IAwLEgVNZWRpYRgBDA/Live%20Space%20Import%20.zip?a=download&quot;&gt;live space import plugin&lt;/a&gt;插件。&lt;br /&gt;&lt;span style=&quot;font-family: Helvetica, Arial, Verdana, sans-serif; line-height: 16px;&quot;&gt;下载好插件后解压缩，并将其放置在Plugins目录下。&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: Helvetica, Arial, Verdana, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 16px;&quot;&gt;管理后台　－　插件　，激活Livespace import 插件&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: Helvetica, Arial, Verdana, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 16px;&quot;&gt;在管理后台　&amp;mdash;　导入导出　页面选择导入方式为Live Space&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: Helvetica, Arial, Verdana, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 16px;&quot;&gt;在导出页面，单击&amp;ldquo;选择(space.zip)并上传&quot;,选择你刚刚导出的Space.zip文件&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-family: Helvetica, Arial, Verdana, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 16px;&quot;&gt;耐心等待，完成所有文章的导入工作&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;欢迎使用Micolog。Micolog是&lt;span style=&quot;font-family: Helvetica, Arial, Verdana, sans-serif; line-height: normal;&quot;&gt;追求自由、开放、简约的GAE免费博客程序。&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2010/12/live-space-import.html&quot;&gt;http://blog.xuming.net/2010/12/live-space-import.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927622/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/live-space-import.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927622/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/live-space-import.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>micolog</category><pubDate>Sat, 04 Dec 2010 10:43:06 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2010/12/live-space-import.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1359801</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2010/12/live-space-import.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927622/5135673</fs:itemid></item><item><title>GAE新特性－高性能数据存储 (Python)</title><link>http://blog.xuming.net/2010/12/gae-High-Replication.html</link><content:encoded>&lt;p&gt;App Engine即将为数据存储提供一个新的配置选项（High Replication).这个选项即将生效。并且对所有GAE应用都有效。&lt;/p&gt;
&lt;h3&gt;当前的数据存储(Datastore)&lt;/h3&gt;
&lt;p&gt;目前，GAE只有一种存储方式（Master/Slave datastore）. 这种方式使用主从服务器的方式来处理数据的写入，当你将数据写入主服务器后，它将自动将数据同步到各个从服务器。因为他只有一个主服务器用于写入数据，所以能够提供非常良好的数据一致性。但是当系统出现故障或进行数据迁移会出现临时的数据不可访问的情况。不过这种方式相对来说消耗的存储空间和Cpu时间会稍微少一点。&lt;/p&gt;
&lt;h3&gt;高性能数据存储(High Replication datastore)&lt;/h3&gt;
&lt;p&gt;高性能数据存储方案，使用Paxos算法进行各个数据中心之间数据的同步。提供更加好的读和写的性能。但同时它可能会比主从服务器的方式多消耗两倍以上的存储空间和CPU时间。&lt;br /&gt; 稍候，GAE官方将给出如何使用这项新特性的相关文档。如果你打算创建一个新的应用，您可以选择使用 Master/Slave或High Replication这两者之一。如果你已经有了自己的应用，你可以选择是否将当前的应用切换到使用High Replication模式。&amp;nbsp;&lt;/p&gt;
&lt;p&gt;估计这个功能将会在未来几个月内发布，请大家保持关注。&lt;/p&gt;
&lt;p&gt;PS:越来越有云计算的味道了！&lt;/p&gt;

&lt;h4&gt;相关阅读&lt;/h4&gt;
&lt;ul&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/?p=1640808&quot;&gt;再谈GAE&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/11/gae-rollback.html&quot;&gt;解决GAE工程无法提交问题&lt;/a&gt;&lt;/li&gt;
    
    &lt;li&gt;&lt;a href=&quot;http://blog.xuming.net/2008/10/gae_ip_block.html&quot;&gt;又一个Google的IP光荣了&lt;/a&gt;&lt;/li&gt;
    
&lt;/ul&gt;
&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2010/12/gae-High-Replication.html&quot;&gt;http://blog.xuming.net/2010/12/gae-High-Replication.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927623/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/gae-High-Replication.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927623/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/gae-High-Replication.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>Google App Engine</category><pubDate>Fri, 03 Dec 2010 14:03:13 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2010/12/gae-High-Replication.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1348801</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2010/12/gae-High-Replication.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927623/5135673</fs:itemid></item><item><title>GAE程序优化最佳实践(一)-处理工作最小化</title><link>http://blog.xuming.net/2010/12/minimize.html</link><content:encoded>&lt;p&gt;&lt;span style=&quot;font-family: Helvetica, Arial, sans-serif; line-height: normal; font-size: small;&quot;&gt; &lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;原文：&lt;span style=&quot;line-height: 19px;&quot;&gt;&lt;a href=&quot;http://code.google.com/appengine/articles/scaling/minimize.html&quot;&gt;http://code.google.com/appengine/articles/scaling/minimize.html&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;App Engine 允许您使用Google提供的高性能的Web服务运行环境.　虽然环境本身已经提供了良好的性能可扩展性，但我们仍然可以使用一些方法来优化我们的应用程序，以提供用户体验减少系统资源的消耗，当然也节约了你的钞票。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;这篇文章提供了一些技巧，帮助你优化代码，提高性能。&lt;!--more--&gt;使用key, key name,或 ID来检索实体数据&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;App Engine的数据存储依赖于BigTable，BitTable是为分布式计算所设计的，所以它的一些实现与传统的面向对象的数据库系统有所不同。比如， App Engine数据库直接读取数据非常高效, &amp;nbsp;&lt;a style=&quot;color: #0000cc;&quot; href=&quot;http://code.google.com/status/appengine/&quot;&gt;System Status page&lt;/a&gt;&amp;nbsp;显示直接读取数据要比使用查询平均快四到五倍. 这就要求我们认真的考虑如何根据这个情况来设计我们的应用程序，以获取更好的性能。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;为了能够直接读取数据, 我们需要用到实体的keys. 当一个实体第一次创建的时候，您可以选择一个字符串作为实体的主键名(key name). 如果你知道这个实体的某个属性是唯一的（比如email地址），那么你就可以用这个属性值来作为主键的名字。如果你没有指定主键名.存储系统会为这个实体创建一个唯一的ID,并使用这个ID来关联实体的主键(Key).&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;不过如何指定主键，存储系统都允许你通过主键(key)简单并高效的来检索数据。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;&amp;nbsp;&lt;/p&gt;
&lt;div class=&quot;tabpane&quot; style=&quot;margin: 10px 0px 0px; width: 589px;&quot;&gt;
&lt;ul class=&quot;ui-tabs-nav&quot; style=&quot;margin-top: 0px; margin-right: 0px; margin-bottom: 4px; margin-left: 0px; line-height: 16px; background-image: none; background-attachment: scroll; background-origin: initial; background-clip: initial; background-color: #ffffff; list-style-type: none; list-style-position: initial; list-style-image: initial; background-position: 0% 50%; background-repeat: repeat repeat; padding: 0px;&quot;&gt;
&lt;li style=&quot;border-top-width: 1px; border-right-width: 1px; border-left-width: 1px; border-top-style: solid; border-right-style: solid; border-left-style: solid; border-top-color: #cccccc; border-right-color: #cccccc; border-left-color: #cccccc; border-bottom-style: none; border-bottom-width: initial; border-bottom-color: initial; background-color: #e5ecf9; display: inline; padding: 5px; margin: 0px;&quot;&gt;&lt;span style=&quot;color: black; display: inline;&quot;&gt;&lt;a style=&quot;color: black; text-align: center; text-decoration: none; white-space: nowrap; display: inline;&quot; href=&quot;http://code.google.com/appengine/articles/scaling/minimize.html#retrieve_java_sample&quot;&gt;P&lt;/a&gt;ython&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;div class=&quot;content-container&quot; style=&quot;padding-top: 15px; padding-right: 15px; padding-left: 15px; padding-bottom: 0px; background-color: #fafafa; border: 1px solid #cccccc;&quot;&gt;
&lt;div id=&quot;retrieve_python_sample&quot; class=&quot;ui-tabs-panel&quot; style=&quot;display: block;&quot;&gt;
&lt;pre class=&quot;prettyprint&quot; style=&quot;font-family: monospace; color: #007000; font-size: 9pt; background-color: #fafafa; line-height: 15px; overflow-x: auto; overflow-y: auto; word-wrap: break-word; padding: 2px; margin: 0px; border: 1px none #bbbbbb;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# To retrieve an entity given its corresponding &lt;/span&gt;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;Key&lt;/span&gt;&lt;/code&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt; object, pass it into &lt;/span&gt;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;get&lt;/span&gt;&lt;/code&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# directly:&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;br /&gt;e &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; db&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;color: #000088;&quot;&gt;get&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;key&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# You can fetch an entity given its key name using the &lt;/span&gt;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;Model&lt;/span&gt;&lt;/code&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt; class'&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# &lt;/span&gt;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;get_by_key_name&lt;/span&gt;&lt;/code&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt; class method:&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;br /&gt;key_name &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;str&quot; style=&quot;color: #008800;&quot;&gt;'Alfred.Smith@example.com'&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;;&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;e &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;color: #660066;&quot;&gt;Employee&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;get_by_key_name&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;key_name&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;);&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# To fetch an entity given its numeric ID, use the &lt;/span&gt;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;Model&lt;/span&gt;&lt;/code&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt; class'&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# &lt;/span&gt;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;get_by_id&lt;/span&gt;&lt;/code&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt; class method:&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;br /&gt;id &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;lit&quot; style=&quot;color: #006666;&quot;&gt;52234&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;;&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;e &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;typ&quot; style=&quot;color: #660066;&quot;&gt;Employee&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;get_by_id&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;id&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;);&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;您甚至可以使用一个列表来批量获取实体数据&lt;/p&gt;
&lt;div class=&quot;tabpane&quot; style=&quot;margin: 10px 0px 0px; width: 589px;&quot;&gt;
&lt;ul class=&quot;ui-tabs-nav&quot; style=&quot;margin-top: 0px; margin-right: 0px; margin-bottom: 4px; margin-left: 0px; line-height: 16px; background-image: none; background-attachment: scroll; background-origin: initial; background-clip: initial; background-color: #ffffff; list-style-type: none; list-style-position: initial; list-style-image: initial; background-position: 0% 50%; background-repeat: repeat repeat; padding: 0px;&quot;&gt;
&lt;li style=&quot;border-top-width: 1px; border-right-width: 1px; border-left-width: 1px; border-top-style: solid; border-right-style: solid; border-left-style: solid; border-top-color: #cccccc; border-right-color: #cccccc; border-left-color: #cccccc; border-bottom-style: none; border-bottom-width: initial; border-bottom-color: initial; background-color: #e5ecf9; display: inline; padding: 5px; margin: 0px;&quot;&gt;&lt;a style=&quot;color: black; text-align: center; text-decoration: none; white-space: nowrap; display: inline;&quot; href=&quot;http://code.google.com/appengine/articles/scaling/minimize.html#batch_java_sample&quot;&gt;&lt;span style=&quot;color: black; display: inline;&quot;&gt;Python&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;div class=&quot;content-container&quot; style=&quot;padding-top: 15px; padding-right: 15px; padding-left: 15px; padding-bottom: 0px; background-color: #fafafa; border: 1px solid #cccccc;&quot;&gt;
&lt;div id=&quot;batch_python_sample&quot; class=&quot;ui-tabs-panel&quot; style=&quot;min-width: 0px;&quot;&gt;
&lt;pre class=&quot;prettyprint&quot; style=&quot;font-family: monospace; color: #007000; font-size: 9pt; background-color: #fafafa; line-height: 15px; overflow-x: auto; overflow-y: auto; word-wrap: break-word; padding: 2px; margin: 0px; border: 1px none #bbbbbb;&quot;&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# The return value is a corresponding list of model instances, with None values&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;# when no entity exists for a corresponding Key.&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class=&quot;com&quot; style=&quot;color: #880000;&quot;&gt;#...&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;entities &lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; db&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;kwd&quot; style=&quot;color: #000088;&quot;&gt;get&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;key1&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; key2&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt; key3&lt;/span&gt;&lt;span class=&quot;pun&quot; style=&quot;color: #666600;&quot;&gt;]);&lt;/span&gt;&lt;span class=&quot;pln&quot; style=&quot;color: #000000;&quot;&gt;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p class=&quot;note&quot; style=&quot;padding-top: 0.2em; padding-right: 0.5em; padding-bottom: 0.2em; padding-left: 0.9em; margin-top: 1em; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 16px; background-color: #efefef; border-top-width: 1px; border-top-style: solid; border-bottom-width: 1px; border-bottom-style: solid; border-color: #bbbbbb;&quot;&gt;Note: 现在还无法使用 JDO and JPA接口来批量获取或设置实体, 您必须使用&amp;nbsp;&lt;a style=&quot;color: #0000cc;&quot; href=&quot;http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/datastore/package-summary.html&quot;&gt;low-level datastore API&lt;/a&gt;&amp;nbsp;for Java.&lt;/p&gt;
&lt;h3 style=&quot;margin: 1.5em 0px 0px; font-size: 17px; position: relative; top: 0em; font-weight: bold;&quot;&gt;不要使用offset进行分页&lt;/h3&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;分页是将大量数据呈现在用户面前的一种常用的手段。通过分页我们把数据切分成多个子集，我们可以在单个页面展示有限的数据，从而减少页面加载的时间。但需要的时候，用户可以通过上一页或下一页来查看更多数据。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;许多GAE的开发者喜欢使用offset来实现分页。但这种方式存在很多的问题。&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;span style=&quot;line-height: 16px;&quot;&gt;不能检索超过1000个实体&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;line-height: 16px;&quot;&gt;性能不高，每次检索都必须搜索所有实体，比如说，pagesize=10,每页显示１０条数据，使用offset来分页，将搜索所有数据，然后从中过滤出合适的数据进行显示。&lt;/span&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;所幸，这里有一些好的分页的方法，比如&amp;nbsp;&quot;&lt;a style=&quot;color: #0000cc;&quot; href=&quot;http://code.google.com/appengine/articles/paging.html&quot;&gt;How-To Do Paging on App Engine&lt;/a&gt;&quot;. 这种方式在每个实体中存储一个字符串属性，然后使用这个属性来判断那些实体需要被提取。使用这种方式，你不再需要提取不需要显示的实体，而且可以显示所有数据（不再受1000个实体的限制)。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;另外一个有效的方法是，当实体的显示顺序不是十分重要的时候，我们可以使用&amp;nbsp;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;__key__&lt;/code&gt;&amp;nbsp;属性来进行分页，&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;这两种方法都比使用offset来的快，具体实现方法请参考文章中的相关链接。&lt;/p&gt;
&lt;p class=&quot;note&quot; style=&quot;padding-top: 0.2em; padding-right: 0.5em; padding-bottom: 0.2em; padding-left: 0.9em; margin-top: 1em; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; line-height: 16px; background-color: #efefef; border-top-width: 1px; border-top-style: solid; border-bottom-width: 1px; border-bottom-style: solid; border-color: #bbbbbb;&quot;&gt;Note: 从GAE SDK 1.3.6开始已经取消了1000个实体的限制&lt;/p&gt;
&lt;h3 style=&quot;margin: 1.5em 0px 0px; font-size: 17px; position: relative; top: 0em; font-weight: bold;&quot;&gt;减少读／写频率&lt;/h3&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;在前面的章节里面，我们介绍了一条原则：只提取必须的数据。 这只是我们减少读写的原则中的一条。我们需要考虑哪些数据是必须的，并优化我们的实体设计模型和业务逻辑从而获取更好的数据处理能力。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;这是完全有可能做到的，下面以文件列表操作为例。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;由于Google App Engine不支持写入文件，所以我们需要使用datastore来存储文件的内容。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;一种可能的设计就是将文件的元数据（比如：文件名，大小，创建时间等）和内容存放在一个实体里.但是我们知道，其实通常情况下，我们并不需要获取文件的内容，比如说我们列出所有文件的时候。将文件云数据和内容存放在同一个实体中，但我们获取文件信息的时候，将会浪费很多不必要的CPU时间和内存。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;解决方法是将文件的云数据和内容使用两个实体类保持，实体１保存元数据，另外一个实体２保存实际的文件内容。实体１里面保存实体２的reference信息，这样但我们列出文件信息的时候，就可以不用去提取文件内容了。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;当然，当我们讨论减少读取频率的时候，我们不得不提到memcache. App Engine的Memcache服务为我们提供了非常高效的分布式缓存系统。您可以存储字符串或者其他实体在里面，并且快速的将其读取出来，从而避免直接从数据存储中重复读取数据。Memcache是一种非常好的数据库读写的替代品，他可以防止由于读取时间过长而导致的数据冲突（&lt;a style=&quot;color: #0000cc;&quot; href=&quot;http://code.google.com/appengine/articles/scaling/contention.html&quot;&gt;contention&lt;/a&gt;）。但Memcache并不能完全替代datastore,因为它保存的数据是不稳定，并且随时都有可能被丢弃。 但Memcache的使用，确实可以大大的减少数据库的读写操作，从而提高程序的性能。更多内容请阅读： &lt;a style=&quot;color: #0000cc;&quot; href=&quot;http://code.google.com/appengine/articles/scaling/memcache.html&quot;&gt;Effective memcache&lt;/a&gt;&amp;nbsp;.&lt;/p&gt;
&lt;h3 style=&quot;margin: 1.5em 0px 0px; font-size: 17px; position: relative; top: 0em; font-weight: bold;&quot;&gt;代码和环境缓存(Python runtime)&lt;/h3&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;如果你使用Python运行环境，我们强烈建议在你的代码里包含一个main函数。感觉Python 运行环境中关于 &quot;&lt;a style=&quot;color: #0000cc;&quot; href=&quot;http://code.google.com/appengine/docs/python/runtime.html#App_Caching&quot;&gt;App Caching&lt;/a&gt;&quot;的说明, 添加一个&amp;nbsp;&lt;code style=&quot;font-family: monospace; color: #007000; font-size: 10pt;&quot;&gt;main&lt;/code&gt;&amp;nbsp;函数，将使系统能够缓存key items(比如python脚本，全局变量），这些数据可以在下一个Request中重用。如果没有main函数的情况下，这些脚本将在每个request中重新加载并执行，从而浪费大量的资源，导致响应变慢。&lt;/p&gt;
&lt;p style=&quot;padding-top: 1em; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; line-height: 16px; margin: 0px;&quot;&gt;App Engine 在内存中自动缓存重要的模块，所以你不需要太担心你的脚本使用了太多的模块。但是，正因为这些缓存的存在，您可能会发现一些预期的Reload或R&lt;span style=&quot;font-family: Helvetica, Arial, sans-serif; font-size: small;&quot;&gt;eevaluated可能不会发生，您必须提起注意。&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;p&gt;本文网址:&lt;a href=&quot;http://blog.xuming.net/2010/12/minimize.html&quot;&gt;http://blog.xuming.net/2010/12/minimize.html&lt;/a&gt;&lt;/p&gt;&lt;img src=&quot;http://www1.feedsky.com/t1/639927624/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/minimize.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</content:encoded><wfw:commentRss>http://feeds.feedburner.com/xuming/comments</wfw:commentRss><slash:comments>0</slash:comments><description>&lt;img src=&quot;http://www1.feedsky.com/t1/639927624/xuming/feedsky/s.gif?r=http://blog.xuming.net/2010/12/minimize.html&quot; border=&quot;0&quot; height=&quot;0&quot; width=&quot;0&quot; style=&quot;position:absolute&quot; /&gt;</description><category>Google App Engine</category><pubDate>Thu, 02 Dec 2010 14:54:39 +0800</pubDate><author>徐明</author><comments>http://blog.xuming.net/2010/12/minimize.html#comments</comments><guid isPermaLink="false">http://blog.xuming.net/?p=1344801</guid><dc:creator>徐明</dc:creator><fs:srclink>http://blog.xuming.net/2010/12/minimize.html</fs:srclink><fs:srcfeed>http://xuming.net/feed</fs:srcfeed><fs:itemid>feedsky/xuming/~7132614/639927624/5135673</fs:itemid></item></channel></rss>
