Office 365

I wouldn’t say I like Microsoft or most of its products much. But Office 365 is actually working well for me. It also receive lots of praise from the community and users.

I guess I miss something after few years working solely on Apple stuff :))

Xamarin – Migration Journey (Part 3 – Legacy code integration)

This is actually the hard part, and the failure at this point actually prevents us from moving towards with Xamarin.

We have been developing with native iOS and Android for 6 years, with lots of legacy code and libraries. Our libraries in both iOS and Android can have up to 20-30,000 lines of code. To migrate all of them to Xamarin would be a huge deal. The only solution is to connect Xamarin with those libraries.

We have libraries in 3 languages: Objective-C, Swift and Java. The first trouble came up when Xamarin could not connect with Swift framework. In our experiment, we took the risk and port 1 of our library into Objective-C. The Swift framework issue should have signaled us that something was not going right.

Anyways, we move forward with our intention to write a real project, working on both iOS and Android, and connect with 5 of our libraries and use 3 cocoapods frameworks/libraries.

For the libraries we wrote, there was not much problem, except the Swift issue mentioned above. However, with cocoapods, when people write code in all shapes and forms, the API definition kept having weird issues that we could not comprehend. We spent 3-4 man days on this, and still wasn’t sure that if the code would work or not.

We will discuss more about what binding issues we have with Xamarin that forced us to change the direction: to try to at least make a workable app with missing elements and libraries working in Xamarin

 

Xamarin Migration Journey (Part 2 – Architecture)

In part 1, we discuss about some steps that we have to take when experimenting with Xamarin. In this part, we will discuss about architecture between iOS and Android.

In the normal process, iOS and Android will share some similar architecture styles. Both will have UI layer, Model Logic layer and Database Layer. Before trying to use Xamarin, we need to make sure that both of our code platform will share similar architecture.

So, the first step was to try bring both our platform into a V.I.P.E.R architecture and share the same code process. VIPER is more commonly used in iOS and there are not many resources for Android, but we still have to force the Android codebase to use VIPER. You can read more about VIPER here.

With this architecture, we hope to reuse our Interactor (Business and Controller Logic), Presenter (View Logic), Worker (Data Logic) and Models as much as possible. Any code that is different between iOS and Android will be integrated at runtime using a Protocol / Interface approach.

We take this as a first step, because if we fail to use Xamarin, we can still have a nice codebase and a familiar structure between iOS and Android. This allows us to port code from iOS to Android easily in the future

Xamarin Migration Journey (Part 1 – Introduction)

We are trying Xamarin as our cross platform approach. And we have learnt many things along the way, some of them were the old approach of Static Library, the API definition and how the code structure and the API design of Xamarin and iOS are somehow different.

We have quite a big codebase (more than 100 thousand lines of code) in iOS and Android in native, mainly because we deal mostly with Video Processing and some native features. We use frameworks a lot to share code between different apps. I have been looking for ways to port the code from iOS to Android in a smooth and cost saving way.

There are multiple steps that I plan to go through when adapting Cross Platform:

– Same or similar architecture between iOS and Android codebase

– Prepare the library in correct format to be reused in the Cross Platform

– Prepare the Binding

– Prepare the team with C# knowledge to migrate the codebase

– Design the module and how best the app will be separated between Shared Module and iOS Module

Experience, bad and good

Just congratulated my 26th birthday. I have got 6 years of working experience under my belt, but now I always have a big question: Am I 6 years more experience than my 20 years old, or just 1 year of experience repeated 5 times. And do I have a 6 years of shit assumption, bad software, customer and internal development practice. Sometimes, it is hard to tell huh :)) A reflection of what I became after 6 years is truly crucial. When I was in university, I saw myself as a software architecture or a computer science researcher. However, working my first job opens my eyes about the startup world, the comfort zone, the up and down of a software startup. This, together with the realization that I am not a good fit for an academic research role, changes my career path. It shows an important lesson for me that it would always be good to set out a plan, try your best and willing to adapt or change to a new environment for a new challenge

The good thing about the IT career is that it is always changing fast.  Experience can become old, like my iOS 3 and 4 experience would not be used any more. Even experience with iOS5 and 6 can become obsolete soon. New thing like Swift can change the landscape fast.

Unfortunately, it can become hard for me when I need to manage people or develop a program. It might be a lot easier for me to give a clear guidance to others based on my old experience and people will just follow and do that quickly. But then, they won’t be able to find out a new way of doing that thing. People surprised me all the time about their different way of thinking, which reminds me to be humble and patient to listen to their idea

The Generalist and Specialist Approach

Learning is a lifelong and continuous process in anyone’s career. A common question from the newbie and the college students is what areas they should focus their efforts on to move fast. I share the same feeling with their ambition to go fast and change the world. However, in my opinion, the first few years of college and career should be on learning their most favourite subjects. It is fine to not earn much money at first as long as you are building up your background.

Choosing the first job

Some people would claim that the first internship and job is the most crucial one in his career. This was far from the truth. A career is a 40-50 year (yes, they are extending retirement age to 70) marathon which allows you to make a few mistakes here and there and still achieve the greatness. The key strategy is to always move forward, always expand beyond your comfort zone. I would encourage new students to try different career paths if they are still unsure about what they want: the startup life, the small and medium enterprise and the multinational companies. These offer different skills and experience to people.

The learning curve

To learn some fundamental concepts about a new topic does not take much amount of time.  The pareto principle (The Pareto Principle states that 80% of outcomes come from 20% of causes.) on learning new concept would say you will understand and know 80% of a subject by spending 20% of the time. This part of 80% will not qualify you as a great specialist in the area, but it is enough for you to apply it in your current speciality.

A good example would be that a developer learns about UI/UX development. The first few hundreds of hours of learning and applying it will not make him a UX specialist, but that would be enough for him to apply it into his software development. This will guarantee that the UI/UX of his app/website would be at least at an acceptable level.

Work to learn or work to earn money?

A very important concept for newbie is to know their value, or to put a dollar amount into his work. The one who would say he can work for me for free will not make me impressed. The one who would say that his salary would be a specific amount of A $ because of these reasons, will be the one I feel good about. He would show me that he spends a significant amount of time to research about different companies, about my company to know how much his contribution is worth. He would still have to seek for learning and improving himself over the future period of time, and it would be good for him to show me that plan and how he would stick to it.

The altitude is always valuable for most employers, but you better show that you have the knowledge and skills to make that altitude become valuable.

Dealing with customers

Written Contract

Written Contract

Dealing with customers is always a hard topic. This blog post will not summarise some of my experience before working for my current company. Communication with customers require both art and discipline to make sure that nothing could possibly go wrong. Here is a quick list of errors I have been making throughout my working life. :

– Not thinking through each of the small details the customers may want to add later.

For example, if the customers want his websites to work on mobile device, it would be wrong to assume that he meant iPhone. 

– Don’t have a specific, fixed requirement document.

It could go wrong if both sides did not agree on a specific set of requirement before the project starts. I think I may need to understand more about Agile development

Agree on a verbal basic: this is one of the hard lesson that I learnt when working outsourcing. Everything needs to be at least written and agreed on the email and not just chat or voice call.

Not thinking through small details

This is what is hard with software estimation when all the devils are in the details. When customers say they want their app to work on iphone, they really think of all iphone versions, and they probably assume that it works on android as well unless you tell them. It is good to be clear upfront and think through all cases.

Another example is that customer do not understand how important security is, and they just want it to work. But while they are testing, they may find the security issue and blame us all for bad practice of coding and testing.

Don’t have a specific, fixed requirement document.

Customers may want us to change the graphics 2 to 3 times and that are lots of back and froth emails and demonstration with the client. It will also extend the deadline of the project as we may need to wait for them most of the time.

Agree on a verbal basic

Everything should be at least in a written form. This was the key lesson I learnt during the early days of doing business. Everything needs to be agreed again over email. Even if you trust someone, or have a good memory, it is important to remind both of us what we said. It could be as simple as the client wanted to change the graphics and then later on, they completely forgot. It would be troublesome if clients wanted to change the requirement, then to extend deadline and the budget but they regretted it later. A written document would be helpful, or at least an email. I am not a lawyer but I found this book (22 Legal Mistakes you don’t need to make) helpful for new people.

When you write something down and let the other side read through it once, you can confirm that both sides share the same idea and clear all the miscommunication. This proves to be effective when you work on project requirement.

What is your tip? Please share it in the comment.

 

Coursera Optimization

Discreet Optimization at Coursera

Discreet Optimization at Coursera

I just finished the Optimization course in Coursera.org and I felt excited about it. I learnt many new computer science concepts that I skipped during my undergraduate time. My postgraduate was more about management, business and finance than a technical one.

This is a quick review of the course to show what I learnt, what I wished to learn more and how I could apply it in my real world problem

What I learnt:
– NP-hard problems
– The basic knapsack problem
– Branch and bound
– Bottom Up Dynamic Programming
– Constraint Programming
– Local Search
– Integer Programming

It is one of the toughest course in coursera so I needed to watch one topic twice, one for the general understanding and the second is when I need to finish my programming assignment. I will summarise what I learnt in the next few posts, and upload my java code so people can learn from it. The code is not good, though.

The difficulty of the assignments increase significantly when you progress through the course. However, you can jump to any assignment and finish it if you feel comfortable. The lecturer has a hilarious style of teaching that I enjoyed. I personally got 256/320, about 80% of the score, enough to get a certificate

P/S: I recently had a discussion with my coworker about the role of the school and what students should expect to learn. Some of the key concepts offer short term benefits while others’ usefulness need years to recognize.I will write about that in another blog post.

Controls Android New Site

ControlsAndroid.com

ControlsAndroid.com

I am so excited to announce my new site: ControlsAndroid.com where I show my collection of all android controls that I find on the internet. We are still updating it everyday, so please spend time visiting the website, download and use the controls for your cool app. Leave my any comments or suggestions on how to improve the site much better for the community.

For a better Android Interface