西维蜀黍

【Linux】Shell - Bash Utility

# Execute a command:
$ bash -c "command"

# Run commands from a file:
$ bash file.sh

# Run commands from a file, logging all commands executed to the terminal:
$ bash -x file.sh

# Run commands from a file, stopping at the first error:
$ bash -e file.sh

# Run commands from stdin:
$ bash -s
  ...


【Linux】命令 - echo

Usage

# Print a text message. Note: quotes are optional:
$ echo "Hello World"

# Print a message with environment variables:
$ echo "My path is $PATH"

# Append a message to the file:
$ echo "Hello World" >> file.txt

# Enable interpretation of backslash escapes (special characters):
$ echo -e "Column 1\tColumn 2"
  ...


【Distributed System】高可用(High-availability)

High availability

High availability (HA) is a characteristic of a system which aims to ensure an agreed level of operational performance, usually uptime, for a higher than normal period.

Modernization has resulted in an increased reliance on these systems. For example, hospitals and data centers require high availability of their systems to perform routine daily activities. Availability refers to the ability of the user community to obtain a service or good, access the system, whether to submit new work, update or alter existing work, or collect the results of previous work. If a user cannot access the system, it is – from the user’s point of view – unavailable.

Generally, the term downtime is used to refer to periods when a system is unavailable.

  ...


【Cache System】缓存更新策略

Update Cache Design Pattern

  • Cache aside Pattern
  • Read through Pattern
  • Write through Pattern
  • Write Back/ Write Behind Pattern
  ...


【Engineering】Code Review

  ...