Fake data
当测试程序需要数据时,可以通过faker来构造测试数据
安装
1 | $ pip install faker |
基本使用
1 | from faker import Faker |
对方法 faker.ipv4()的每次调用都会产生不同的随机结果
1 | for _ in range(10): |
Commencement Address at Stanford University
Steve Jobs
I am honored to be with you today at your commencement from one of the finest universities in the world. Truth be told, I never graduated from college, and this is the closest I’ve ever gotten to a college graduation. Today I want to tell you three stories from my life. That’s it. No big deal. Just three stories.
The first story is about connecting the dots.
I dropped out of Reed College after the first 6 months, but then stayed around as a drop-in for another 18 months or so before I really quit. So why did I drop out?
It started before I was born. My biological mother was a young, unwed college graduate student, and she decided to put me up for adoption. She felt very strongly that I should be adopted by college graduates, so everything was all set for me to be adopted at birth by a lawyer and his wife. Except that when I popped out they decided at the last minute that they really wanted a girl.
Protocol Buffers使用
I Have a Dream
On August 28, 1963, some 100 years after President Abraham Lincoln signed the Emancipation Proclamation freeing the slaves, a young man named Martin Luther King climbed the marble steps of the Lincoln Memorial in Washington, D.C. to describe his vision of America. More than 200,000 people-black and white-came to listen. They came by plane, by car, by bus, by train, and by foot. They came to Washington to demand equal rights for black people. And the dream that they heard on the steps of the Monument became the dream of a generation.
As far as black Americans were concerned, the nation’s response to Brown was agonizingly slow, and neither state legislatures nor the Congress seemed willing to help their cause along. Finally, President John F. Kennedy recognized that only a strong civil rights bill would put teeth into the drive to secure equal protection of the laws for African Americans. On June 11, 1963, he proposed such a bill to Congress, asking for legislation that would provide “the kind of equality of treatment which we would want for ourselves.” Southern representatives in Congress managed to block the bill in committee, and civil rights leaders sought some way to build political momentum behind the measure.
A. Philip Randolph, a labor leader and longtime civil rights activist, called for a massive march on Washington to dramatize the issue. He welcomed the participation of white groups as well as black in order to demonstrate the multiracial backing for civil rights. The various elements of the civil rights movement, many of which had been wary of one another, agreed to participate. The National Association for the Advancement of Colored People, the Congress of Racial Equality, the Southern Christian Leadership Conference, the Student Non-violent Coordinating Committee and the Urban League all managed to bury their differences and work together. The leaders even agreed to tone down the rhetoric of some of the more militant activists for the sake of unity, and they worked closely with the Kennedy administration, which hoped the march would, in fact, lead to passage of the civil rights bill.
Tcpdump使用
简介
tcpdump是一个命令行数据包分析、抓取工具
可以使用 -D 标志来列出可用于捕获的接口
1 | $ tcpdump -D |
可以使用 -i 标志指定要捕获的接口,指定 any 作为接口将从所有活动接口捕获
1 | $ tcpdump -i any |
可以使用 -v 标志来调整tcpdump输出中的详细程度
1 | $ tcpdump -i any -v (Verbose output) |
The Pragmatic Programmer
The Pragmatic Programmer Quick Reference Guide
关心你的技艺
Care About Your Craft
如果你不在乎能否漂亮地开发出软件,你又为何要耗费生命去开发软件呢?思考!你的工作
Think!About Your Work
关掉自动驾驶,接管操作,不断地批评和评估你的工作提供各种选择,不要找蹩脚的借口
Provide Options, Don’t Make Lame Excuses
要提供各种选择,而不是找借口,不要说事情做不到,说明能够做什么不要容忍破窗户
Don’t Live with Broken Windows
当你看到糟糕的设计、错误的决策和糟糕的代码时,修正它们做变化的催化剂
Be a Catalyst for Change
你不能强迫人们改变。相反,要向他们展示未来可能会怎样,并帮助他们参与对未来的创造记住大图景
Remember the Big Picture
不要太过专注于细节,已忘了查看周围正在发生什么
Kafka Quickstart
1. GET KAFKA
Download the latest Kafka release and extract it:
1 | $ tar -xzf kafka_2.13-3.2.1.tgz |
2.START THE KAFKA ENVIRONMENT
NOTE: Your local environment must have Java 8+ installed.
Run the following commands in order to start all services in the correct order:
1 | # Start the ZooKeeper service |
Open another terminal session and run:
1 | # Start the Kafka broker service |
Once all services have successfully launched, you will have a basic Kafka environment running and ready to use.
Kafka Introduction
1. What is event streaming?
Event streaming is the digital equivalent of the human body’s central nervous system. It is the technological foundation for the ‘always-on’ world where businesses are increasingly software-defined and automated, and where the user of software is more software.
事件流是人体中枢神经系统的数字等效物。它是”永远在线”世界的技术基础,在这个世界中,企业越来越多地由软件定义和自动化,并且软件的用户更多地是软件。
Technically speaking, event streaming is the practice of capturing data in real-time from event sources like databases, sensors, mobile devices, cloud services, and software applications in the form of streams of events; storing these event streams durably for later retrieval; manipulating, processing, and reacting to the event streams in real-time as well as retrospectively; and routing the event streams to different destination technologies as needed. Event streaming thus ensures a continuous flow and interpretation of data so that the right information is at the right place, at the right time.
从技术上讲,事件流是从事件源(如数据库、传感器、移动设备、云服务和软件应用程序)以事件流的形式实时捕获数据的实践;持久存储这些事件流以供以后检索;实时和回顾性地操作、处理和响应事件流;并根据需要将事件流路由到不同的目标技术。因此,事件流确保了数据的连续流动和解释,以便正确的信息在正确的时间出现在正确的位置。
LeetCode Online Judge
进度

Github
https://github.com/eazow/leetcode
作者
版本
0.3.0.0