Last week because of the temporary company has urgent demand, most of the time into the work, so they suspended clock program, in remote office in the first week of this week, continue to roll the column study plan, this week will share the treasure jade old geek time column – * * * * in the beauty of the software engineering development code.

What method can improve the development efficiency of 25 |?

This estimation is a topic of concern for every developer and project manager. Teacher Bao Yu shared several working principles that have influenced him a lot:

  • active
  • Is beginning to the end
  • Shall first

active

  • Avoid negative emotions, do not complain, with a positive attitude towards the improvement of the actual work
  • Instead of backing out of something unfamiliar or unknown, remind yourself to think again and try again
  • Reduce your circle of concern and expand your circle of influence. Instead of focusing on what you can’t change, take the time to expand your circle of influence

On this point, I also can have negative emotions at ordinary times, in the face of unreasonable demand will complain, but slowly I found complain useless, only oneself to take positive attitude to look at, broaden their ability, make oneself can influence others, rather than passive to accept some things, the more positive nature also more efficient.

Is beginning to the end

Received demand is inevitable is one of the most inefficient code inside, now than in the past I received demand will hold the first demand, I will carefully analyze the effect of what eventually want to reach this demand, and then go with the product manager to discuss, according to the current situation to feasibility scheme of evaluation work, and then begin to develop according to the rhythm.

Starting with an end points to three things: goals, principles and plans.

Everything we do has an original purpose, and if you’re doing something that doesn’t revolve around that, then you’re going in the wrong direction and need to stop and think about it.

You need to set some rules for yourself to avoid technical debt, such as:

  • Run first, optimize later
  • Don’t copy and paste code
  • Each PR should be as small as possible
  • .

It is not enough to have a principle. You need to have a plan to carry it out and set deadlines so that everything can be completed within the specified time.

Shall first

This is about prioritizing things in order of importance and urgency. This is also known as the quadrants of time:

  • Take care of important and urgent matters immediately
  • Take time for things that are important but not urgent
  • Put off urgent, unimportant tasks and concentrate on them
  • Do as little or no work as possible that is not important or urgent

26 | continuous delivery: how to do it at any time a new release to production?

We hear a lot about CI/CD in DevOps, which is continuous integration and continuous delivery, and this lecture also mentions continuous deployment, which is a more automated level. How do we understand the difference between them? First of all, they all have something in common — persistence, which is the process of making painful things in software engineering more frequent and cheaper to do, from manual to automatic is persistence.

The continuum is broken down into integration, delivery, and deployment, with the following concepts:

  • Integration: Developers merge code from branches to trunk and must test to fit in
  • Delivery: Integration-based, built after testing to generate release packages for deployment to test and production environments
  • Deployment: Environment deployment, test, and production environments

The evolution of our software engineering is from continuous integration to continuous delivery to continuous deployment, which builds on the former with higher levels of automation and higher requirements for developers and tools.

Continuous delivery has the following benefits regardless of the development model:

  • Expose problems as soon as possible
  • Greatly improve efficiency
  • Improve the quality
  • Reduce project cost

There is also about how to build a continuous delivery system, mainly based on source code tools and continuous integration tools, and then with their own business to the implementation, we can go to learn Qiao Liang’s continuous delivery: the systematic method of releasing reliable software.

27 | core competence is a software engineer? (on)

As for the core competence of software engineers, everyone is probably very interested in it. So am I. I have been thinking about whether the competence I have mastered can become my core competence. This lesson focuses on what are the core competencies of software engineers.

The ability to learn

Master more than one language and be proficient in using tools and frameworks, and be able to quickly master the learning ability of programming languages, frameworks and tools. In terms of learning ability, my view is that business cannot stay the same, technology cannot not be updated and iterative, and learning ability is what enables us to adapt to change faster. Just like the current terminal, you only know Android, do not know iOS, in the face of cross-terminal problems you do not know how to solve, for another student proficient in both ends, others will be more competitive than you.

Problem solving skills

I wrote an article about this before:

www.jianshu.com/p/bdd7e4927…

The core of our problem-solving skills in our daily work is:

  • Finding problems (problems with solutions, anomalies)
  • Analyze the problem (analyze the underlying causes of the failure to avoid recurrence and propose mechanisms)
  • Problem solving (learn to ask questions, learn to search)

influence

  • Experience sharing, technical blogs, forums, technical communities
  • Unique project, company or industry experience
  • Technical conferences, public speaking, etc

The above is my summary of the core competitiveness of software engineers, personal feeling or quite harvest.

28 | core competence is a software engineer? (below)

Last class is about what is the core competence of software engineers, and this class is about how to do it. Teacher Baoyu shared the following content, I did the next extraction:

How to improve learning ability

  • Deep cultivation of a technical field, understand domain knowledge, the construction of knowledge domain forest
  • Horizontal expansion of similar fields, using existing knowledge, speed up learning

How to improve your problem solving skills?

A workable methodology:

  • Step 1: Identify the problem (analyze the nature of the problem and whether there are other problems)
  • Step 2: Split and locate problems (divide complex problems into simple ones and locate them one by one)
  • Step 3: Propose solutions and summarize
    • Better solution
    • Programs to prevent the same problems

How to increase influence?

  • Do well in a field
  • Do things beyond expectations. Manage expectations
  • Helping others is helping yourself
  • Analytics is all about learning and building impact

The three points mentioned by Teacher Baoyu are also what I have been practicing: vertical deep cultivation, horizontal expansion of technical field, daily thinking to better solve problems in work, summing up experience and precipitation methodology, which make me more confident in the road of technology.

29 | test automation: how to kill a Bug in the cradle?

This lecture focuses on improving code quality through automated testing. Here’s my summary:

In fact, automated testing is to use procedures instead of people to do the test, our test generally contains the following elements:

  • The test case
  • Input and operation
  • Real and expected

Some simple and repetitive logic is written into unit tests, which are automatically run aside before each compilation. The code is guaranteed to be stable and new bugs are prevented by 100% code merging.

Automated test classification

Google divides automated testing into three broad categories:

  • Small tests (often called unit tests, tests on a function or a class)
  • Medium testing (verifying interaction between two or more modules, also called integration testing, simulating or using real services to complete tests)
  • Large-scale testing (no emulation, testing with real services, also known as system testing or end-to-end testing)

A picture is worth a thousand words:

Test pyramids, faster from the top down, more expensive to implement from the bottom up:

How to write the automated code? Contains four parts:

  • Prepare (create instance, create mock object)
  • Execute (the method that executes the test, passing in parameters)
  • Assertion (verification result, expected success or failure)
  • Clean up (clean up data to avoid affecting the next test)

A complete automated test consists of three parts:

  • Verify that the function is correct
  • Covering boundary condition
  • Exception and error handling

Implement automated testing for the project

A picture is worth a thousand words:

The core is the ability to automatically run written test code in a continuous integration environment.

This lesson is a good explanation of the nature of automated testing, which is also a module lacking in our project. We will try to promote it to the project team later.

30 | with good source code management tool, makes you more efficient collaboration

This lesson covers the history of code versioning from integrated to distributed:

SCCS(Source Code Control System)-> RCS(Revision Control System) -> CVS(Concurrent Versions System) -> SVN(Subversion)-> DVC(Distributed Version Control)

The mainstream version management tools are SVN and Git, which are the representatives of centralized and distributed version management respectively. Git has basically replaced SVN as the most mainstream source code management tool, and our team is currently using Git as our code version management.

Build your own source code management system

  • Git
  • Gitlab
  • Gerrit

Online code hosting platform

  • Github
  • Gitlab
  • Coding
  • The other…

Working principles of good source code tools

  • Principle 1: Frequent submission (small granularity, easy to Review Code, easy to roll back problems, as far as possible to ensure integrity)
  • Rule 2: Run automated tests every commit (nip bugs in the bud)
  • Rule three: Submit code for review

Choose the right development process

  • Git Flow
  • Github Flow
  • Gitlab Flow

Look at these three best practices and choose one that is appropriate for your team.

The last

This article was two days late, because I was so busy that I worked around the clock for a week, met some problems in the process of developing requirements, and worked all night to solve them. Finally, the development was completed as scheduled. About this week to learn the beauty of “software engineering” in the column development code, I think is worth every developers to learn, which no matter mentioned to have a good reference value, idea and practice will make you more understand their pain points, review what is core ability as a software engineer, what they are lacking.

Ok, this week’s learning summary is over, next week continue to learn the content of software testing, please look forward to.

Welcome to my public account: Wushan old demon