Todays Objec3ves Using git Networking Layers End to End Argument - - PDF document

today s objec3ves
SMART_READER_LITE
LIVE PREVIEW

Todays Objec3ves Using git Networking Layers End to End Argument - - PDF document

9/15/17 Todays Objec3ves Using git Networking Layers End to End Argument discussion Sept 15, 2017 Sprenkle - CSCI325 1 Review What are some performance issues we need to consider with Web Servers (and servers in general)?


slide-1
SLIDE 1

9/15/17 1

Today’s Objec3ves

  • Using git
  • Networking Layers
  • End to End Argument discussion

Sept 15, 2017 1 Sprenkle - CSCI325

Review

  • What are some performance issues we need to

consider with Web Servers (and servers in general)?

Ø How can we solve those issues?

  • What are some of the metrics we use for

networks?

Sept 15, 2017 Sprenkle - CSCI325 2

slide-2
SLIDE 2

9/15/17 2

GIT

Sept 15, 2017 Sprenkle - CSCI325 3

Review: Subversion

  • How did you use Subversion?

Sept 15, 2017 Sprenkle - CSCI325 4

slide-3
SLIDE 3

9/15/17 3

Centralized vs Distributed VCS

  • Centralized (CVS,

Subversion)

Ø One central repository – the gold standard Ø Must be capable of connec3ng to repo

  • No access, no updates

Ø Need to solve issues with group members making different changes on the same files

  • Distributed (git,

mercurial, bazaar)

Ø Everyone has a working repository Ø Faster Ø Connec3onless Ø S3ll need to resolve issues, but it's not an argument against DVCS

Sept 15, 2017 Sprenkle - CSCI325 5

What to Put Under Version Control

  • YES!

Ø text based things made by humans Ø source code Ø Scripts Ø Documenta3on

  • No!

Ø large binary files that change ofen Ø Things automa3cally built Ø Temporary files Ø Sensi3ve data: passwords, private ssh keys Ø Ignore these things with .gitignore

Sept 15, 2017 Sprenkle - CSCI325 6

slide-4
SLIDE 4

9/15/17 4

SVN à GIT

  • S3ll use add, remove, and commit

Ø BUT, commit is a local opera3on

  • We’re using GitHub

Ø Host for git system

Sept 15, 2017 Sprenkle - CSCI325 7

add (stage) files Working directory Repository (.git directory) Index (staging area) checkout the project commit

Local Workflow

Sept 15, 2017 Sprenkle - CSCI325 8

slide-5
SLIDE 5

9/15/17 5

Recording Changes to the Repository: File Level

Sept 15, 2017 Sprenkle - CSCI325 9

https://git-scm.com/book/en/v2/Git-Basics-Recording- Changes-to-the-Repository

Git Staging in Eclipse

Sept 15, 2017 Sprenkle - CSCI325 10

These are what will be commimed These have been modified but not staged for comminng

slide-6
SLIDE 6

9/15/17 6

Best prac3ces for code collabora3on: Commi3ng

  • Not a clear-cut answer
  • Try not to break things (don’t do a lot of work in
  • ne commit)
  • Always use a clear, concise commit message

Ø Put more details in lines below, but always make the first line short

  • Describe the why; the what is clear in the change

log

  • When making giant changes, consider branches

(we'll talk about these in a few slides)

Sept 15, 2017 Sprenkle - CSCI325 11

Git transport commands

  • Remote Repository is where you’ll collaborate

Remote repository Local repository $HOME/.git/repo GitHub Repo push pull

Sept 15, 2017 Sprenkle - CSCI325 12

slide-7
SLIDE 7

9/15/17 7

Git Branches

  • Like a copy of the code in the current branch

Ø Creates a “sandbox” Ø Can edit/update code in your sandbox

  • Use a branch to work on new features
  • Allows you to test out new ideas, fix bugs, work
  • n mul3ple features in parallel
  • Do most of your development work in a branch

Sept 15, 2017 Sprenkle - CSCI325 13

Typical Workflow

  • 1. I want to implement X
  • 2. Create a branch, named “implemen3ngX”
  • 3. Implement X, adding files, commi)ng

whenever I do something that is “significant”

  • 4. Afer tes3ng to make sure my code works,

switch to master branch

  • 1. Merge “implemen3ngX” into master branch
  • 5. Push master branch to remote (GitHub)

repository

Sept 15, 2017 Sprenkle - CSCI325 14

If it didn’t work, can throw branch away.

slide-8
SLIDE 8

9/15/17 8

Tags

  • Can tag versions you want to save in GitHub

Repository

Sept 15, 2017 Sprenkle - CSCI325 15

Recommended (More Complicated) Organiza3on

  • Adds another layer/branch
  • Master branch is the thoroughly tested, gold

standard

  • Development branch is where you coordinate

with teammate

Ø Afer teammate tests your work and you both sign

  • ff on it working, then merge into master
slide-9
SLIDE 9

9/15/17 9

Web Server Project

  • Follow GitHub Educa3on set up instruc3ons on

project page.

  • Create teams

Sept 15, 2017 Sprenkle - CSCI325 17

NETWORKING

Sept 15, 2017 Sprenkle - CSCI325 18

slide-10
SLIDE 10

9/15/17 10

Formalizing Defini3ons

Sept 15, 2017 Sprenkle - CSCI325 19

Term DefiniDon

Host Packet Link Switch Router

Formalizing Defini3ons

Sept 15, 2017 Sprenkle - CSCI325 20

Term DefiniDon

Host Computer, mobile device, … Packet Unit of transmission across a network Link Used to transmit bits; pipe

  • Wired or wireless
  • Broadcast or switched (or both)

Switch Used to move bits between links – Local Area Network (LAN)

  • Packet switching: stateless, store & forward
  • Circuit switching: stateful, cut through

Router Connects networks across wide area (WAN)

slide-11
SLIDE 11

9/15/17 11

Review: Layering in Network Design

  • Fundamental Ques3on: What services do

applica3ons require from the bare hardware?

Ø Don’t make each app implement the same func3onality Ø OSs should implement these services/abstrac3ons

  • Network links hand a frame to the opera3ng system
  • But what abstrac3on does the applica3on desire?
  • Do all applica3ons need the same abstrac3on?
  • What abstrac3ons do intermediate hosts (routers) in

the network need?

Sept 15, 2017 Sprenkle - CSCI325 21

Hardware OS Applications

COMMUNICATION ABSTRACTION

Sept 15, 2017 Sprenkle - CSCI325 22

slide-12
SLIDE 12

9/15/17 12

End-to-End Argument

  • What is the end to end argument?
  • Do you believe it?

Ø The paper was wrimen in 1984…things have changed…

  • Why are the tradeoffs in E2E?

Ø What applica3ons benefit? Ø Can you think of any applica3ons that do not benefit from the E2E argument?

  • Do you think the E2E argument will hold in the future?
  • Does this change how you think about sofware

development?

Sept 15, 2017 23 Sprenkle - CSCI325

TODO

  • Work on web server project in team

Ø Figure out what needs to be done Ø Design solu3on Ø Break into pieces

  • Read and comment on Perusall for Friday:

Lessons from Giant-Scale Internet Services

Sept 15, 2017 Sprenkle - CSCI325 24