All Blog Posts Tagged 'technology' - TechHui2024-03-28T10:22:24Zhttp://www.techhui.com/profiles/blog/feed?tag=technology&xn_auth=noicutv newsfeedtag:www.techhui.com,2024-01-12:1702911:BlogPost:2136342024-01-12T21:03:22.000ZKeith Wayne Rushinghttp://www.techhui.com/profile/KeithWayneRushing
<p><a href="http://tinyurl.com/muajrdey" target="_blank" rel="noopener">http://tinyurl.com/muajrdey</a></p>
<p><a href="http://tinyurl.com/muajrdey" target="_blank" rel="noopener">http://tinyurl.com/muajrdey</a></p>Machine Learning to Reduce the Burden of Cancer in Hawaii and the Pacifictag:www.techhui.com,2021-09-09:1702911:BlogPost:2072342021-09-09T01:53:46.000ZLambert Leonghttp://www.techhui.com/profile/LambertLeong206
<p>In our most recent<a href="https://www.nature.com/articles/s43856-021-00024-0" rel="noopener" target="_blank"> Nature Article</a> we detail how we used a novel compositional breast imaging technique and machine learning/artificial intelligence to better detect cancer. We have been funded for the next 5 year by the National Institutes of Health (NIH) to build upon this research in Hawaii. As you may know, Hawaii's ethnic diversity makes it an ideal location to develop health based machine…</p>
<p>In our most recent<a href="https://www.nature.com/articles/s43856-021-00024-0" target="_blank" rel="noopener"> Nature Article</a> we detail how we used a novel compositional breast imaging technique and machine learning/artificial intelligence to better detect cancer. We have been funded for the next 5 year by the National Institutes of Health (NIH) to build upon this research in Hawaii. As you may know, Hawaii's ethnic diversity makes it an ideal location to develop health based machine learning models. We seek to better the health of Hawaii, its people, and the rest of the world. Please give it a look and we welcome feedback, comments, and/or questions. Enjoy!</p>#MyCorona (parody of My Sharona)tag:www.techhui.com,2020-05-05:1702911:BlogPost:1589992020-05-05T17:25:49.000ZSherry Lorancehttp://www.techhui.com/profile/SherryLorance
<p>Ooh my little sneaky one, my infections one</p>
<p>When you gonna let me socialize, Corona!</p>
<p>Ohh you make my body ache, my breath shallow</p>
<p>Got to isolate myself- thank you Rona!</p>
<p> </p>
<p>When’s this gonna stop, give it up, such a sneaky one</p>
<p>Gonna take my temp, to see if I’m getting worse</p>
<p>My, my, my, aye-aye- cough!</p>
<p>M-m-m-my Corona!</p>
<p> </p>
<p>Stay six feet away, huh a-will ya, huh?</p>
<p>Far enough away to not catch my Corona</p>
<p>Keeping it…</p>
<p>Ooh my little sneaky one, my infections one</p>
<p>When you gonna let me socialize, Corona!</p>
<p>Ohh you make my body ache, my breath shallow</p>
<p>Got to isolate myself- thank you Rona!</p>
<p> </p>
<p>When’s this gonna stop, give it up, such a sneaky one</p>
<p>Gonna take my temp, to see if I’m getting worse</p>
<p>My, my, my, aye-aye- cough!</p>
<p>M-m-m-my Corona!</p>
<p> </p>
<p>Stay six feet away, huh a-will ya, huh?</p>
<p>Far enough away to not catch my Corona</p>
<p>Keeping it all for me, it’s just for me</p>
<p>Running the length of its course- Corona</p>
<p> </p>
<p>When’s this gonna stop, give it up, such a sneaky one</p>
<p>Gonna take my temp, to see if I’m getting worse</p>
<p>My, my, my, aye-aye- cough!</p>
<p>M-m-m-my Corona!</p>
<p>M-m-m-my Corona!</p>
<p> </p>
<p>When you going to leave me, to leave me</p>
<p>I know it’s just a matter of time Corona</p>
<p>Or will you still be plaguing me, a plaguing me</p>
<p>Or will we find a cure- Corona?</p>
<p> </p>
<p>When’s this gonna stop, give it up, such a sneaky one</p>
<p>Gonna take my temp, to see if I’m getting worse</p>
<p>My, my, my, aye-aye- cough!</p>
<p>M-m-m-my Corona!</p>
<p>M-m-m-my Corona!</p>
<p>M-m-m-my Corona!</p>
<p>M-m-m-my Corona!</p>
<p> </p>
<p>Ooooooooo-ohhh, my Corona!</p>
<p>Ooooooooo-ohhh, my Corona!</p>
<p>Ooooooooo-ohhh, my Corona!</p>Siginificant IT Outages for 2019tag:www.techhui.com,2020-01-17:1702911:BlogPost:1582612020-01-17T15:43:22.000ZFrancis A. Covingtonhttp://www.techhui.com/profile/FrancisACovington
<p>Folk:</p>
<p>I just published a new White Paper on The Significant IT outages of 2019. I have not uploaded it to my website as yet, but I should have it uploaded by later today (<a href="http://www.covingtonca.com">http://www.covingtonca.com</a>). The last story especially touched me because we have solutions that could have prevented each and every one of these outage. I am going to try to attach the file. but if it doesn't work, you can retrieve it from my website later. I hope this…</p>
<p>Folk:</p>
<p>I just published a new White Paper on The Significant IT outages of 2019. I have not uploaded it to my website as yet, but I should have it uploaded by later today (<a href="http://www.covingtonca.com">http://www.covingtonca.com</a>). The last story especially touched me because we have solutions that could have prevented each and every one of these outage. I am going to try to attach the file. but if it doesn't work, you can retrieve it from my website later. I hope this info is useful to all.</p>
<p>Francis</p>
<p></p>
<p><a href="https://storage.ning.com/topology/rest/1.0/file/get/3823788839?profile=original" target="_blank" rel="noopener">Major%20Technology%20Outages%20in%202019.pdf</a></p>
<p></p>Please refer me to a good (cheap and honest lawyer?)tag:www.techhui.com,2018-09-04:1702911:BlogPost:1514692018-09-04T19:42:33.000ZDavid Hennahttp://www.techhui.com/profile/DavidHenna
<p>the names I see, Leighton Chong and Sayoko Jean Blodgett-Ford are</p>
<p>outdated! Thank you. David Henna. September 4, 2018</p>
<p>the names I see, Leighton Chong and Sayoko Jean Blodgett-Ford are</p>
<p>outdated! Thank you. David Henna. September 4, 2018</p>Using Touch ID to separate bots from humans in social mediatag:www.techhui.com,2018-04-09:1702911:BlogPost:1497132018-04-09T03:47:38.000ZAugusto Callejashttp://www.techhui.com/profile/AugustoCallejas
<p>Whenever you’re on a social network, like Facebook or Twitter, you know who your friends and family are. However, there are many accounts that you don’t know personally, which can be bots. How can you tell bot from human? This a general issue beyond just social media. Google supports an approach to this called <a href="https://en.wikipedia.org/wiki/ReCAPTCHA">reCAPTCHA</a> which can require a user doing a task that a human can do better than a bot. However, when posting to a social network,…</p>
<p>Whenever you’re on a social network, like Facebook or Twitter, you know who your friends and family are. However, there are many accounts that you don’t know personally, which can be bots. How can you tell bot from human? This a general issue beyond just social media. Google supports an approach to this called <a href="https://en.wikipedia.org/wiki/ReCAPTCHA">reCAPTCHA</a> which can require a user doing a task that a human can do better than a bot. However, when posting to a social network, this process would be tedious and lead to lower engagement. Apple’s Touch ID may be able to help.</p>
<p>Apple introduced <a href="https://en.wikipedia.org/wiki/Touch_ID">Touch ID</a> in 2013 to allow users to quickly unlock their phones and download apps without having to re-enter their password. It was <a href="https://techcrunch.com/2014/06/02/apple-touch-id/">extended</a> to all app developers in 2014 so they could store secure credentials that could only be unlocked with a fingerprint.</p>
<p>The proposal is to use Touch ID (and potentially <a href="https://en.wikipedia.org/wiki/Face_ID">Face ID</a>, which was introduced in 2017) as a way to uniquely confirm a human is behind every social media post. Storing secure credentials would not work because they are known to the user, and hence to a bot developer. Instead, the proposal is to allow an app developer (and hence Twitter and Facebook) the ability to provide a timestamped server-generated message that needs to be encrypted via a hardware key that is only available during a finger press. That encrypted message is then sent back to the app developer’s server, where it is decrypted from a list of public keys based on device model and operating system version. If the decrypted message matches the original server message, then the app developer knows that a genuine human confirmed the operation, and the social media post can be accepted. The whole process would need to occur within a certain amount of time, like 30 seconds, in order to stop malicious users from accumulating many encrypted messages in order to spam the network.</p>
<p>This idea is currently not supported by Touch ID, but would require an upgrade allowing device-specific private keys to be stored on the device and public keys to be made available for app developers to confirm encrypted messages. In order to spur adoption among major social networks, the confirmation mechanism would need to be standardized so other hardware providers can implement it on their own hardware. Initially, this could be an optional feature, allowing accounts with more “Touch ID” confirmed posts to be displayed prominently. In the future, users should be able to display only confirmed posts, to ensure their social media feed is bot-free.</p>
<p><em>This post was originally posted on my <a href="https://www.augustocallejas.com/2018/04/08/touch-id/" target="_blank" rel="noopener">blog</a>.</em></p>Ho`i Mai - Stories of Kama`aina who have returned hometag:www.techhui.com,2017-11-06:1702911:BlogPost:1472422017-11-06T19:29:31.000ZCindy Matsukihttp://www.techhui.com/profile/CindyMatsuki13
<p>I wanted share a <a href="https://hoimai.wordpress.com/" target="_blank">blog</a> with everyone on TechHui, and I also wanted to ask if anyone has moved back recently to Hawaii in a tech job/tech entrepreneur area after working away for a while. I'd love to share your story.</p>
<p>The goal of the blog is to inspire others and give them roadmap options on how to make the journey back to Hawaii. Here's the…</p>
<p>I wanted share a <a href="https://hoimai.wordpress.com/" target="_blank">blog</a> with everyone on TechHui, and I also wanted to ask if anyone has moved back recently to Hawaii in a tech job/tech entrepreneur area after working away for a while. I'd love to share your story.</p>
<p>The goal of the blog is to inspire others and give them roadmap options on how to make the journey back to Hawaii. Here's the <a href="https://hoimai.wordpress.com/2017/11/01/welcome-home-meli-james/" target="_blank">latest post featuring Meli James</a>. Please email me at cindy@htdc.org if you'd like to share your story. :D</p>
<p>Mahalo!</p>2 Software Developer Positions with TITLE GUARANTYtag:www.techhui.com,2017-10-17:1702911:BlogPost:1463482017-10-17T00:00:00.000ZDesireehttp://www.techhui.com/profile/Athena
<p>POSITIONS FILLED</p>
<p>We are looking for one Senior Developer and one Junior Developer at Title Guaranty!</p>
<p>Our office is in downtown Honolulu!</p>
<p>If you want to find out more, please go to <a href="http://www.tghawaii.com">www.tghawaii.com</a> and click on Career Opportunities!</p>
<p></p>
<p></p>
<p></p>
<p>POSITIONS FILLED</p>
<p>We are looking for one Senior Developer and one Junior Developer at Title Guaranty!</p>
<p>Our office is in downtown Honolulu!</p>
<p>If you want to find out more, please go to <a href="http://www.tghawaii.com">www.tghawaii.com</a> and click on Career Opportunities!</p>
<p></p>
<p></p>
<p></p>About $90,000 in prizes awarded on October 21! Hope you guys can join us.tag:www.techhui.com,2017-09-28:1702911:BlogPost:1465432017-09-28T20:13:51.000ZOlin Lagonhttp://www.techhui.com/profile/OlinLagon123
<p dir="ltr"><iframe allowfullscreen="" frameborder="0" height="315" src="https://www.youtube.com/embed/MmpEiWsVO_U?wmode=opaque" width="560"></iframe>
</p>
<p dir="ltr"><span><a href="http://storage.ning.com/topology/rest/1.0/file/get/396587800?profile=original" target="_self"><img class="align-right" src="http://storage.ning.com/topology/rest/1.0/file/get/396587800?profile=RESIZE_320x320" width="300"></img></a> Since March there’s been a competition going on, called the Purple Prize, that asks tech developers to team up with cultural practitioners to innovate technologies that serve Hawaiian culture and Hawaiʻi.…</span></p>
<p dir="ltr"><iframe width="560" height="315" src="https://www.youtube.com/embed/MmpEiWsVO_U?wmode=opaque" frameborder="0" allowfullscreen=""></iframe> </p>
<p dir="ltr"><span><a href="http://storage.ning.com/topology/rest/1.0/file/get/396587800?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396587800?profile=RESIZE_320x320" width="300" class="align-right"></a>Since March there’s been a competition going on, called the Purple Prize, that asks tech developers to team up with cultural practitioners to innovate technologies that serve Hawaiian culture and Hawaiʻi. The winners will be selected in October.</span></p>
<p>The Purple Prize is only two years old and is run by the small team at technology education nonprofit Purple Maiʻa Foundation. But it’s one of the biggest competitions in Hawaiʻi if you measure by how much prize money is given away. This year they say they’ll be giving out $90K or more in prizes (cash and cloud service credits).</p>
<p dir="ltr"><span>The words “technology innovation” usually bring to mind things like flying cars, the latest smartphone, or futuristic space stations, but the Purple Prize encourages participants to think about innovation as working to solve problems faced by your local community and your environment.</span></p>
<p>This year, the 12 competing teams are working on projects that have to do with things like monitoring loko iʻa (traditional Hawaiian fishponds), gathering and visualizing data about ecosystems, connecting consumers to healthy food, and sharing moʻolelo (stories) about significant places. The teams all relate their work to this year’s competition theme: Waiwai (value).</p>
<p>Last year, 6 teams competed with projects inspired by the theme aloha ʻāina (love of the land). The top three winning teams were working on wetland censors, a kid’s game app about the watershed called <a href="https://play.google.com/store/apps/details?id=com.halepili.waiwai&hl=en">Waiwai</a>, and a wearable technology that helps you learn Hawaiian rain names.</p>
<p><a href="http://storage.ning.com/topology/rest/1.0/file/get/396589058?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396589058?profile=RESIZE_1024x1024" width="750" class="align-center"></a></p>
<p></p>
<p>This year’s winners will be chosen on Oct. 21 at UH West Oʻahu. The public and especially students are welcome to check out all the teams, have lunch, and stay for other programming about innovation taking place throughout the day. There is also a pau hana networking event planned for Oct. 19 in Mōʻiliʻili. Watch <a href="http://www.purpleprize.com">www.purpleprize.com</a> for details.</p>Code Ninja coming to Maui, Hawaiitag:www.techhui.com,2016-08-01:1702911:BlogPost:1399762016-08-01T20:48:59.000ZTom Bigelowhttp://www.techhui.com/profile/TomBigelow
<p></p>
<p><a href="http://storage.ning.com/topology/rest/1.0/file/get/396587608?profile=original" target="_self"><img class="align-full" src="http://storage.ning.com/topology/rest/1.0/file/get/396587608?profile=RESIZE_1024x1024" width="750"></img></a></p>
<p><a href="http://www.code-ninja.co/" rel="nofollow" target="_blank">www.Code-Ninja.co</a><span> is expanding to Hawaii! Our first location is in the Maui Tech Center! Enroll Today. </span><a class="_58cn" href="https://www.facebook.com/hashtag/codelikeaninja?source=feed_text&story_id=655373787953379"><span class="_58cl">#…</span></a></p>
<p></p>
<p><a href="http://storage.ning.com/topology/rest/1.0/file/get/396587608?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396587608?profile=RESIZE_1024x1024" width="750" class="align-full"></a></p>
<p><a href="http://www.code-ninja.co/" target="_blank" rel="nofollow">www.Code-Ninja.co</a><span> is expanding to Hawaii! Our first location is in the Maui Tech Center! Enroll Today. </span><a class="_58cn" href="https://www.facebook.com/hashtag/codelikeaninja?source=feed_text&story_id=655373787953379"><span class="_58cl">#</span><span class="_58cm">CodeLikeaNinja</span></a><span> </span><a class="_58cn" href="https://www.facebook.com/hashtag/aloha?source=feed_text&story_id=655373787953379"><span class="_58cl">#</span><span class="_58cm">Aloha</span></a><span> </span><a class="_58cn" href="https://www.facebook.com/hashtag/hawaii?source=feed_text&story_id=655373787953379"><span class="_58cl">#</span><span class="_58cm">hawaii</span></a></p>
<p></p>
<p><span class="_58cm"><span>There are only six spots left for our September 6th RAMP program. Find out more:</span></span></p>
<p><span class="_58cm"><span><a href="https://eg144.infusionsoft.com/app/storeFront/showProductDetail?productId=60" target="_blank">https://eg144.infusionsoft.com/app/storeFront/showProductDetail?productId=60</a></span></span></p>Why It May Still Be Worthwhile to Try to Patent Your Business Method Inventiontag:www.techhui.com,2016-05-27:1702911:BlogPost:1399442016-05-27T22:55:42.000ZLeighton K. Chonghttp://www.techhui.com/profile/LeightonKChong
<p></p>
<p>There are significant business and tactical advantages that can make it worthwhile for a startup company to file for a U.S. patent application on its business method invention, despite the current chaos in the U.S. Patent Office and the courts on the legal parameters for patenting business methods. <a href="http://HawaiiTechnology.blogspot.com" target="_blank">For more ...</a></p>
<p></p>
<p>There are significant business and tactical advantages that can make it worthwhile for a startup company to file for a U.S. patent application on its business method invention, despite the current chaos in the U.S. Patent Office and the courts on the legal parameters for patenting business methods. <a href="http://HawaiiTechnology.blogspot.com" target="_blank">For more ...</a></p>SpaceX makes HISTORY, successfully "Lands" first-stage of Falcon-9 "Main Rocket" back to Earth at Cape Canaveral, FL for "re-use" in future missions, and deploys 11 Satellites in one shot!tag:www.techhui.com,2015-12-22:1702911:BlogPost:1381682015-12-22T00:30:00.000ZRubén Peñahttp://www.techhui.com/profile/RubenPena
<p><span class="font-size-4"><strong>SpaceX - Hawthorne, CA & Cape Canaveral, FL</strong></span><br></br> <span class="font-size-4"><strong>December 21, 2015 @ 5:20pm PST = 8:20pm EST = 2:20pm HST…</strong></span></p>
<p></p>
<p><strong><span style="color: #0000ff;"><a href="https://www.linkedin.com/pulse/spacex-makes-history-successfully-relands-first-stage-rub%C3%A9n-pe%C3%B1a" target="_blank"></a></span></strong></p>
<p><span class="font-size-4"><strong>SpaceX - Hawthorne, CA & Cape Canaveral, FL</strong></span><br> <span class="font-size-4"><strong>December 21, 2015 @ 5:20pm PST = 8:20pm EST = 2:20pm HST</strong></span></p>
<p></p>
<p><strong><span style="color: #0000ff;"><a href="https://www.linkedin.com/pulse/spacex-makes-history-successfully-relands-first-stage-rub%C3%A9n-pe%C3%B1a" target="_blank"><span style="color: #0000ff;">https://www.linkedin.com/pulse/spacex-makes-history-successfully-relands-first-stage-rubén-peña</span></a></span><br></strong></p>
<p></p>
<p>SpaceX makes HISTORY a few moments ago today!! SpaceX successfully "Lands" the "Main Stage-1 Falcon9 Rocket" back to Earth at Cape Canaveral, Florida, after liftoff and deployment of 11 ( = 5 pairs + 1 solo ) ORBCOMM-2 satellites!! The Falcon9 "Main Rocket" can now be prepped and *REUSED* for many future space launches, hence astronomically reducing the launch costs and deployment of satellites, cargo and humans into space! This is a serious disruptive technological breakthrough and paradigm shift in Space Exploration and Travel. Not even the NASA Space Shuttle with its launch & landing capabilities was this inexpensive and effortless.</p>
<p></p>
<p style="text-align: center;"><span style="font-family: verdana, geneva;"><strong><span class="font-size-3" style="color: #008000;"><em>This is the beginning of a New Era in</em></span></strong></span></p>
<p style="text-align: center;"><span style="font-family: verdana, geneva;"><strong><span class="font-size-3" style="color: #008000;"><em>Space Exploration and Travel for the</em></span></strong></span></p>
<p style="text-align: center;"><span style="font-family: verdana, geneva;"><strong><span class="font-size-3" style="color: #008000;"><em>Human race!</em></span></strong></span></p>
<p></p>
<p>WOW!! Super cool especially for this to happen right after the "Star Wars" movie release is AWESOME!</p>
<p></p>
<p>After success of the Falcon9 "Main Rocket" landing back in Cape Canaveral, Florida, the entire Family of SpaceX in Hawthorne, CA went <em><strong>*WILD*</strong></em> chanting <em><strong>"USA USA USA USA USA ... !!!!!"</strong></em> Then, the 11 ORBCOMM-2 satellite payloads were deployed out of the Nose (Fairing) by the Stage-2 into their respective orbits around the Earth for the ORBCOMM-2 customer.</p>
<p></p>
<p><strong><span style="color: #0000ff;"><a href="https://www.linkedin.com/pulse/spacex-makes-history-successfully-relands-first-stage-rub%C3%A9n-pe%C3%B1a" target="_blank"><span style="color: #0000ff;">https://www.linkedin.com/pulse/spacex-makes-history-successfully-relands-first-stage-rubén-peña</span></a></span><br></strong></p>
<p></p>
<p>TAGS: SpaceX Falcon9 ORBCOMM-2 Rocket_Landing</p>
<p><a href="http://storage.ning.com/topology/rest/1.0/file/get/396586941?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396586941?profile=RESIZE_1024x1024" width="750" class="align-full"></a></p>Software Developer at Title Guaranty!tag:www.techhui.com,2015-12-09:1702911:BlogPost:1380532015-12-09T00:40:24.000ZDesireehttp://www.techhui.com/profile/Athena
<p>Title Guaranty in downtown Honolulu is currently looking for a couple of Software Developers! Ideal candidate would have a minimum of 2 years of experience with .NET, C#, ASP.net, Microsoft SQL Server and SSRS. </p>
<p></p>
<p>If you are interested, please apply through our website at <a href="http://www.tghawaii.com">www.tghawaii.com</a>.</p>
<p>Title Guaranty in downtown Honolulu is currently looking for a couple of Software Developers! Ideal candidate would have a minimum of 2 years of experience with .NET, C#, ASP.net, Microsoft SQL Server and SSRS. </p>
<p></p>
<p>If you are interested, please apply through our website at <a href="http://www.tghawaii.com">www.tghawaii.com</a>.</p>H-1B Visas: Large firms exploit visa system flaw, exclude start-ups and small firmstag:www.techhui.com,2015-11-12:1702911:BlogPost:1375452015-11-12T02:27:15.000ZJohn Robert Eganhttp://www.techhui.com/profile/JohnEgan
<p>The H-1B visa is commonly known as the Professional Worker's Visa and has been heavily used in the finance and tech industries as a tool for recruiting top international talent into information technology, software engineering and other specialized jobs in the information economy. A recent article in the New York Times, headlined <a href="http://www.nytimes.com/2015/11/11/us/large-companies-game-h-1b-visa-program-leaving-smaller-ones-in-the-cold.html" rel="nofollow" target="_blank">"Large…</a></p>
<p>The H-1B visa is commonly known as the Professional Worker's Visa and has been heavily used in the finance and tech industries as a tool for recruiting top international talent into information technology, software engineering and other specialized jobs in the information economy. A recent article in the New York Times, headlined <a href="http://www.nytimes.com/2015/11/11/us/large-companies-game-h-1b-visa-program-leaving-smaller-ones-in-the-cold.html" target="_blank" rel="nofollow">"Large Companies Game H-1B Visa Program"</a> details the process whereby a small number of outsourcing companies have successfully exploited a flaw in the way the visa system is operated to capture a disproportionate share of the annual quota of these visas. The result is that small firms, start-ups and other legitimate applicants are being squeezed out of the program.</p>
<p>This matters very much to business in places like Hawaii, where essentially all of our businesses are small, relatively speaking, and concerted efforts are underway to foster a viable tech business community. Local entrepreneurs find themselves locked out of the international talent pool, and our academic engineering programs, where upwards of 50% of graduating PhD students are foreign students, cannot place their best students into local jobs. This in turn impacts <a href="http://www.civilbeat.com/2013/11/20479-hawaii-loses-money-as-international-student-population-shrinks/" target="_blank" rel="nofollow">the ability of local universities and colleges to recruit foreign students</a>. Places like Hawaii <a href="http://www.kauffman.org/what-we-do/research/2014/03/lessons-for-us-metro-areas-characteristics-and-clustering-of-high-tech-immigrant-entrepreneurs" target="_blank" rel="nofollow">need to be talent magnets to compete in the global marketplace,</a> but need a level playing field to stay in the game.</p>
<p>The visa system flaw is quite simple. Individuals may only submit a single application, duplicates are rejected. Firms on the other hand, may submit as many applications as they wish, as long as each is for a single individual. So the large outsourcing firms working the visa game make job offers to literally thousands of workers, predominately in India, contingent on getting a visa. They know they will receive only third of these, but are able to spread the costs over the whole field of newly visaed workers as they place them in batches into contract labor positions for companies such as Disney and Toy R Us.</p>
<p>Why does this disadvantage small firms? A small innovative start-up is looking for the one "best fit" team member who adds a specific talent or expertise to the enterprise build-out. Each highly skilled tech worker on the start-up team is a key component of the product or service development process. A one-in-three chance of success in obtaining a working visa for your employee of choice introduces additional costs and a frustrating uncertainty and instability into the human resources scaling process. For the outsourcing firms on the other hand, skilled workers are the product itself, and at the level they operate on, are essentially fungible. Functioning as high tech temp agencies, they are renting out a generic skill-set and resume, that just incidentally has a human being attached to it.</p>
<p>The entire U.S. employment visa system is ripe for reform, but the political action needed does not look likely in the near term. With the types of exploitation being practiced by the outsourcing firms, along with the many other negative effects of visa abuse, the whole H-1B visa program is getting a bad name.</p>
<p><em>John Robert Egan is an Immigration Lawyer practicing in Honolulu, and can be reached at <a target="_blank" rel="nofollow">jegan@migrationcounsel.com</a></em></p>Free Developer Tools on Windowstag:www.techhui.com,2015-08-14:1702911:BlogPost:1353462015-08-14T03:30:00.000ZDouglas Chinghttp://www.techhui.com/profile/DouglasChing
<p>It used to be that to develop with Microsoft technologies developers would have to pay up for development tools if they wanted the best experience. These days with all the options developers have, getting someone to pay for tools can be difficult.<br></br> <br></br> Recently I wiped of one of my development machines and realized this is no longer the case while installing various tools. <br></br> <br></br> It's well known that Microsoft has been moving towards open sourcing many of their projects like…</p>
<p>It used to be that to develop with Microsoft technologies developers would have to pay up for development tools if they wanted the best experience. These days with all the options developers have, getting someone to pay for tools can be difficult.<br/> <br/> Recently I wiped of one of my development machines and realized this is no longer the case while installing various tools. <br/> <br/> It's well known that Microsoft has been moving towards open sourcing many of their projects like their .net framework, but beyond that they have also been providing more options for free tools and services. To be clear many of these free tools are aimed toward home users, individuals and small teams. Larger businesses still need to pay for the appropriate licensed product.<br/> <br/> <strong>Windows 10</strong></p>
<p>Microsoft has made Windows 10 a free upgrade (if you upgrade within the offer's time period) for individual users who have Windows 7 or Windows 8. When Windows 8 came out one of the major developer complaints is that in order to develop for Windows 8 and the new Windows Store you needed a machine with Windows 8. That meant buying a new computer or paying for a Windows 8 license. By making Windows 10 free for Windows 7 and 8 users Microsoft is trying to lower the barrier for developers.<br/> <br/> <strong>Visual Studio</strong><br/> <a href="http://www.visualstudio.com">http://www.visualstudio.com</a></p>
<p>I remember having to purchase Visual Studio or MSDN just to get Visual Studio. A free Visual Studio is not new. Ever since 2010 Microsoft has offered Express versions of Visual Studio, but they were always heavily restricted in features. At the end of 2014 Microsoft started offering Visual Studio Community 2013 for free. The Community edition is very close to the Professional version and can be used by "individual developers, open source projects, academic research, training, education and small professional teams". VS.net Community 2015 also includes features that allow developers to create Android and other non-Windows apps as well as Data Tools that have usually been reserved for the higher level versions.<br/> <br/> <strong>Visual Studio Code</strong><br/> <a href="http://www.visualstudio.com/products/code-vs.aspx">http://www.visualstudio.com/products/code-vs.aspx</a></p>
<p>Visual Studio Code is a code editor that is cross platform (Windows, OSX, Linux). It is not like Visual Studio. Instead it is similar to other code editors like Sublime, Atom and Brackets. It is based around the same code that the Atom editor (atom.io) uses. Why would someone use VS Code? The main reason would be because it is built to work well with ASP.NET 5 which is also planned to work on Windows, OSX and Linux when released. That's not to say it doesn't work well with other development frameworks. I've used VS Code to update Node, TypeScript and Python and it plays well with many other languages.<br/> <br/> <strong>SQL Server</strong><br/> <a href="http://www.microsoft.com/en-us/server-cloud/products/sql-server-editions/sql-server-express.aspx">http://www.microsoft.com/en-us/server-cloud/products/sql-server-editions/sql-server-express.aspx</a></p>
<p>SQL Server has always been a tough one to get for free. There has been various free versions available over the years, but they have always been very lacking and it's always been hard to get the management tools without getting your hands on one of the full versions. Over the years the Express version has gotten better and with the current SQL Server Express version developers can get functionality that is close to the full versions, but with restricted database size, CPU and memory utilization. They have also made available the management studio that allows developers to manage SQL databases.<br/> <br/> Of course SQL Server Express isn't going to include many of the advanced features of SQL Server. For developers who do need SQL Server that matches production environments closely Microsoft still sells SQL Server Developer edition <a href="http://www.microsoftstore.com/store/msusa/en_US/pdp/SQL-Server-2014-Developer-Edition/productID.298540400">http://www.microsoftstore.com/store/msusa/en_US/pdp/SQL-Server-2014-Developer-Edition/productID.298540400</a><br/> <br/> <strong>Azure</strong><br/> <a href="http://azure.microsoft.com">http://azure.microsoft.com</a></p>
<p>For developers who build web apps or services Microsoft offers some free Azure services. In particular you can publish 10 web sites to Azure for free. It's a good service to use for web site development if you don't want to pay for hosting.<br/> <br/> <strong>Other Great Tools</strong><br/> Besides the Microsoft backed tools above there are a lot of other free tools that I use.<br/> <br/> <strong>GitHub Desktop</strong><br/> <a href="https://desktop.github.com/">https://desktop.github.com/</a></p>
<p>Git has become the source control of choice for many developers. I like GitHub Destkop because it's easy to install and easy to use. If you are someone that doesn't like the command line this one is a good Git client, however it would still benefit you to learn the git command line commands.<br/> <br/> <strong>Atom</strong><br/> <a href="https://atom.io/">https://atom.io/</a></p>
<p>Atom has become my favorite code editor that is not a full fledged IDE.<br/> <br/> <strong>Notepad++</strong><br/> <a href="https://notepad-plus-plus.org/">https://notepad-plus-plus.org/</a></p>
<p>Every developer who has used Windows has probably downloaded Notepad++. It's the app I install to avoid having to use Notepad. Even though I don't use it for coding I like it as a quick editor.</p>
<p></p>
<p>I'd be interested in hearing if anyone has any other good developer tools for Windows or what tools developers on OSX and Linux love to use.</p>Our Immigration System Sucks – Is There a Tech Fix?tag:www.techhui.com,2015-08-07:1702911:BlogPost:1353392015-08-07T20:19:51.000ZJohn Robert Eganhttp://www.techhui.com/profile/JohnEgan
<p>Sooner or later, everyone who is in the tech field for the long run bumps up against the U.S. immigration system. The tech talent pool is global, our engineering schools have plenty of international grads looking to be placed into U.S. jobs, and smart international investors are looking for U.S. tech entrepreneurs to back. And the unanimous reaction to the immigration encounter is “the U.S. immigration system really sucks!”</p>
<p>A …</p>
<p>Sooner or later, everyone who is in the tech field for the long run bumps up against the U.S. immigration system. The tech talent pool is global, our engineering schools have plenty of international grads looking to be placed into U.S. jobs, and smart international investors are looking for U.S. tech entrepreneurs to back. And the unanimous reaction to the immigration encounter is “the U.S. immigration system really sucks!”</p>
<p>A <a href="http://www.wired.com/2015/07/us-digital-service-immigration/http://" target="_blank">recent article in Wired</a> skips over the convoluted politics of immigration reform (it’s really going nowhere) and looks at recent attempts by the federal <a href="https://playbook.cio.gov/" target="_blank">U.S. Digital Service</a> to tech-up the process itself. On first glance, they were floored by the amount of paper (yes, ground-up dead trees are still the foundational mode of communication in the immigration system) being shuffled from office to office. And then they looked at the heavily silo-ed transactional processes that prevent effective collaboration and information sharing, and began to recognize just how entrenched and calcified existing bad practices have become.</p>
<p>So have the engineers got a fix for all this? Let’s hope so, but I’m not holding my breath. The <a href="https://www.whitehouse.gov/blog/2015/07/15/bringing-our-immigration-system-digital-age" target="_blank">report delivered to the White House</a> sums up the present state of affairs pretty accurately - “currently, applicants face unnecessary ambiguity and confusion around how each step in the application process fits into the process as a whole, and lack of awareness of how to succeed.” I think if the Digital Service succeeds in their task of rationalizing and digitizing the immigration system there will be a whole lot less need for immigration lawyers like me to lead clients through the maze. Which, truth be told, would be a very good thing for everyone involved. Higher productivity, increased transparency, better predictability for innovative start-ups, and lower transactional costs overall can’t be bad. And I expect to be retired by then.</p>Continuous Delivery with WordPresstag:www.techhui.com,2015-08-03:1702911:BlogPost:1322492015-08-03T18:48:50.000ZDavid Chunghttp://www.techhui.com/profile/DavidChung
<p>As a continuation of my blog posts regarding continuous delivery, I shall explore the continuous delivery options for WordPress websites since I was recently been involved in such a project.</p>
<p>One changing component of a WordPress website is its templates, which are written in PHP. This PHP source can be version controlled quite easily and integrated with a continuous delivery system.</p>
<p>However, another changing component of a WordPress website is its plugins and their…</p>
<p>As a continuation of my blog posts regarding continuous delivery, I shall explore the continuous delivery options for WordPress websites since I was recently been involved in such a project.</p>
<p>One changing component of a WordPress website is its templates, which are written in PHP. This PHP source can be version controlled quite easily and integrated with a continuous delivery system.</p>
<p>However, another changing component of a WordPress website is its plugins and their configurations, which are stored in the database. Version control of these configurations will require managing the data.</p>
<h1>WordPress Hurdles</h1>
<p>Continuous delivery with WordPress is made difficult with the fact that its configuration is done through the database exclusively with the exception of the configuration of connecting to the database itself.</p>
<p>Another hurdle is that the content is not easily manageable.</p>
<p>For continuous delivery, you will rebuild the WordPress website using a specified core version, a specified list of plugins to install, a version-controlled database, and a maintained uploaded content directory.</p>
<h1>Version Control</h1>
<p>The branching strategy here would be similar to that mentioned in <a href="http://www.techhui.com/profiles/blogs/continuous-delivery-with-ruby-on-rails-and-heroku/" target="_blank">my continuous delivery post with Ruby on Rails and Heroku</a>.</p>
<p>Since the WordPress website is being built from scratch and WordPress is unfortunately configured via database entries, the following should be in version control:</p>
<ul>
<li>the MySQL database dump</li>
<li>list of plugins need</li>
<li>URL to desired WordPress core to install</li>
</ul>
<p><br/> The MySQL database dump should also include DROP TABLE statements. Simply run mysqldump with default settings to generate such a dump.<br/> <br/> The plugins list is simply a text file containing the URLs to the plugin zip file separated by newlines. Unless a specific version is needed, the plugins need to point to the URL that contains the latest plugin zip file. For example, use “<a href="https://downloads.wordpress.org/plugin/some-plugin.zip">https://downloads.wordpress.org/plugin/some-plugin.zip</a>” instead of “<a href="https://downloads.wordpress.org/plugin/some-plugin-1.0.0.zip">https://downloads.wordpress.org/plugin/some-plugin-1.0.0.zip</a>.”</p>
<h1>Continuous Integration</h1>
<p>The build server needs the following, which doesn’t necessarily need to be in version control:</p>
<ul>
<li>Apache server with mod_rewrite</li>
<li>MySQL with a database for the project</li>
<li>PHP with the appropriate Apache modules</li>
<li>.htaccess file for the web root directory containing:<ul>
<li><IfModule mod_rewrite.c></li>
<li>RewriteEngine On</li>
<li>RewriteBase /{root}</li>
<li>RewriteRule ^index\.php$ - [L]</li>
<li>RewriteCond %{REQUEST_FILENAME} !-f</li>
<li>RewriteCond %{REQUEST_FILENAME} !-d</li>
<li>RewriteRule . /{root}/index.php [L]</li>
<li></IfModule></li>
</ul>
</li>
<li>A zip file containing the uploaded content</li>
<li>wp-config.php containing the necessary database credentials</li>
</ul>
<p>However, we maintain the following in version control:</p>
<ul>
<li>data.sql (the MySQL database dump from above)</li>
<li>wordpress (single line of WP URL to download and install)</li>
<li>plugins (multiple lines of plugin URLs to download and install)</li>
<li>wp-content/ (your work)</li>
</ul>
<p>And so, the following is a suggested build configuration:</p>
<ol>
<li>Clear out the target test web directory (for websites with large content, you may want to move the contents directory: wp-content/uploads to restore later to speed up the process)</li>
<li>Download the latest WordPress core at: <a href="https://wordpress.org/latest.tar.gz">https://wordpress.org/latest.tar.gz</a></li>
<li>If the project requires a specific WordPress core version, find what you need here: <a href="https://wordpress.org/download/release-archive/">https://wordpress.org/download/release-archive/</a></li>
<li>Extract the WordPress core to the target test web directory</li>
<li>Copy the held wp-config.php to the root of the target test web directory</li>
<li>Copy the work to the target test web directory</li>
<li>For each entry in the plugins list, download and extract the plugin to the wp-contents/plugins directory</li>
<li>Extract the uploaded content and copy it to the wp-content/uploads directory</li>
<li>Populate the test database with the database dump in version control</li>
<li>Output the URL to access the test WordPress website.</li>
</ol>
<p><br/> After a successful build, the build server should have a working WordPress website in some web directory. The build configuration should provide the URL for a user to access for testing.<br/> <br/> To ease the development and deployment process, consider making use of development and release branches.</p>
<h1>Development Branch</h1>
<p>The development branch shall attempt to provide the opportunity for developers to sync with production content.<br/> <br/> The build configuration is modified to also include the step of downloading the uploads directory and obtain a database dump from the production site. These artifacts are then stored on the build server for retrieval and possible integration with the codebase.<br/> <br/> Specifically, regarding the database:</p>
<ol>
<li>The build configuration uses the data dump in version control first to apply any non-WordPress data.</li>
<li>Then the build configuration will use the data dump from production to populate the WordPress data.</li>
<li>Finally, the build configuration dumps the resulting database from the above and stores it as a build artifact.</li>
<li>Developers then use this artifact to synchronize the data dump in version control so that developers working off from the development branch can have access to the latest production data (note that this data does not necessarily include content)</li>
</ol>
<h1>Staging Branch</h1>
<p>The staging branch shall include database configuration changes to be deployed to production.<br/> <br/> The build configuration is similar to the development branch’s build configuration except that it doesn’t sync with the production database since the staging environment is intended to replace what’s currently in production. Thus, the staging environment is meant to stage the next production iteration.<br/> <br/> In lieu of an explicit staging branch, the development branch can be used. In this case, there would be two build configurations: one for development that syncs its database with what’s in production and the other for staging that does not sync with the production database.</p>
<h1>Master Branch</h1>
<p>Note that the build configuration in the development branch does not affect the volatile data in production. That is, the uploads directory or the database.<br/> <br/> However, the release branch is an opportunity for developers to push their changes to production as a deployment even in the database!<br/> <br/> The build configuration for the release branch blows away the current instance and builds the site from scratch.<br/> <br/> Thus, the flow for a deployment is to synchronize the development branch with production and then trigger the release.<br/> <br/> The build configuration shall keep a running backup of current data dumps before running the deployment so that the instance can be rolled back as needed.</p>Celebrating...tag:www.techhui.com,2015-06-30:1702911:BlogPost:1346902015-06-30T13:30:00.000ZRobert J. Vitellohttp://www.techhui.com/profile/RobertJVitello
<p>We’re celebrating our having picked up two more engagements in June, for the States of Georgia and Oklahoma, with a tip of the hat to Andrew Hoppin (NuCivic.com) who, several years ago, got me focused on a business model based on long distance, distributed project teams. Justin, of course, continues to do the heavy lifting.</p>
<p>Lately I’ve been reviewing issues of long distance worker health and safety, and of information security with respect to access to corporate information from the…</p>
<p>We’re celebrating our having picked up two more engagements in June, for the States of Georgia and Oklahoma, with a tip of the hat to Andrew Hoppin (NuCivic.com) who, several years ago, got me focused on a business model based on long distance, distributed project teams. Justin, of course, continues to do the heavy lifting.</p>
<p>Lately I’ve been reviewing issues of long distance worker health and safety, and of information security with respect to access to corporate information from the remote locations where our developers reside. These are topics that are easily overlooked as time passes. It’s easy, with so many other concerns in the forefront, to grow complaisant and think that health, safety, and security have all been addressed and are just fine. That’s why they need periodic re-examination.</p>
<p>Occupational health and safety is not a direct responsibility of ours. The workers we collaborate with are usually employees of governmental or corporate clients. And aside from the on-line resources we provide in some engagements, most security concerns surround the data holdings of our clients and is a separate responsibility of theirs. Nonetheless, these are issues we look at because they are factors in the successful outcome of the projects we manage, and in the well-being of the workers we depend upon.</p>
<p>We’re celebrating because we are building an ethical and empathetic practice, and because concern over all of the aspects of our projects is not going unnoticed. We’re celebrating because our skill at managing distributed teams continues to grow stronger. We’re celebrating because the road we’re taking is paying rich dividends for all of our partners and clients, and certainly for us.</p>
<p></p>
<p><a href="http://storage.ning.com/topology/rest/1.0/file/get/396586786?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396586786?profile=original" width="559" class="align-left"></a></p>HTDC is looking for qualified business mentors to assist innovate small businesses on the islands of Maui, Hawaii Island, and Kauai!tag:www.techhui.com,2015-06-27:1702911:BlogPost:1345232015-06-27T01:33:51.000ZCindy Matsukihttp://www.techhui.com/profile/CindyMatsuki13
<p>Hi TechHui! I wanted to let you know that HTDC has an RFP out, looking for business mentors on Maui, Hawaii Island, and Kauai, to help small businesses grow as well as to represent HTDC. If you are interested, please check out the <a href="http://www.spo3.hawaii.gov/notices/notices/rfp-16-001-htdc" target="_blank">RFP</a>. Please forward to anyone you think might be interested as well! Last chance to ask questions regarding…</p>
<p>Hi TechHui! I wanted to let you know that HTDC has an RFP out, looking for business mentors on Maui, Hawaii Island, and Kauai, to help small businesses grow as well as to represent HTDC. If you are interested, please check out the <a href="http://www.spo3.hawaii.gov/notices/notices/rfp-16-001-htdc" target="_blank">RFP</a>. Please forward to anyone you think might be interested as well! Last chance to ask questions regarding <a href="http://www.spo3.hawaii.gov/notices/notices/rfp-16-001-htdc" target="_blank">the RFP</a> is next week Tuesday. </p>
<p>Much aloha!</p>
<p>Cindy</p>JavaScript Game Enginestag:www.techhui.com,2015-06-17:1702911:BlogPost:1343212015-06-17T21:52:54.000ZDouglas Chinghttp://www.techhui.com/profile/DouglasChing
<p dir="ltr"><span>Recently I’ve been interested in games created using JavaScript. JavaScript is everywhere and works with a lot of devices and platforms including mobile devices that run on iOS, Android, Windows and FirefoxOS. On the web seems that games using HTML and JavaScript have started to replace those using older technologies like Flash. Here is a list of JavaScript libraries that I have seen recommended for creating games. To compile this list I looked at libraries that are free,…</span></p>
<p dir="ltr"><span>Recently I’ve been interested in games created using JavaScript. JavaScript is everywhere and works with a lot of devices and platforms including mobile devices that run on iOS, Android, Windows and FirefoxOS. On the web seems that games using HTML and JavaScript have started to replace those using older technologies like Flash. Here is a list of JavaScript libraries that I have seen recommended for creating games. To compile this list I looked at libraries that are free, preferably open source, actively updated and focuses mainly on 2D.</span></p>
<p><span><span><br/><br/></span></span></p>
<p dir="ltr"><strong>CreateJS</strong></p>
<p dir="ltr"><a href="http://createjs.com/"><span>http://createjs.com/</span></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>CreateJS is a suite of libraries that can be used to create interactive content using HTML5 and JavaScript. CreateJS is composed of several separate libraries: EaselJS, TweenJS, SoundJS and PreloadJS to handle functionality commonly needed in games and animation. Unlike the other libraries in this list CreateJS isn’t targeted at creating games. Instead it seem like it’s goal is closer to being a Flash replacement. It also has many integrations with tools. Adobe Flash CC is able to export directly to CreateJS.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>CraftyJS</strong></p>
<p dir="ltr"><a href="http://craftyjs.com/"><span>http://craftyjs.com/</span></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>CraftyJS is a Javascript game engine that describes itself as a “flexible framework for Javascript games”. It features:</span></p>
<ol>
<li dir="ltr"><p dir="ltr"><span>OpenSource</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Works with all modern browsers including IE9</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Uses Cavas or DOM to render entities</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Small file size</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Sprit map support</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Collision detection</span></p>
</li>
</ol>
<p><span><span> </span></span></p>
<p dir="ltr"><span><strong>Pixi.js</strong></span></p>
<p dir="ltr"><a href="https://github.com/GoodBoyDigital/pixi.js"><span>https://github.com/GoodBoyDigital/pixi.js</span></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Pixi.js is a lightweight 2D library that uses WebGL, falls back on Canvas and boasts fast performance for both. Some game engines make use of Pixi.js’ strong 2D support. Some of the features include:</span></p>
<p><span><span> </span></span></p>
<ol>
<li dir="ltr"><p dir="ltr"><span>Asset loader / sprite sheet loader</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Masking</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Filters</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Easy to use API</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Full mouse and multi-touch interaction</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>WebGL and Canvas rendering</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Texture atlases</span></p>
</li>
</ol>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Kiwi.js</strong></p>
<p dir="ltr"><a href="http://www.kiwijs.org/"><span>http://www.kiwijs.org/</span></a></p>
<p dir="ltr"></p>
<p dir="ltr"><span>Kiwi.js is a fun and friendly open source HTML5 game engine. Some of Kiwi.js’ features include:</span></p>
<p><span><span> </span></span></p>
<ol>
<li dir="ltr"><p dir="ltr"><span>Canvas and WebGL rendering</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Support for spritesheets, texture atlases and individual images</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Entity/Component system</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Multitouch support</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>State management</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>File management and loading</span></p>
</li>
</ol>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Melon.js</strong></p>
<p dir="ltr"><span><a href="http://melonjs.org/">http://melonjs.org/</a></span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Melon.js is a free, open source light weigh JavaScript game engine. Some of its features include:</span></p>
<p><span><span> </span></span></p>
<ol>
<li dir="ltr"><p dir="ltr"><span>Lightweight physic implementation</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Collision detection</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Tween effects</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Transition effects</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Basic particle system</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Spritesheet and packed texture support</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>State manager</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Tile map integration</span></p>
</li>
</ol>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Panda</strong></p>
<p dir="ltr"><a href="http://www.pandajs.net/"><span>http://www.pandajs.net/</span></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Panda is a free HTML5 game engine. It features:</span></p>
<p><span><span> </span></span></p>
<ol>
<li dir="ltr"><p dir="ltr"><span>Canvas/WebGL rendering</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Particle engine</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Tweening</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Physics engine</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Timers</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Sound manager</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Ability to organize code in modules</span></p>
</li>
</ol>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Phaser</strong></p>
<p dir="ltr"><a href="https://phaser.io/"><span>https://phaser.io/</span></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Phaser is a fast, free and fun open source framework for games. Phaser is popular on GitHub. One thing that interests me about Phaser is it is one of the few game engines that has a set up guide using TypeScript. Some of Phaser’s features include:</span></p>
<p><span><span> </span></span></p>
<ol>
<li dir="ltr"><p dir="ltr"><span>WebGL & Canvas</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Preloader</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Physics</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Sprites</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Animation</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Particles</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Tilemaps</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Camera</span></p>
</li>
<li dir="ltr"><p dir="ltr"><span>Plugin system</span></p>
</li>
</ol>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Quintus</strong></p>
<p dir="ltr"><a href="http://www.html5quintus.com/"><span>http://www.html5quintus.com/</span></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Quintus is an “easy-to-learn, fun-to-use” JavaScript HTML5 game engine. Quintus seems to be a younger library, but I’ve seen it mentioned on several sites. Quintus also seems to cover the basics of a game engine, but is not as full-featured or refined as other game engines on this list.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Stage.js</strong></p>
<p dir="ltr"><a href="http://piqnt.com/stage.js/"><span>http://piqnt.com/stage.js/</span></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Stage.js is a 2D HTML5 JavaScript game engine that is lightweight, fast and open source. Stage.js seems to include many of the basics for a game engine including the game loop, events, support for mouse and touch, texture atlas, images, animation and tweening. </span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>In the future I hope to pick a few of these and hopefully one day create a simple game. If anyone knows of any good JavaScript game engines that are not on this list please let me know.</span></p>
<p><span> </span></p>Spaceballstag:www.techhui.com,2015-06-08:1702911:BlogPost:1340392015-06-08T10:00:00.000ZDavid Chunghttp://www.techhui.com/profile/DavidChung
<p>I like to hone my problem-solving skills by going over some programming contest questions and I also like to use programming contest problems in interviews because it allows me to gauge whether the candidate is a just a coder or a problem solver. That's not to say that if you can't come up with a correct solution, you aren't a problem solver -- if I'm the interviewer, I'm more interested in how you approach the problem and whether you can break up and present the problem in an abstract…</p>
<p>I like to hone my problem-solving skills by going over some programming contest questions and I also like to use programming contest problems in interviews because it allows me to gauge whether the candidate is a just a coder or a problem solver. That's not to say that if you can't come up with a correct solution, you aren't a problem solver -- if I'm the interviewer, I'm more interested in how you approach the problem and whether you can break up and present the problem in an abstract manner.</p>
<p>So here is a programming contest problem I used recently in an interview: <a href="http://acm.student.cs.uwaterloo.ca/~acm00/150131/A-ack.pdf" target="_blank">Spaceballs</a>! My <a href="https://cs.uwaterloo.ca/" target="_blank">Alma Mater</a> hosts <a href="http://acm.student.cs.uwaterloo.ca/" target="_blank">programming contests</a> and this was one of the recent problems.</p>
<p>In case the link breaks, here is the problem:</p>
<blockquote><p>Juliet reads an interesting sci-fi book. In one chapter, the main character needs to solve a problem of maximizing the utilization of cargo spaceships. The ships transport valuable items that have the form of D-dimensional mesh with the size of 3 nodes in each dimension. The nodes are formed by balls of the same weight. The connections between balls are so light that their weight is negligible compared to the weight of balls. This means that the weight of any item is determined solely by the number of its nodes. On the other hand, the value of such an item is equal to the number of nodes plus the number of connections.</p>
<p>Zero Dimension (Weight = 1, Price = 1)<br/> First Dimension (Weight = 3, Price = 5)<br/> Second Dimension (Weight = 9, Price = 21)</p>
<p>Each spaceships has a limited tonnage and we want to maximize the total value of items that maybe stored in the ship without exceeding the tonnage. Your task is to decide what items of what dimension should be loaded to maximize their total value, providing that we have an unlimited supply of items of all dimensions</p>
<p><strong>Input Specification:</strong></p>
<p>The first line of the input contains the number of test cases N. Each test case then consists of a single line containing one positive integer number K < 10,000,000 giving the ship cargo capacity.</p>
<p><strong>Output Specification:</strong></p>
<p>For each test case, print one line containing space-separated non-negative numbers Xm Xm−1 . . . X1 X0, where Xm > 0 and Xi (0 ≤ i ≤ m ) is the number of items of the i-th dimension that we need to store to maximize their total value.</p>
<p><strong>Sample Input:</strong><br/> 4<br/> 1<br/> 100<br/> 175<br/> 9841</p>
<p><strong>Output of Sample Input:</strong><br/> 1<br/> 1 0 2 0 1<br/> 2 0 1 1 1<br/> 1 1 1 1 1 1 1 1 1</p>
</blockquote>
<p>In this blog post, I shall go over what my proposed solution would look like in at most pseudo-code.</p>
<p>The first step is the understand what the problem is asking for. Given a number of nodes, K, we want to assign them into dimension containers, Xm, such that the maximum value is achieved.</p>
<p>For example, looking at the second sample test case, K = 100: X0 = 1, with a total weight of 1; X2 = 2, with a total weight of 18; X4 = 1, with a total weight of 81. So 1 + 18 + 81 = 100 = K. Notice that I didn't even look at the value. It's obvious that higher dimensions have greater value and so we want to fit the balls from high to low dimension to achieve the greatest value.</p>
<p>Each dimension adds a mesh of 3 nodes. So each dimension holds 3^i balls. So, X0 holds 3^0 = 1, X1 holds 3^1 = 3, X2, holds 3^2 = 9, X3 holds 3^3 = 27.</p>
<p>The problem also has a cap for K. 3^15 = 14,348,907, which exceeds the cap. Therefore, the highest dimension that a cargo ship can hold is 3^14 = 4,782,969.</p>
<p>So we really have 15 buckets that can be filled with i-th dimension cargo. If we see the problem as receiving K balls, then every time an i-th dimension bucket is used, 3^i balls are consumed from K as stored balls.</p>
<p>Starting from the highest 14th dimensional bucket, we will attempt to consume the remaining balls without going negative. If we can't, then we will go down a dimension and see if that dimension is able to consume. We will continue to consume balls until we reach zero balls. The 0-th dimension consumes single balls so we will eventually achieve this.</p>
<p>So here is my pseudo-code of my solution:</p>
<p><span style="font-family: terminal,monaco;">SolveSpaceballs(K)</span></p>
<p><span style="font-family: terminal,monaco;"># The dimensional buckets</span></p>
<p><span style="font-family: terminal,monaco;">X = X[14]</span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"># Start at the 14th dimension</span></p>
<p><span style="font-family: terminal,monaco;">i = 14</span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"># Track how many balls were consumed</span></p>
<p><span style="font-family: terminal,monaco;">L = K</span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"># Loop until all balls are consumed</span></p>
<p><span style="font-family: terminal,monaco;">while L > 0</span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"> <span style="font-family: terminal,monaco;"># If we can consume 3^i balls...</span><br/> if L <= 3^i<br/></span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"> # Then we will use this bucket</span></p>
<p><span style="font-family: terminal,monaco;"> X[i] += 1 <br/></span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"> # We consumed 3^i balls</span></p>
<p><span style="font-family: terminal,monaco;"> L -= 3^i</span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"> else</span></p>
<p></p>
<p><span style="font-family: terminal,monaco;"> # Otherwise, we will move to the next bucket down</span></p>
<p><span style="font-family: terminal,monaco;"> i -= 1</span></p>
<p><span style="font-family: terminal,monaco;">END</span></p>
<p>The solution fills the buckets with the number of times it is used. We can iterate through the buckets and print out its value as per specification so that we start from the 14th dimension and skip the element until we reach a non-zero bucket to begin printing values.</p>
<p>So let's run the test cases:</p>
<p><strong>K = 1</strong></p>
<p>Loop and decrement i until i = 0 where 3^0 = 1 and increment X[0] = 1 for a final result of:</p>
<p>[1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]</p>
<p>Output: 1</p>
<p></p>
<p><strong>K = 100</strong></p>
<p>Loop and decrement i until i = 4 where 3^4 = 81 and increment X[4] = 1 leaving L = 19.</p>
<p>Loop and decrement i until i = 2 where 3^2 = 9 and increment X[2] = 1 leaving L = 10.</p>
<p>Loop but L can still be consumed by 3^2 so increment X[2] = 2 leaving L = 1.</p>
<p>Loop and decrement i until i = 0 where 3^0 = 1 and increment X[0] = 1 for a final result of:</p>
<p>[1, 0, 2, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0]</p>
<p>Output: 1, 0, 2, 0, 1</p>
<p></p>
<p><strong>K = 175</strong></p>
<p>Loop and decrement i until i = 4 where 3^4 = 81 and increment X[4] = 1 leaving L = 94.</p>
<p>Loop but L can still be consumed by 3^4 so increment X[4] = 2 leaving L = 13.</p>
<p>Loop and decrement i until i = 2 where 3^2 = 9 and increment X[2] = 1 leaving L = 4.</p>
<p>Loop and decrement i until i = 1 where 3^1 = 3 and increment X[1] = 1 leaving L = 1.</p>
<p>Loop and decrement i until i = 0 where 3^0 = 1 and increment X[0] = 1 for a final result of:</p>
<p>[1, 1, 1, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0]</p>
<p>Output: 2, 0, 1, 1, 1</p>
<p></p>
<p><strong>K = 9841</strong></p>
<p>Loop and decrement i until i = 8 where 3^8 = 6561 and increment X[8] = 1 leaving L = 3280.</p>
<p>Loop and decrement i until i = 7 where 3^7 = 2187 and increment X[7] = 1 leaving L = 1093.</p>
<p>Loop and decrement i until i = 6 where 3^6 = 729 and increment X[6] = 1 leaving L = 364.</p>
<p>Loop and decrement i until i = 5 where 3^5 = 243 and increment X[5] = 1 leaving L = 121.</p>
<p>Loop and decrement i until i = 4 where 3^4 = 81 and increment X[4] = 1 leaving L = 40.</p>
<p>Loop and decrement i until i = 3 where 3^3 = 27 and increment X[3] = 1 leaving L = 13.</p>
<p>Loop and decrement i until i = 2 where 3^2 = 9 and increment X[2] = 1 leaving L = 4.</p>
<p>Loop and decrement i until i = 1 where 3^1 = 3 and increment X[1] = 1 leaving L = 1.</p>
<p>Loop and decrement i until i = 0 where 3^0 = 1 and increment X[0] = 1 for a final result of:</p>
<p>[1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0]</p>
<p>Output: 1, 1, 1, 1, 1, 1, 1, 1, 1</p>
<p></p>
<p>I am curious what others think of this problem and other approaches to this problem. I thought this problem was pretty straight-forward but a common pitfall is reading too much into the i-th dimension value and the i-th dimension itself.</p>Where to worktag:www.techhui.com,2015-04-27:1702911:BlogPost:1343552015-04-27T13:15:57.000ZRobert J. Vitellohttp://www.techhui.com/profile/RobertJVitello
We work on long distance projects from home offices. We should have invested in solar years ago. Now Hawaii Electric is telling us we'll have no power as they replace telephone poles in our area. We're scrambling to find a place with access to the Internet from where we can participate in Skype and GoToMeeting scrums. Any ideas?
We work on long distance projects from home offices. We should have invested in solar years ago. Now Hawaii Electric is telling us we'll have no power as they replace telephone poles in our area. We're scrambling to find a place with access to the Internet from where we can participate in Skype and GoToMeeting scrums. Any ideas?A Look at Windows 10 Technical Preview Build 10061tag:www.techhui.com,2015-04-23:1702911:BlogPost:1343512015-04-23T22:50:38.000ZDouglas Chinghttp://www.techhui.com/profile/DouglasChing
<p dir="ltr">In my <a href="http://www.techhui.com/profiles/blogs/windows-phone-10-tech-preview-and-experience-using-windows-phone" target="_blank">last blog post</a> I wrote about Windows 10 preview for phones. Yesterday Microsoft released the latest technical preview for Windows 10 on desktops, build 10061. With the rumored end of July release date of Windows 10 here is a look at where Windows 10 is today. The current build is the most refined one yet, but is still very buggy and…</p>
<p dir="ltr">In my <a href="http://www.techhui.com/profiles/blogs/windows-phone-10-tech-preview-and-experience-using-windows-phone" target="_blank">last blog post</a> I wrote about Windows 10 preview for phones. Yesterday Microsoft released the latest technical preview for Windows 10 on desktops, build 10061. With the rumored end of July release date of Windows 10 here is a look at where Windows 10 is today. The current build is the most refined one yet, but is still very buggy and hopefully many things will be fixed and updated before final release. One thing that is pretty neat about Windows 10 development is Microsoft released the builds early over the last year and has actually made updates based on user feedback.</p>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Start Menu vs Start Page</strong></p>
<p dir="ltr"><span>The most noticeable change from Windows 8 to Windows 10 that people will look for is probably going to be the Start Menu. Windows 8 removed the Start Menu and replaced it with a Start Page and that did not go over very well.</span></p>
<p><span><span> </span></span></p>
<p><span><span><a href="http://storage.ning.com/topology/rest/1.0/file/get/396586803?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396586803?profile=original" width="600" class="align-center"></a></span></span></p>
<p></p>
<p dir="ltr"><span>In Windows 10 the Start Menu is back. It no longer takes up the entire screen. Users can resize the menu by dragging the edges. The left side of the menu acts more like the traditional Start Menu of Windows 7 with a list of recent applications and the ability to go to a list of all applications and the shutdown button. The right side of the menu functions like the Windows 8 Start Page, but within a smaller area.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><strong>Charms Are Gone, Replaced by Notifications Panel</strong></p>
<p dir="ltr"><span>The Charms Bar completely gone. It’s been replaced by the notifications panel. The notifications panel is similar to what you would see in Android, iOS or Windows Phone when you pull down from the top. It contains a list of recent notifications and an area with frequently used settings and toggles. This is almost completely different from what the Charms Bar did. The functionality of the Charms Bar got moved into the individual app windows instead.</span></p>
<p><span><span><br> <a href="http://storage.ning.com/topology/rest/1.0/file/get/396587440?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396587440?profile=original" width="283" class="align-center"></a><br></span></span></p>
<p></p>
<p dir="ltr"><strong>Multiple Destkops</strong></p>
<p dir="ltr"><span>Windows 10 finally introduces a native multiple desktop feature. Clicking on the multiple desktop icon in the taskbar opens up the multiple desktop window. The user can create as many desktops as they want and can also drag apps from one desktop to another.</span></p>
<p><span><span><br> <a href="http://storage.ning.com/topology/rest/1.0/file/get/396588506?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396588506?profile=original" width="600" class="align-center"></a><br></span></span></p>
<p></p>
<p dir="ltr"><strong>Desktop vs Tablet Mode</strong></p>
<p dir="ltr"><span>One of the big problems with Windows 8 is how it attempted to combine desktops and tablets into a single UI. Based on what people say about Windows 8 I don’t think they got it right. Users ended up with a UI that either functioned like the Windows 7 UI or jumped into a full screen tablet mode for Windows Store Apps, completely separate from the desktop. You could work on both if you used the split view, but it was as if the desktop was contained in an app itself and felt a lot like using 2 separate OSes at the same time. This is Windows 8's view of using an app and the destkop:</span></p>
<p dir="ltr"><a href="http://storage.ning.com/topology/rest/1.0/file/get/396588606?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396588606?profile=RESIZE_1024x1024" width="600" class="align-center"></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Windows 10 tries to fix this by bringing Windows Store apps into the desktop instead of having the entire desktop environment function like another store app. Windows 10 apps can now run in windows on the desktop alongside Windows desktop apps.</span></p>
<p dir="ltr"><span><a href="http://storage.ning.com/topology/rest/1.0/file/get/396589010?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396589010?profile=original" width="600" class="align-center"></a></span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Windows 10 also has a “Tablet mode” that detects if the device no longer as a keyboard and mouse attached and asks the user if they want to go into “Tablet mode”. The user can also go into this mode by toggling “Tablet mode” in the notifications area.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>In Tablet mode app, both desktop and store apps open in full screen. The desktop and task bar get cleared of icons and some UI elements become larger.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>In Tablet mode the user can use a split view similar to Windows 8.</span></p>
<p dir="ltr"></p>
<p dir="ltr"><span>The user can split two Windows Store apps.</span></p>
<p><img src="http://storage.ning.com/topology/rest/1.0/file/get/396590743?profile=original" width="600" class="align-center"></p>
<p dir="ltr"></p>
<p dir="ltr"><span>The user can split two desktop apps.</span></p>
<p dir="ltr"><span><a href="http://storage.ning.com/topology/rest/1.0/file/get/396591603?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396591603?profile=original" width="600" class="align-center"></a></span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>The user can split a store app and a desktop app.</span></p>
<p dir="ltr"><a href="http://imgur.com/Z80Hq2B"><img src="http://i.imgur.com/Z80Hq2B.png" title="source: imgur.com" class="align-center"></a></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Unlike in Windows 8 store apps and desktop apps are treated in a similar way. The user isn’t put into a situation where they are using the desktop within an app view.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>If the user exits Tablet mode all their apps are displayed accordingly back on the desktop.</span></p>
<p><span><span><a href="http://storage.ning.com/topology/rest/1.0/file/get/396589010?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396589010?profile=RESIZE_1024x1024" width="600" class="align-center"></a><br> <br></span></span></p>
<p dir="ltr"><strong>Cortana, Spartan, Apps</strong></p>
<p dir="ltr"><span>Cortana, the counterpart to Google’s Google Now and Apple’s Siri is going to be integrated into Windows 10’s Search. In theory Cortana will be able to keep you updated on things you are interested in across devices.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Windows 10 will include a new browser. Codenamed Spartan it is being developed as a more modern browser than IE that doesn’t maintain the backwards compatibility that has hindered IE’s development over the years. One of the highlights of the Spartan browser is the ability to use a pen to mark up pages and share them with others. It will also have a feature that formats articles into a more readable view (similar to Readability).</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>Apps in Windows 10 will become more “universal”. In Windows 8 Windows Store apps could be developed to work on Windows Phone and Windows, but they were still largely separated. They could share code but had completely separated UI. In Windows 10 the lines between apps on desktops, laptops, tablets and phones will be further blurred. We will have to wait until Microsoft’s Build conference to find out more. Microsoft’s own Office, Email/Calendar and Maps apps are already built using the newer universal app model.</span></p>
<p><span><span> </span></span></p>
<p dir="ltr"><span>I don’t know if what Microsoft does with Windows 10 will work well or be well received, but I’m interested in what they are attempting to do. As a consumer I like many of the features that are being added and I like that the 2 completely different UIs of Windows 8 is getting combined into a single more consistent UI. As a developer the ability to write a single app and have it run on phones, tablets and laptops/desktops is more compelling than what Microsoft pitched with Windows 8. Windows 10 is still just a tech preview and there are many bugs and issues. It looks like Microsoft has a lot of work ahead, but I’m looking forward to seeing the final Windows 10 build and I think it will be an improvement over Windows 8 from what I have seen so far.</span></p>
<p><span id="docs-internal-guid-5d1b6c19-e86a-8432-6638-6661da9fcd90"><br> <br> <br> <br> <br> <br></span></p>Google API Authorization Using Oauth2 in Ruby on Railstag:www.techhui.com,2015-04-23:1702911:BlogPost:1340562015-04-23T04:30:00.000ZLeo Dhttp://www.techhui.com/profile/LeoD
<p>Say you are writing a web app that will help its users optimize their companies' online marketing. In that case your web app would need to be able to access its users google analytics web site data. The way you allow your site users to authorize your web app to to access their google analytics data, is with Oauth2. Oauth2 is a security protocol for third party application authorization. When a user visits your web app, you present them with a link that will take them to a google page…</p>
<p>Say you are writing a web app that will help its users optimize their companies' online marketing. In that case your web app would need to be able to access its users google analytics web site data. The way you allow your site users to authorize your web app to to access their google analytics data, is with Oauth2. Oauth2 is a security protocol for third party application authorization. When a user visits your web app, you present them with a link that will take them to a google page where they will be able to authorize your app to access their data. Google knows who your user is because your user is logged into Google and if not, Google will ask them to log in. The way Google knows what the web app the user is giving permission to access their google analytics data, is via parameters in the url the user clicked on your site. Those parameters tell Google to what Google project, your site user is giving authorization to access their data. So, for your web app, you will need one Google project associated with it, and each of your users will need to have a Google app that they are authorized to access, and whose data they will authorize your Google Project to access. Your site users will in effect be giving the Google Project you set up for your site, access to their Google Analytics data. An example of a Google app might be: read-only access to Google Analytics. So, if user A has been authorized to access the Google Analytics data for site X, then user A can log into your site, and then authorize your site to access Google Analytics data for site X on behalf of user A. Your site will then be able to access Google Analytics data for site X on behalf of user A until user A revokes access to your site. Once a site user who has been directed to Google via an authorize link on your site, clicks a button on the Google site indicating that they want your site to be able to access their data, they will be redirected to your site, and the redirect url will have a code. Your site will use that code to send a server to server message to google, which will retrurn an access token and a refresh tokens. Google access tokens last one hour, but you can get new ones via the refresh token. A lot of this is taken care of for you by the Oauth2 Ruby library (gem).</p>
<p>For this blog post, I am assuming you are using devise, and therefore can invoke current_user in your controllers to get the currently logged in user. I am also assuming that you add a field to your users table called ggl_access_token to store a serialized version of a hash containing the access and refresh tokens, and a field, and another field called google_profile_id to store the application id of the site for which users want your web app to access Google Analytics API data.</p>
<p>For your Rails app, you will need the Oauth2 and Legato gems. You can add these lines to your Gemfile:</p>
<blockquote><p>gem 'oauth2',<br/> gem 'legato'</p>
</blockquote>
<p></p>
<p>The Oauth2 gem is for authorization, and the legato gem is for querying Google data in a Ruby idiomatic way, without the json commands that Google expects, and you'll use it to allow a site user to choose what app he wants your site to access data for. </p>
<p>For your site, you will need a Google Project. To create a google project, which is technically what your site users are giving permission to, to access their data. You can view your current google projects and add new ones here:</p>
<blockquote><p><a href="https://console.developers.google.com/">https://console.developers.google.com/</a></p>
</blockquote>
<p>Create a project. Then click on "Credentials" under the "APIs & Auth" menu header to your left. You will then see the Client ID and Client Secret for each of your projects. Refer to the ones for the project that you are using to access the Google APIs for this web app. You can click on "Edit Settings" within a project, to add the url you will be using for the authorization callback. For example:</p>
<blockquote><p>http://localhost:3000/authorize_google_api</p>
</blockquote>
<p>This will need to match up with what you assign to the <span>GOOGLE_REDIRECT_HOST environment variable.</span></p>
<p>the following should be in a Rails environment variables file:</p>
<blockquote><p>ENV['GOOGLE_OAUTH_CLIENT_ID'] = ''"<br/> ENV['GOOGLE_OAUTH_SECRET_KEY'] = ''"<br/> ENV['GOOGLE_REDIRECT_HOST'] = 'http://localhost:3000'</p>
<p><span>ENV['GOOGLE_REDIRECT_PATH'] = '/<span>authorize_google_api</span>'</span></p>
</blockquote>
<p>I load mine at application startup via code in config/environment.rb</p>
<blockquote><p>env_vars = File.join(Rails.root, 'config', 'env_vars.rb')<br/> load(env_vars) if File.exists?(env_vars)</p>
</blockquote>
<p>of course, the first two environment variables should not be empty strings but the values you got from the Google developer's console page under the Credentials section, and the last two will change depending on whether you are in development or production, what your application's web address is, and the value you choose for the redirect path for your app. Just make sure to add the resulting url to the authorized callbacks in the Google developer's console page, or the callback and authorization will fail.</p>
<p>Add a link on your site that asks your users to authorize your site to access their Google data like so:</p>
<blockquote><p>Click <%= link_to 'here', @google_oauth_service.<span>get_authorize_url</span> %> to authorize us to access your app.</p>
</blockquote>
<p>This takes advantage of a GoogleOauthService object (in <span>@google_oauth_service</span>), that is set up in a before_action filter, that we will set up below.</p>
<p>Put the following onto a controller of your choice, possibly a new one, and add a route to it:</p>
<blockquote><p>i.e. in a controller called <span>oauth_authorize</span>:</p>
<p>def authorize_google_api<br/> google_oauth_service = GoogleOauthService.new(current_user)<br/> google_oauth_service.set_access_token(params[:code])<br/> google_oauth_service.refresh_access_token<br/> redirect_to root_path, :notice => "you have been successfully authorized!"<br/> end</p>
<p>in routes.rb:</p>
<p>get 'authorize_google_api' => 'oauth_authorize#authorize_google_api'</p>
</blockquote>
<p>This will handle the Google callback, once the user clicks on the authorize button at the Google site, and is redirected back to your app.</p>
<p></p>
<p>put the following into your application controller or, better yet if you are using Rails 4, into a controller concern and include that concern into the site's application controller:</p>
<blockquote><p>def refresh_token</p>
<p> @google_oauth_service.refresh_access_token<br/> end</p>
<p>def google_oauth_service<br/> @google_oauth_service = GoogleOauthService.new(current_user, current_user.google_profile_id)<br/> if current_user.ggl_acc_token<br/> @google_oauth_service.restore_access_token<br/> if @google_oauth_service.expired?<br/> refresh_token<br/> end<br/> end<br/> end</p>
</blockquote>
<p>Then use a before_action in any controller or for any controller where you need to access the Google API on behalf of a site user:</p>
<blockquote><p>before_action :google_oauth_service</p>
</blockquote>
<p></p>
<p>put the following into a file inside app/services folder:</p>
<blockquote><p>require 'oauth2'</p>
<p>class GoogleOauthService</p>
<p> GOOGLE_OAUTH_CLIENT_ID = ENV['GOOGLE_OAUTH_CLIENT_ID']<br/> GOOGLE_OAUTH_SECRET_KEY = ENV['GOOGLE_OAUTH_SECRET_KEY']<br/> GOOGLE_REDIRECT_HOST = ENV['GOOGLE_REDIRECT_HOST']</p>
<p><span> GOOGLE_REDIRECT_PATH = ENV['GOOGLE_REDIRECT_PATH']</span><br/> GOOGLE_REDIRECT_URI = "#{GOOGLE_REDIRECT_HOST}#{<span>ENV['GOOGLE_REDIRECT_PATH']}</span>"<br/> QUERY_ROOT = "https://www.googleapis.com/analytics/v3/data/ga?"</p>
<p> attr_reader :ga_id, :oauth_auth_code, :client, :user</p>
<p> def initialize(user, ga_id=nil)<br/> @user = user<br/> @ga_id = ga_id if ga_id<br/> @client = OAuth2::Client.new(GOOGLE_OAUTH_CLIENT_ID, GOOGLE_OAUTH_SECRET_KEY, {<br/> :authorize_url => 'https://accounts.google.com/o/oauth2/auth',<br/> :token_url => 'https://accounts.google.com/o/oauth2/token'<br/> })<br/> end</p>
<p> def get_authorize_url<br/> url = @client.auth_code.authorize_url({<br/> :scope => 'https://www.googleapis.com/auth/analytics.readonly',<br/> :redirect_uri => GOOGLE_REDIRECT_URI,<br/> :access_type => 'offline'<br/> })<br/> url #copy this url into browser<br/> end</p>
<p> def set_access_token(code=nil)<br/> @access_token = @client.auth_code.get_token(code || @oauth_auth_code,<br/> {:redirect_uri => GOOGLE_REDIRECT_URI})<br/> @serialized_access_token = @access_token.to_hash.to_json<br/> user.update_attribute(:ggl_acc_token, @serialized_access_token)<br/> nil<br/> end</p>
<p> def get_sessions_and_pageviews_by_country<br/> query = "start-date=2015-01-01&end-date=2015-02-01&metrics=ga:sessions,ga:pageviews&dimensions=ga:country"<br/> response_json = @access_token.get("#{QUERY_ROOT}ids=ga:#{@ga_id}&#{query}").body<br/> JSON.parse(response_json)<br/> end</p>
<p> def execute_query(query)<br/> response_json = @access_token.get("#{QUERY_ROOT}ids=ga:#{@ga_id}&#{query}").body<br/> JSON.parse(response_json)<br/> end</p>
<p> def restore_access_token<br/> @serialized_access_token = user.ggl_acc_token<br/> @access_token = OAuth2::AccessToken.from_hash @client,<br/> {:refresh_token => JSON.parse(@serialized_access_token)['refresh_token'],<br/> :access_token => JSON.parse(@serialized_access_token)['access_token'],<br/> :expires_at => JSON.parse(@serialized_access_token)['expires_at']}<br/> nil<br/> end</p>
<p> def expired?<br/> restore_access_token unless @access_token<br/> @access_token.expired?<br/> end</p>
<p><span> def access_token_object</span><br/><span> restore_access_token unless @access_token</span><br/><span> @access_token</span><br/><span> end</span></p>
<p> def access_token<br/> restore_access_token unless @access_token<br/> @access_token.token<br/> end</p>
<p> def refresh_token<br/> restore_access_token unless @access_token<br/> @access_token.refresh_token<br/> end</p>
<p> def refresh_access_token<br/> restore_access_token unless @access_token<br/> @access_token = @access_token.refresh!<br/> @serialized_access_token = @access_token.to_hash.to_json<br/> user.update_attribute(:ggl_acc_token, @serialized_access_token)<br/> nil<br/> end</p>
<p>end</p>
</blockquote>
<p></p>
<p>This service class is a wrapper around the OAuth2 Ruby library. It serves mainly to encapsulate the needed OAuth2 functionality and isolate the controller or concern from OAuth2 library details. The thing to keep in mind is that the OAuth2::AccessToken object (<a href="http://www.rubydoc.info/github/intridea/oauth2/OAuth2/AccessToken">http://www.rubydoc.info/github/intridea/oauth2/OAuth2/AccessToken</a>), has both a refresh and access tokens inside it, so it's deceptively named. When the access token inside the OAuth2::AccessToken object has expired, which you can tell by calling expired? on it, you just call the refresh! method, and the oauth library will refresh the access token and possibly even refresh the refresh token, depending on how old the refresh token is. Also, notice that OAuth2::AccessToken has a to_hash method for serializing it so you can store it in a database field, and a from_hash method for restoring it from its serialized form. Also, as long as the client id client secret, callback domain, and callback path do not change for the Google Project you are using for your app, you use for your cache the authorization link returned by <span>get_authorize_url, since it depends only on your site and the Google Project associated with your site, and not on the details of a specific site user or their Google apps.</span></p>
<p>You will need to allow site users to pick which of their Google Apps they want your site to access data for. You can do this with a select box. Here is some controller code to get the list for a given user:</p>
<blockquote><p>def get_google_profiles<br/> google_user = Legato::User.new(@google_oauth_service.access_token_object)<br/> @profiles = google_user.profiles.map{|profile| GoogleProfile.new(profile.id, profile.name)}<br/> end</p>
</blockquote>
<p>Store whatever app id a site user chooses in the google_profile_id in that user's row in the users table.</p>
<p>For testing, you can play the part of a user, and revoke authorization at the following url:</p>
<blockquote><p><a href="https://security.google.com/settings/security/permissions?pli=1">https://security.google.com/settings/security/permissions?pli=1</a></p>
</blockquote>
<p>Of course, to do that, you will need to be authorized as a user on some Google application, possibly Google Analytics for some web site.</p>
<p>Of course, a site user might revoke access to their Google app at some point, and in that case, your site would have no way of knowing until they actually try to refresh an expired access token or make a query using an existing non-expired access token. So you want to be able to catch such errors. To do that, you can add a rescue_from call to your application controller, or a concern that you include into the controller:</p>
<p></p>
<blockquote><p>rescue_from OAuth2::Error do |oauth2_error|<br/> if current_user.ggl_acc_token<br/> begin<br/> refresh_token<br/> redirect_to root_path, :notice => "Your google token has been refreshed."<br/> rescue Exception => exception<br/> oauth_error<br/> end<br/> else<br/> oauth_error<br/> end<br/> end</p>
<p>def oauth_error<br/> if current_user.ggl_acc_token<br/> current_user.update_attribute(:ggl_acc_token, nil)<br/> end<br/> redirect_to root_path, :notice => "You need to reauthorize our site to use access your data."<br/> end</p>
</blockquote>
<p></p>
<p>I borrowed heavily from the following page in writing this code and this blog post:</p>
<blockquote><p><a href="https://github.com/tpitale/legato/wiki/OAuth2-and-Google">https://github.com/tpitale/legato/wiki/OAuth2-and-Google</a></p>
</blockquote>
<p></p>
<p></p>
<p></p>Bootcamp'd: A Retrospectivetag:www.techhui.com,2015-04-13:1702911:BlogPost:1343352015-04-13T21:00:00.000ZGeorge Leehttp://www.techhui.com/profile/GeorgeLee
<blockquote><p class="graf--p">“I never want to become a teacher.” — 20 year old me.</p>
</blockquote>
<p class="graf--p"></p>
<p class="graf--p">I stood at a crossroads as a junior in college. Organic Chemistry had destroyed any hope I had of going to medical school. I had declared Biology as my major, but I began to have second thoughts. I fell back on the thing I was good at, which was Mathematics. Still, I wasn’t sure what I would do with that degree.…</p>
<p class="graf--p"></p>
<blockquote><p class="graf--p">“I never want to become a teacher.” — 20 year old me.</p>
</blockquote>
<p class="graf--p"></p>
<p class="graf--p">I stood at a crossroads as a junior in college. Organic Chemistry had destroyed any hope I had of going to medical school. I had declared Biology as my major, but I began to have second thoughts. I fell back on the thing I was good at, which was Mathematics. Still, I wasn’t sure what I would do with that degree.</p>
<p class="graf--p"></p>
<p class="graf--p">I thought about becoming a teacher, but the more I thought about it the more I didn’t want to do it. I thought I would be good at teaching. I might have grown to enjoy it. But, I was pretty sure it would drive me insane. I didn’t want to deal with misbehaving students. I didn’t want to deal with school politics. I wanted something more hands on.</p>
<p class="graf--p"></p>
<p class="graf--p">Fast forward to today. I received my Master’s in Computer Science and am employed as a software engineer. I taught a one day class on Javascript at the local outreach college. I’ve done some volunteer work teaching Ruby on Rails to women at <a href="http://www.railsbridge.org/" class="markup--anchor markup--p-anchor">RailsBridge</a> Honolulu. I started the local <a href="https://www.facebook.com/groups/ohanajs" class="markup--anchor markup--p-anchor">Javascript users group</a> and continue to organize talks and meetups. My efforts have not gone unnoticed and I got an opportunity to teach at <a href="http://www.devleague.com/" class="markup--anchor markup--p-anchor">Dev League</a>. The offer was to take over the part time class for 3 months.</p>
<p class="graf--p"></p>
<p class="graf--p">I immediately said yes. As I tell my students, I have a problem saying no. There were reasons for me to turn it down. I have many side projects that need to get done. But, I wanted to help out a friend and it was a good opportunity to give back to the tech community. Yeah, it’d be 20 more hours per week, but it’s only for 3 months, right?</p>
<p class="graf--p"></p>
<p class="graf--p">I started by putting a daily schedule together. I taught twice during the week at night, so I went to the gym in the mornings. I set aside some time on nights I didn’t teach to work on side projects or rest. When class was over, I left to make sure I got enough rest for the next day. I started thinking about the topics we’d cover and what my approach would be.</p>
<p class="graf--p"></p>
<p class="graf--p">It wasn’t easy adjusting to the schedule, but I pulled it off. I treated it as another job and made sure to keep my day job and teaching separate. I started losing weight because of my time at the gym. I made sure to get enough rest so I could make it through another day. It all worked out pretty well. During the first 8 weeks, I skipped one day at the gym.</p>
<p class="graf--p"></p>
<p class="graf--p">But then something happened. I’m not sure I can pinpoint the exact cause. I think it was one night after teaching algorithms. I told some students that I found discrete math interesting. I recalled a graph algorithm my boss used to schedule our hours. I ended up staying about 2 hours after class talking.</p>
<p class="graf--p"></p>
<p class="graf--p">It started to become more than a job. I began to care about my students. I always wanted to help them with their projects and understand the material. But, as I got to know them better, I became invested in their success. I tried to give advice and shared my observations of the tech industry in Hawaii. I told tales of how I succeeded and failed. I empathized with each of the students. It was a lot of fun.</p>
<p class="graf--p"></p>
<p class="graf--p">Sure, there were times where things got tough. Coming up with curriculum was difficult. Trying to help 8 students with 8 different projects is a challenge. I didn’t get to all the topics I wanted to cover. The students got to see me mess up on more than one occasion. I hope it demonstrated that even after all that education and experience, it’s okay to make mistakes. I’m still human after all.</p>
<p class="graf--p"></p>
<p class="graf--p">Looking back, there were some things we did that worked well for the students.</p>
<ol class="postList">
<li class="graf--li">Standup: Every class day, we started off with standup meeting. Each student said what they did since the last meeting and what their next step was going to be. Since they were doing this part time, they needed to work on things outside of class. This held them accountable and also got everyone to speak for a little bit.</li>
<li class="graf--li">Writing tests for the students: For some of our lessons, we wrote unit tests. These tests gave the students immediate feedback on whether their implementation was correct. We stumbled on tests a few times (I’m used to RSpec), but they kept the students on track.</li>
<li class="graf--li">Personal projects: For the last month, the students worked on their own personal project. We helped the students manage the scope of their projects and kept them on track. We also provided help, but the students had to come up with their project idea.</li>
</ol>
<p></p>
<p class="graf--p">At the same time, there were things that we could do better.</p>
<ol class="postList">
<li class="graf--li">Keeping people on task outside of class: This was the biggest challenge for the part-time cohort. We expected students to work on projects or assignments outside of class. For the most part, students were motivated enough to find work when they needed to. Still, we needed to do a better job of giving the students work to do.</li>
<li class="graf--li">Managing the group project: The students worked on a group project during the month of February. We split the project up into 4 parts and had pairs of students work on each one. We simulated an open-source environment where the project owners (the instructors) reviewed pull requests. Yet, we did a poor job of time management and could not get the entire system up in a working state. Some of the teams were blocked on others, which made it difficult to keep them engaged. The students did learn a lot from the experience, so I can’t say it was a complete failure.</li>
</ol>
<p></p>
<p class="graf--p">This was an amazing experience and I’m thankful to Jason, Russel, and Jon for giving me the opportunity. I developed a bond with each student and have become invested in their success. Turning the lights off on the last day was difficult, but we did our best to prepare them for the road ahead.</p>
<p class="graf--p">I can’t wait to see what they do next.</p>
<p class="graf--p"></p>
<p class="graf--p"><em>This blog is also cross-posted on <a href="https://medium.com/@keokilee/bootcamp-d-a-retrospective-1f96f318152d" target="_blank">Medium</a>.</em></p>C# Architecture Preferencetag:www.techhui.com,2015-04-13:1702911:BlogPost:1336562015-04-13T10:02:39.000ZDavid Chunghttp://www.techhui.com/profile/DavidChung
<p>Having worked on many software projects written in C#, I've come to prefer certain conventions when creating the architecture of a C# project. In this highly opinionated blog post, I will share these personal preferences, which I hope may be of some value to the reader.</p>
<h1>Single Solution, Multiple Projects</h1>
<p>If possible, I prefer not to hunt down projects that ultimately make up the product. If a product is a collection of projects, then I think this should be bundled as a Visual…</p>
<p>Having worked on many software projects written in C#, I've come to prefer certain conventions when creating the architecture of a C# project. In this highly opinionated blog post, I will share these personal preferences, which I hope may be of some value to the reader.</p>
<h1>Single Solution, Multiple Projects</h1>
<p>If possible, I prefer not to hunt down projects that ultimately make up the product. If a product is a collection of projects, then I think this should be bundled as a Visual Studio solution.</p>
<p>With the projects contained in a solution, you can then reference another project in your solution and then build the solution to then build your projects in order of dependencies.</p>
<h1>Database Projects</h1>
<p>If your product relies heavily on a database, I prefer that the database is built from a project contained in the product solution.</p>
<p>Visual Studio supports schema comparisons to import and deploy database schemas designed in the database project.</p>
<p>The motivation behind this mentality is now you have version control of your data objects. In particular, database procedures and functions since they are now maintained in your database projects.</p>
<h1>Test Projects</h1>
<p>I prefer to pair a project with its corresponding test project, which contains the test fixtures for the paired project.</p>
<p>In addition, the database project mentioned above can be paired with a test project that agnostically connects to a test database that deploys the database project's schema and run the test project's test fixtures.</p>
<p>For a detailed explanation, refer to my <a href="http://www.techhui.com/profiles/blogs/test" target="_blank">blog post about unit-testing database projects</a>.</p>
<h1>Consolidate Build Artifacts</h1>
<p>With the projects contained in a single solution, I prefer to maintain deployable build artifacts in the solution itself.</p>
<p>This consolidation can be achieved by modifying each project's build configuration to move (copy) its build artifacts in a common location relative to the solution path.</p>
<p>The motivation behind this mentality is to allow your solution to be easily deployable so that it can be automated via continuous integration. While your CI build can be configured to hunt down multiple projects and build your product, from my first point above, if everything is consolidated, then setting up your CI build configuration should be trivial and it would take the load off of your build engineers so they can focus on promoting builds in targeted environment rather than figuring out how to build your product.</p>
<h1>Interfaces</h1>
<p>Interfaces are always preferred.</p>
<p>If interfaces start to bloat your projects, then the next best thing would be to add virtual keywords in your class members that provide your logic.</p>
<p>This mentality keeps your projects easily testable since interfaces can easily be mocked and virtual members can be overridden by a test class.</p>
<h1>Default Constructor</h1>
<p>I prefer to keep logic outside of the constructor. Even better is to include a default constructor and use public properties. The class will then need to throw exceptions if operations are called during an invalid state.</p>
<p>Like the interfaces mentality, by maintaining simple constructors, your projects will be easily testable since when calling concrete constructors, you don't risk your tests accessing external resources.</p>Open Data Africatag:www.techhui.com,2015-04-02:1702911:BlogPost:1339362015-04-02T12:04:05.000ZRobert J. Vitellohttp://www.techhui.com/profile/RobertJVitello
<div class="text_exposed_root text_exposed" id="id_551c9103641824b49240434"><p>We (v257 LLC) picked up some new assignments this month with Justin leading projects for our business partner, NuCivic, in a collaboration with IBM and the World Bank. We’re managing the development of Open Data web sites for the governments of Sierra Leone and Liberia. And we’re managing another project to enhance an Open Source software package that’s used on the …</p>
</div>
<div id="id_551c9103641824b49240434" class="text_exposed_root text_exposed"><p>We (v257 LLC) picked up some new assignments this month with Justin leading projects for our business partner, NuCivic, in a collaboration with IBM and the World Bank. We’re managing the development of Open Data web sites for the governments of Sierra Leone and Liberia. And we’re managing another project to enhance an Open Source software package that’s used on the <a href="http://eboladata.org/" target="_blank" rel="nofollow">EbolaData.org</a> web site (among many others). We’re also working on extending this government transparency model t<span class="text_exposed_show">o other projects for Pacific Rim nations.</span></p>
<div class="text_exposed_show"><p>One of the topics that we’re looking at critically is how to make open government data useful to citizens in the rural villages of third world countries. We need to devise strategies addressing the very serious Digital Divide . No less a challenge is to find ways to educate potential users of open data. College educated Americans struggle with statistics; how can we make government facts and figures useful to third world agrarian and mining communities?</p>
</div>
</div>
<p><span class="userContentSecondary _c24">— at <a class="profileLink" href="https://www.facebook.com/pages/Sierra-Leone-West-Africa/115783268504690">Sierra Leone, West Africa</a>.</span></p>Rails on Windows With Bitnamitag:www.techhui.com,2015-03-25:1702911:BlogPost:1335132015-03-25T21:23:11.000ZGeorge Leehttp://www.techhui.com/profile/GeorgeLee
<p><span style="font-size: 13px;">When I first started learning Ruby on Rails back in 2007, one thing was made clear: don’t even try setting it up on a Windows machine. Since then, we had some open source projects like</span> <a class="markup--anchor markup--p-anchor" href="http://railsinstaller.org/en" style="font-size: 13px;">RailsInstaller</a> <span style="font-size: 13px;">that make it really easy to set up a development environment on your machine. Also, with the advent of virtual machines…</span></p>
<p><span style="font-size: 13px;">When I first started learning Ruby on Rails back in 2007, one thing was made clear: don’t even try setting it up on a Windows machine. Since then, we had some open source projects like</span> <a href="http://railsinstaller.org/en" class="markup--anchor markup--p-anchor" style="font-size: 13px;">RailsInstaller</a> <span style="font-size: 13px;">that make it really easy to set up a development environment on your machine. Also, with the advent of virtual machines and</span> <a href="https://www.vagrantup.com/" class="markup--anchor markup--p-anchor" style="font-size: 13px;">Vagrant</a><span style="font-size: 13px;">, it is really easy to get a Linux environment set up regardless of what operating system you’re on.</span></p>
<p class="graf--p">These things are all great if you are setting up a development box, but what about production? RailsInstaller is used for development and the virtual machine approach doesn’t work if your system administrator is not familiar with Linux at all. However, a lot has changed in the past 8 years and it is possible to get a production setup on Windows. Doing so is not straightforward and the resources are limited, but it is in fact possible.</p>
<p class="graf--p">We’ll set up our production environment using <a href="https://bitnami.com/stack/ruby" class="markup--anchor markup--p-anchor">Bitnami’s Ruby stack</a>, which bundles Ruby, Apache, Postgres, and some gems that will get our production setup to work. Most of this is based off of <a href="http://stackoverflow.com/a/11619989" class="markup--anchor markup--p-anchor">this Stack Overflow answer</a> with some minor changes.</p>
<h3 class="graf--h3">Install Bitnami and Set Up Your Project</h3>
<p class="graf--p">First of all, go to the Bitnami Ruby stack page and download and run the local installer. Once that is done, you should have a new directory that contains all of the components that Bitnami installed. You should also have a new command line shortcut in your start menu that is called “Use Bitnami Ruby Stack”. Whenever you are executing commands, make sure to use the terminal window created by that shortcut. It runs as administrator, sets up your path, and takes you directly to the Bitnami directory.</p>
<p class="graf--p">Next, you will need a way to download your project. I chose to use <a href="http://windows.github.com" class="markup--anchor markup--p-anchor">Github for Windows</a> to make it easier to talk to a Github repository. It is a little annoying to go back and forth between the command line and Github for Windows, but it was easier than attempting to install OpenSSL. Once that is installed, clone your project into Bitnami’s projects directory so that it can be easily accessed from the command line.</p>
<p class="graf--p">After that, normal Ruby commands should work within the Bitnami cmd terminal, so you can use your usual commands to set up your project (bundle install, rake db:create, rake db:migrate, etc). I set up a PostgreSQL database on another server, so I won’t get into configuring the database. Once the database is set up, you only need to update the database.yml to point to that database.</p>
<h3 class="graf--h3">Setting up Apache as a Reverse Proxy</h3>
<p class="graf--p">Bitnami comes with both Apache and Nginx. Since Bitnami’s service manager already has Apache set up (at the time of this writing), we will use that as our server. Nginx could work with a little bit of effort.</p>
<p class="graf--p">Open the httpd.conf for Bitnami (something like C:\<path to Bitnami>\apache2\conf\httpd.conf) and make sure the following modules are not commented out.</p>
<p><a href="https://gist.github.com/keokilee/5def7622c3a52df36a3e">https://gist.github.com/keokilee/5def7622c3a52df36a3e</a></p>
<p class="graf--p">After that, edit bitnami.conf (something like C:\<path to Bitnami>\apache2\conf\bitnami\bitnami.conf). Replace the virtual host block with the following (replacing <ruby stack> with the path to your installation and <project dir> with the directory for your project). It should look similar to <a href="https://gist.github.com/keokilee/429f39d20d08a8f37f69">https://gist.github.com/keokilee/429f39d20d08a8f37f69</a></p>
<p class="graf--p">This also sets up far-future expiration headers for assets so your server isn’t hammered with constant requests.</p>
<h3 class="graf--h3">Installing the App as a Windows Service</h3>
<p class="graf--p">Create a batch script (*.bat) file to start up your Rails application. Mine looks something like <a href="https://gist.github.com/keokilee/7266195a3463302dc71f">https://gist.github.com/keokilee/7266195a3463302dc71f</a></p>
<p class="graf--p">I used Thin to start up our server because it is installed by default with Bitnami. I could use Puma or another server, but again I did not want to deal with more installation issues. We will pass in the port number as an argument to the script.</p>
<p class="graf--p">Next, download <a href="http://nssm.cc/" class="markup--anchor markup--p-anchor">NSSM (Non-Sucking Service Manager)</a> and put it on your path. Run “nssm install <service name>” and the GUI should appear.</p>
<br />
<div class="aspectRatioPlaceholder is-locked"><img class="graf-image align-full" src="https://d262ilb51hltx0.cloudfront.net/max/800/1*phnKSbAQiepgafSbVtTFYA.png"/>Installing a service named “startApp” in the NSSM GUI.</div>
<br />
<p></p>
<p class="graf--p">Set the path to be the path to your batch script. The startup directory should be your Github project directory. Arguments should just include the port number. In the Apache config, we have two servers in our load balancer, so you’ll need to create one service with port 3000 as the argument and another with port 3001.</p>
<p class="graf--p">Once that is done, start the services you created using Windows’ Services menu (Start menu -> Administrative Tools -> Services). Then, open Bitnami’s GUI and restart the Apache server. Once that is done, you should be able to go to localhost and see your app.</p>
<h3 class="graf--h3">Setting Up SSL</h3>
<p class="graf--p">Most of the above was culled from that Stack Overflow answer, but we also needed to set up SSL on our application. This requires a few changes to our setup. First, let’s update our Apache config. My new bitnami.conf virtual hosts looks something like <a href="https://gist.github.com/keokilee/9980702b6b687fd32403">https://gist.github.com/keokilee/9980702b6b687fd32403</a></p>
<p class="graf--p">The main changes are 1) we set up a redirect from port 80 to go to our SSL URL) and 2) we added in a bunch of SSL configuration options. Make sure to input the correct paths to your SSL certificate (SSLCertificateFile), private key (SSLCertificateKeyFile), and a combined certificate plus private key for the proxy members (SSLProxyMachineCertificateFile).</p>
<p class="graf--p">Next, we need to update our thin servers to use SSL. The batch script should now look something like <a href="https://gist.github.com/keokilee/b650b1f80d658d84ff14">https://gist.github.com/keokilee/b650b1f80d658d84ff14</a></p>
<p class="graf--p">Restart your services and Apache and the site should now work with SSL.</p>
<p class="graf--p">That’s the gist of how we set up our Rails 4.1.8 app on Windows server. I’m sure there are things we could change like using Puma instead of Thin or Nginx instead of Apache, but this got us a working system with a minimal amount of headache. Still, if you have suggestions or comments, let me know.</p>
<p class="graf--p"></p>
<p class="graf--p"><em>This blog post originally appeared on <a href="https://medium.com/@keokilee/rails-on-windows-with-bitnami-8c04d886eddc" target="_blank">Medium</a>.</em></p>Today I Learned — The Apptag:www.techhui.com,2015-03-11:1702911:BlogPost:1335002015-03-11T21:43:02.000ZGeorge Leehttp://www.techhui.com/profile/GeorgeLee
<p><span style="font-size: 13px;">People who know me know that I’ve been pretty busy lately. People who really know me know that I’m actually slammed. Yet, I’m taking a personal challenge to complete a small application in the month of March. As it turns out, I have an idea for a small bite-sized application that I can build in a month. It’s also a great chance to challenge myself to learn new frameworks and libraries.</span></p>
<h3 class="graf--h3">The Problem</h3>
<p class="graf--p">I’ve…</p>
<p><span style="font-size: 13px;">People who know me know that I’ve been pretty busy lately. People who really know me know that I’m actually slammed. Yet, I’m taking a personal challenge to complete a small application in the month of March. As it turns out, I have an idea for a small bite-sized application that I can build in a month. It’s also a great chance to challenge myself to learn new frameworks and libraries.</span></p>
<h3 class="graf--h3">The Problem</h3>
<p class="graf--p">I’ve been tracking the things I learn in a given day in a small <a href="https://github.com/keokilee/til" class="markup--anchor markup--p-anchor">Github repository</a>. Other than the challenges of keeping up with it on a daily basis (as you can tell by the dates in the repo), it works fairly well. It’s great to have a centralized place that I can come back to and review my notes.</p>
<p class="graf--p">However, there are a few shortcomings of this approach. I did organize it by dates on purpose because I wanted it to be a daily thing (yeah, not so much). The <a href="https://github.com/thoughtbot/til" class="markup--anchor markup--p-anchor">original Thoughtbot repo</a> organized it by categories, which might be a better approach. However, I really like having items indexed by the date as well, but doing both is not really something you can do in a file structure like this. Also, as I learn things in multiple categories, I would prefer not to have to fumble around and make sure I open the right file in the right directory. I also tend to write short one-liners, so multiple files in a directory might not be the best approach.</p>
<p class="graf--p">What would be really great is a website where I can go and input the things I learned. I can also tag items and view the things I learned that belong to those tags. If I’m really ambitious, you’ll be able to see what your friends have learned, too.</p>
<h3 class="graf--h3">The Technology</h3>
<p class="graf--p">I don’t like doing the same thing twice. Even at work, there’s always lessons learned in a previous project that can be applied. It can be something small like a library or it can be higher-level like code organization.</p>
<p class="graf--p">For personal projects, I like to change things up a lot. In previous projects, I’ve used <a href="http://nodejs.org/" class="markup--anchor markup--p-anchor">Node</a>, <a href="http://mongodb.org" class="markup--anchor markup--p-anchor">MongoDB</a>, <a href="http://backbonejs.org" class="markup--anchor markup--p-anchor">BackboneJS</a>, and <a href="http://coffeescript.org" class="markup--anchor markup--p-anchor">Coffeescript</a>. For this project, I’m incorporating <a href="http://foundation.zurb.com/apps/" class="markup--anchor markup--p-anchor">Foundation for Apps</a>, <a href="https://babeljs.io/" class="markup--anchor markup--p-anchor">Babel</a> (an ES6 to ES5 transpiler), and <a href="https://firebase.com" class="markup--anchor markup--p-anchor">Firebase</a>. My goal is to write as little backend code as possible and to use Firebase as my backend. I’m also hoping to do most of the design myself, which will either be awesome or horrific. Maybe somewhere in the middle.</p>
<p class="graf--p">I’m still just getting started with building the application, but some initial thoughts:</p>
<ul class="postList">
<li class="graf--li">Foundation for Apps adds an entire workflow based on <a href="https://angularjs.org/" class="markup--anchor markup--li-anchor">Angular</a> and <a href="http://gulpjs.com/" class="markup--anchor markup--li-anchor">Gulp</a>. I ended up refactoring the gulp tasks because I added in <a href="http://browserify.org/" class="markup--anchor markup--li-anchor">Browserify</a>. They also changed the grid classes and their integration with <a href="https://github.com/angular-ui/ui-router" class="markup--anchor markup--li-anchor">UI Router</a> is kind of magic. Overall, I wish I had read the docs more rather than just jumping in head first as I tend to do.</li>
<li class="graf--li">Babel and ES6 is pretty cool. Admittedly, I haven’t done much beyond some shorthand (arrow functions and object properties) and using let instead of var. For example: <a href="https://gist.github.com/keokilee/9e5642ca2338f7dd44cb">https://gist.github.com/keokilee/9e5642ca2338f7dd44cb</a></li>
</ul>
<ul class="postList">
<li class="graf--li">Firebase is what I was really excited about. I had used it over a year ago for a tutorial, but back then it was a real-time data store and hosting. Firebase can now handle <a href="https://www.firebase.com/docs/web/guide/user-auth.html" class="markup--anchor markup--li-anchor">user authentication</a>, which makes this concept of a “no custom backend” app actually feasible. I have Github logins working and I’ll probably add in other services over the coming days.</li>
</ul>
<p class="graf--p">I’m excited to be working on this application over the course of the next month. I already have so many feature ideas, but the first step is to scratch my own itch and build something that I would use.</p>
<p class="graf--p"><em>This blog post is also cross posted on <a href="https://medium.com/@keokilee/today-i-learned-the-app-420313a150a3" target="_blank">Medium</a>.</em></p>Remembering 3/11 and Yurekurutag:www.techhui.com,2015-03-11:1702911:BlogPost:1334982015-03-11T21:30:00.000ZChristopher Kobayashihttp://www.techhui.com/profile/ChristopherKobayashi
<p><iframe frameborder="0" height="315" src="https://www.youtube.com/embed/QXqjxOqPTLg?wmode=opaque" width="560"></iframe>
</p>
<p><a href="http://storage.ning.com/topology/rest/1.0/file/get/396595417?profile=original" target="_self"><img class="align-left" src="http://storage.ning.com/topology/rest/1.0/file/get/396595417?profile=original" width="199"></img></a> About 15 seconds into this video you'll hear an alarm from an iOS app called <a href="https://itunes.apple.com/us/app/yurekuru-call/id398954883?mt=8" target="_blank">Yurekuru</a>, which is a Japanese word that translates to a shake or sway is…</p>
<p><iframe width="560" height="315" src="https://www.youtube.com/embed/QXqjxOqPTLg?wmode=opaque" frameborder="0"></iframe> </p>
<p><a href="http://storage.ning.com/topology/rest/1.0/file/get/396595417?profile=original" target="_self"><img src="http://storage.ning.com/topology/rest/1.0/file/get/396595417?profile=original" width="199" class="align-left"></a>About 15 seconds into this video you'll hear an alarm from an iOS app called <a href="https://itunes.apple.com/us/app/yurekuru-call/id398954883?mt=8" target="_blank">Yurekuru</a>, which is a Japanese word that translates to a shake or sway is coming.</p>
<p>The alarm and a push notification would warn you of an earthquake. And depending on your location, how long until you'll feel it and estimated intensity.</p>
<p>The app receives warnings called <a href="http://en.wikipedia.org/wiki/Earthquake_Early_Warning_%28Japan%29" target="_blank">Earthquake Early Warning (EEW)</a> issued by the Japan Meteorological Agency. According to Wikipedia, there were <a href="http://en.wikipedia.org/wiki/2011_T%C5%8Dhoku_earthquake_and_tsunami#Earthquake" target="_blank">over 1,000 seismometers in Japan</a> at that time.</p>
<p>Actually most phones made in Japan at that time had this capability due to regulations that made it mandatory for 3G phones since 2007. Apple iPhone's didn't have this capability and thus an iOS app was made available.</p>
<p>We had over 1,000 earthquakes in March. It was unnerving when you were on a train and somebody's phone started to make this noise. After a few seconds almost everyone's phone was going making it. A 'ring, ring' here and then behind you. Next to you. And then your phone.</p>
<p>I would quickly look to figure out when and how big it was going to be. And then you would brace yourself. The car would become silent and you could feel the anticipation from around you. I would wonder is this going to be the big one that everyone talks about and we were over due for.</p>
<p>Since there were so many earthquakes, many got fatigued from so many alerts. I set my alarm threshold higher so that I wouldn't receive alerts for smaller earthquakes. I think it was set to 3 or 4.</p>
<p>Here's a visualization of the earthquakes that occurred in 2011. It gets intense in March...</p>
<p><iframe width="560" height="315" src="https://www.youtube.com/embed/NSBjEvPH2j4?wmode=opaque" frameborder="0"></iframe> </p>
<p>I haven't heard the Yurekuru alarm sound in a while. Even though it's only a YouTube video, hearing it again gives me goose bumps.</p>