Skip to content
/ DSV-SP Public

Semestral project for the subject B6B32DSV on FEE CTU in winter semester 2019.

Notifications You must be signed in to change notification settings

Baterka/DSV-SP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DSV-SP

Semestral project for the subject B6B32DSV on FEE CTU in winter semester 2019.

Task

Shared variable

  • Implement a program to access the shared variable..
  • Realize access using either a 'leader' or exclusive system-wide access.
  • Individual nodes will implement at least these functions:
    • read / write variable
    • log off the system
    • exit without logging out
    • log in to the system
  • Log into both the console and the file.
    • Logs will be stamped with a logical timestamp.
  • Each node will have a unique identification.
    • A combination of IP address and port is recommended.

(Translated from Czech original)

Implementation

Overview

Installation

  1. Clone repository
  2. cd DSV-Semestralka/
  3. npm install -g yarn and yarn install (or just use npm install without installing yarn)
  • To build app into native JavaScript run yarn run build
  • To fork (start/spawn) Node run:
    • yarn start -- <ARGUMENTS> - Native JavaScript (usage)
    • yarn run debug -- <ARGUMENTS> - TypeScript by ts-node (usage)
  • To deploy Nodes to different machines:
    • Edit servers,username,password variables in deploy.js file
    • Run yarn run deploy -- <tip> (<tip> is template IP address)

(You can always use npm instead of yarn)