Framework-Driven Application Development & RESTful Services Flashcards

(17 cards)

1
Q

What is a software library?

A

A reusable archive of shared code (classes, interfaces, exceptions, annotations) that application code calls when needed

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

What is a software framework?

A

A predefined flow of logic with “gaps” for app code. The framework controls execution and calls your code (inversion of control)

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

What principle differentiates frameworks from libraries?

A

Inversion of control: the framework manages execution flow, and developers “plug in” code

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

What is dependency injection?

A

Technique to achieve inversion of control by injecting dependencies rather than hardcoding them

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

What is the Spring framework?

A

An application development framework relying on inversion of control via dependency injection

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

What is a Spring “Bean”?

A

A class managed by the Spring IoC container, with dependencies configured via metadata

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

What is Spring Boot?

A

A Spring-based framework that simplifies setup by providing conventional defaults, eliminating most XML configuration

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

What is HTTP?

A

Hypertext Transfer Protocol — stateless, request/response-based, application-layer protocol

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

What are the main HTTP verbs?

A

GET (fetch), POST (create), PUT (create/update), DELETE (delete)

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

Example URL breakdown:
https://vsb.mcgill.ca:8080/vsb/criteria.jsp?term=202509&courses=ECSE-321

A

Protocol: https

Host: vsb.mcgill.ca

Port: 8080

Path: /vsb/criteria.jsp

Query: term=202509&courses=ECSE-321

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

HTTP Status Code categories?

A

1xx Informational

2xx Success (200 OK, 202 Accepted, 204 No Content)

3xx Redirection (301 Moved, 304 Not Modified)

4xx Client errors (400 Bad Request, 401 Unauthorized, 403 Forbidden, 404 Not Found, 409 Conflict)

5xx Server errors (500 Internal Error, 503 Service Unavailable)

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

What does REST stand for?

A

Representational State Transfer

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

What are the characteristics of RESTful services?

A

Resource-centered

Operate via URIs

Use standard HTTP verbs

Pass data as JSON/XML

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

What does “idempotent” mean in HTTP methods?

A

Repeating a request has the same effect as a single request (e.g., PUT is idempotent, POST is not)

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

Why is JSON commonly used in REST?

A

Lightweight, text-only, human-readable, and easily maps to objects

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

How should REST integrate with MVC?

A

REST aligns best with the Controller (not exposing Model directly), to protect server control and prevent illegal state manipulation

17
Q

Why not expose Model directly in REST?

A

Risks include information leaks, unauthorized state changes, and loss of server-side control