Webserver Flashcards

(4 cards)

1
Q

Was ist ein Webserver?

A

Ein Computer mit Webserver-Software, der Dokumente an Clients wie z.B. Webbrowserübertragt.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Was sind Aufgaben eines Webservers?

A

Verarbeitung und Beantworten von HTTP Anfragen

 Weiterleiten der Anfragen an Handlerroutinen (→ Routing)

 Bereitstellung von statischen Dateien (z.B. Bilder)

 Auslieferung von dynamischen Daten (z.B. Inhalte aus Datenbanken)

 Bereitstellung von APIs (Application Programming Interfaces)

 Datenbank und Dateisystem Interaktionen

 Sitzungs- und Benutzerverwaltung

 Sicherheit: Verschlüsselung, Zugriffsbeschränkung, Protokollierung

 Caching

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Was ist Express?

A

Eins schnelles und minimalistisches Framework für Node.js zum Erstellen von Webserver-Software

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Initialisiere ein Express-Server

A

Initalisiert das Express Framework (
import express, { Request, Response } from “express”;
const app =express();
)
Optionales Middleware-Modul (
import bodyParser from “body-parser”;
app.use(bodyParser.json());
)
Startet Server auf Port 8000 (
const port: number = 8000;
app.listen(port, () => {
console.log(Server läuft: http://127.0.0.1:${port});
});
)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly