Monday, September 26, 2016

Setting up NGINX as server for Ionic and reverse proxy for Rails on AWS

For Assignment 3, we implemented a RESTful application, Wishes (www.wishful.tk), with Ionic as front-end framework and Rails as back-end server. Regrading the deployment, there is very limited resource on how to setup Ionic and Rails with NGINX on Ubuntu and make them work together. After days of searching and a few trials, I come up with the following steps.

  1. Install NGINX on Ubuntu 14-04
    1. https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-ubuntu-14-04-lts
  2. Install letsencrypt to get CA certificate
    1. https://certbot.eff.org/#ubuntutrusty-nginx
  3. Update NGINX config to enable HTTPS connection
    1. https://certbot.eff.org/#ubuntutrusty-nginx
    2. http://nginx.org/en/docs/http/configuring_https_servers.html
  4. Setup Ionic
    1. http://ionicframework.com/docs/guide/installation.html
  5. Install git
    1. sudo apt-get install git
    2. sudo npm install gulp -g
  6. Clone frontend repo onto server
    1. git clone https://github.com/Wishes-CS3216/Wishes-Frontend.git
  7. Update NGINX configuration (located at /etc/nginx/sites-avaiable/default)
    1. http://nginx.org/en/docs/beginners_guide.html
    2. restar NGINX
  8. Setup Rails
    1. https://gorails.com/setup/ubuntu/14.10
  9. Clone backend repo
    1. git clone https://github.com/Wishes-CS3216/Wishes-Backend.git
  10. Update NGINX configuration
    1. https://www.digitalocean.com/community/tutorials/how-to-deploy-a-rails-app-with-puma-and-nginx-on-ubuntu-14-04 (We are using Puma here. Other alternatives are Passenger and Unicorn)
    2. git clone https://github.com/Wishes-CS3216/Wishes-Backend.git
    3. update Rails configurations if necessary (under repo/config/ folder)
    4. start Puma
    5. restart NGINX
Links to relevant resource are attached here. Hope it can be useful. If you are still confused about the detailed configurations please feel free to comment below. Cheers =)

Monday, September 19, 2016

Lessons learnt from pitches

1. The word "free" has magic power in attracting people. The experiment mentioned by Patrick was quite inspiring. I think the strategy could be applied for onboarding users.

2. People will be more willing to donate money / free stuff if they know that it is for charity purpose rather than for some random strangers. For assignment 3, our group is doing something related to help fulfilling other people's wishes. And one of our main concern is on how to activate users. I think maybe we can reconsider the project scope to add in element like "help local charity organisations". It indeed sounds more attractive and it is more likely to get support from the society.

3. "Don't find target users for your app; find app for your target users". There were two great examples mentioned that indicated such principle. The first one is the Show My Turban site and the second one is the marriage agency for Indian. During my past barnstorming I mainly focus on the pain in my personal life which made my ideas limited. In the future I will also consider the problems faced by people whose life I truly understand. For example. students and teachers in Chinese high schools and NUS, people living in my hometown, etc.. Since I have a deep insight on their lives I guess I am able to come up with something that will make their life better.

4. Users may not use the app as you planned. I personally doesn't believe that the "anonymous Facebook Message“ idea will be successful. Similar functionality was implemented by Tecent QQ a few years ago and the feedback was quite negative since people felt offended and annoyed by mischief. The idea failed mainly because user didn't use the app as expected. I think it is important to think about all use cases for an app during brainstorming to ensure that all of them doesn't contradict with the main purpose of the app. But the good thing is that if one of the use cases contradict with the original ideas and it sounds fun we may create an app for that as well ><

Monday, September 12, 2016

Reflection on Assignment 1

Assignment 1 is over but there are still lessons can be learnt through reflection. What can we have done better?

First of all, we should have cared about security from the very beginning. Two of us were taking CS3235 but yet we put security as our last concern. Not a good practice at all. Choosing a framework that implements more secure features can be a good start. Securing database access by avoiding raw query can be useful. We should have validated user input as well and we should did it when we still have enough time. I guess Quan Yang must feel quite boring hacking our website - "No challenge."

Second, when we split into two groups each focusing on a component of the website, it is important to know what the other group is doing and will the integration work in the end. In our case we implemented Student page and Company page separately but later we found that there was logic flow missing. It was not only the project manager's duty to see the big picture of the website.

Last but not least, since finishing the write-up is so much pain, it is better to answering each milestone once we finished it.

Tuesday, August 30, 2016

Application Critique - Grab

Congratulation to Group 3 for the successfully presentation. The ideas elaborated were quite inspiring. 

In my opinion, the best part of the presentation came with the question: how will Grab compete with Uber in Southeast Asia? The answer was localisation. For example, GrabBike at Indonesia offers a new solution to the pain caused by Jakarta's terrible traffic jam. It reminds me of how KFC out-powered McDonalds in China by selling chicken rice during lunch hours. It is great that Grab make use of the resources it already acquired to server different needs. Such action is likely to bring customers for all services it provided.

As a user of Grab myself, I cannot agree more that Grab should provide more information to users and update data at real time. Otherwise, users will keep complaining about information asymmetry deals which may leads to trust issues. 

On the other hand, I am afraid that involving bidding into such business model is a risky move. It is true that during peak hours there will be mismatch between demand and supply in certain areas and involving bidding is likely to increase the amount of supply. But considering that more cars means more traffic jam and more traffic jam means longer waiting time. Users may end up paying extra money without saving much time. Besides, with the large amount of demand daily, taxi is more like a kind of necessity good. It is unfair to have customers bidding on necessity good.

The idea of GrabHitch Deals - Sharing 1-for-1 Deals was very interesting (e.g. grab a strange to share the Starbuck 1-for-1 offer). The idea proves the value of information. But I am wondering what kind of commercial potential does the service have for Grab. Please leave comments if you have any ideas =)

Many thanks to Group 3 for uncovering the valuable ideas for us.

Sunday, August 28, 2016

What is good and bad about Discord and possible improvement

After reading tons of reviews about Discord on blogs and Reddit, I get a further insight on what is good and bad about Discord and what functionalities are expected.

Let's start with the advantages. I believe a very important reason that Discord is getting more and more popular is that it is 100% free. Its competitor, TeamSpeak for example, charges $30 per year for a server with 32 slots while Discord is free with no limit on how many channels a user can create. Why pay for something when you can get it free? Besides, Discord is designed for use while gaming which means that it has minimal impact on users' CPU. The game's performance won't be affected in the slightest. Maybe it's time to ditch CPU hogs like Skype? Moreover, unlike apps like IRC, Discord enables different user permissions within an easy-to-use UI. TeamSpeak also supports permissions setting but it requires a package that is ridiculously complicated.

Then what is ugly about the app at current stage? First of all, no user profile. Though Discord doesn't actually require users to login before joining the chat but a user profile is really necessary for logged-in users because I do not want to encounter situation where I find myself texting the wrong Jack. Second, Discord doesn't support search function for text chat. Users have been complained about it for more than a year but it seems to be a very complex problem to fix according to their technical team.

What can be improved then? Of cause, starting from fixing the problems mentioned above. Other than that, some users asked for video chats because they want to play online card games while seeing each other's faces. Screen sharing is also quite nice to have because gamers always want to learn all the fancy moves from each other to improve their skills and screen sharing will server their need.

Sunday, August 21, 2016

A glance on Discord

To be honest I am a bid sad that Pokemon GO was not assigned to my team for Assignment 2. But considering that Discord is something closely related to a gamer like me, I am still quite happy about the topic. The following are a few things I observed when I first visited its official website and downloaded the app.

First of all, Discord has a nice cute logo which like a gamepad and a pig nose. It leaves me a good impression. Besides, its registration process seems to be simple. I did not encounter any difficulty in choosing a username. But I am not sure if  it is just by luck nobody had chosen the name or Discord allows duplicated username. I am also unsure about what will happen if there are duplicated names. I need some more testing to figure it out.

A great thing about Discord is that it provides a feedback forum on its official website. Garena should have something similar to collect complains about unstable server and suggestions on improvement of its voice chat app TalkTalk (to be fair, TalkTalk had improved remarkably in the past 4 months). This feedback forum of Discord will serve as a great source for the "What is bad / ugly about the application" and "Suggest improvements" parts of our presentation.

So far I hasn't observer the key feature that makes Discord better than other voice and text chat applications. I guess today after lecture I should play game with my friends purely to test the functions of Discord and gain some first hand user experience =)

Thursday, August 18, 2016

The origin of NUS-PARTIME

For the Facebook assignment, my team members are Yanhao, Hanming and Zhuohan. To be honest we didn't form a team of 4 Chinese students purposely. It was just so happened that 4 Pokemon fans sat together in the first lecture so why not just form a team to catch Pokemon create cool apps together?

As for the core feature of our app, we proposed around 10 ideas through brainstorming. For example, selling unused SOC printing quota to students of other faculties, taking tutorial attendance with mobile locations, IVLE chit chat group that was open to student ONLY and, of cause, dating app. But some of the ideas had no much relation to Facebook or to social networks, and some of them were not of piratical use. In the end we came up with this idea of creating a platform for NUS students, SOC students in particular, to find part time jobs / projects. It was a surprise for us when we found that there were no existing platform or attempts because we thought the need was real. We were all CS major and we understand that many CS students, including ourselves, were doing or were interested in doing part time jobs / projects as a way to enhance experience and skills as well as earning some money. 

After further analysis, we decided that the flow of the app should be as follow: Companies, or individuals such as professors, will post available jobs / projects onto the app and students will be able to indicate interests. Afterwards, companies and students will get in touch with each other and proceed the process or recruiting offline.

I personally think the app will be useful but there are issues concerns me as well. First of all, can the demand of SOC students to part time jobs be a fake demand? In other words, is it possible that most of students are just considering about finding a part time jobs but actually cannot do it due to problems such as time constraints. Second, how can we ensure that the companies that are recruiting can be trusted (for example, they will pay our students)? Actually I should worry about not being able to get enough companies on board first.

Concerns aside, I am actually quite looking forward to carrying out such idea because it may be able to serve the needs of my fellow schoolmates.