Swift Server Side

Looks Interesting, although it is quite new. I am learning on this course, would update with more details later: https://www.udacity.com/course/server-side-swift–ud1031

  1. Couple of notes from the course:
  • We can use Swift on Command Line. Wow, never heard about it before.
  • There is SwiftEnv for you to play around
  • As Swift can run on Command Line, it can run on Linux just fine, but with different libraries. I am not sure how different it will be between Swift on Linux and Swift on iOS / MacOS
  • They also talking about Docker. I don’t have any experience with Docker so I have to spend some time on this topic

Book Review

Well, I am back into my writing mood now, so I will go quickly through a list of books that I read. This is very personal, and everybody has their own priorities about what books are good.

Here is my list:

  • It must be engaging. Yes, it has to be. Fun is a plus
  • A little bit of story telling and some fact, research supported fact. Story supports your emotion, and helps you to link with the people, and remember what you read longer. However, too much story seems to focus on details and fail to abstract a lesson from then.
  • It offers new content and knowledge in each chapter. There are good books with amazing beginning chapters, but then it goes on and on about the same topic or concept. “I got it, thanks”, and move on.

Some kinds of books I love reading on:

  • Technology books. Definitely. Well, it is always awesome to read old and new technology books. They taught us new mindset, new tricks and new process.
  • Psychology and Sociology books. I actually want to touch into the people’s emotion and feeling, rather than just learning management. I think learning management offers lots of value, but I enjoy psychology and Sociology more.
  • Management, Process and Leadership
  • Design, UI & UX
  • Law
  • Sales

In the next post, I would review many of the books I read, hope that it can help others to find out what they should learn

 

Learning from a variety of source is key

Having going out and meeting a lot more people recently, I can start feeling differences in the way they learn and value learning:

  • Phd students tend to read a lot, and trust the source they read and learn. Many of them view people who disagree as idiots, stupid and not complicated enough
  • Practical and on hands people normally disregard reading, as it took them too long for it. They prefer working on the issue and having a chat with people.
  • Parents overestimate the value of studying in famous high school and colleges.
  • Entrepreneurs love learning from real experience and getting out to the real world, and point to Bill Gates as a solid example.

It is hard to say who is right, and everybody has their own strength and weakness. The reason they got their current achievement is due to those strength, weakness and hobbies.

But overtime, people’s mind change. I think that learning a little bit from any source is a better way to advance:

  • Books help you to look at the big picture, with facts, data and insights.
  • People tell you their stories, what is touching to their feeling. Those stories teach you that everybody feel differently about the same fact.
  • People give you concrete guideline and example, which saves you hours or months of reading and researching.
  • There are lots of things formal education can teach you, but there are lots of things that they cannot teach you. Nobody else can teach you either. You need to go out and experience for yourself. In Information Technology, NoSQL means Not Only SQL, and in education, NoDegree means Not Only Degree.

Opening your mind and your heart to knowledge, insights and understanding. Sometimes, what is factually right does not matter to lots of people. People are never rational. To convince them, you touch their hearts first, and then their mind.

You cannot touch their hearts without a solid fact follows on. That is dangerous for society as well. Trump is an example.

URL Design

The url has become an important part of lives, when it is shared around. You want to have a Get, not a Post, and the url has to include text for the SEO, but should be easy for human to make mistakes.

I love Stack Overflow’s URLs. Here’s an example: https://stackoverflow.com/users/6380/scott-hanselman

The only thing that matters there is the 6380. Try it https://stackoverflow.com/users/6380 or https://stackoverflow.com/users/6380/fancy-pants also works. SO will even support this! http://stackoverflow.com/u/6380.

Great post here with Scott Hanselman:

https://www.hanselman.com/blog/URLsAreUI.aspx

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