62 Commits

Author SHA1 Message Date
Joachim Van Herwegen
785ec1ee07 fix: Don't buffer data before sending response with InMemoryResourceStore 2020-09-03 11:13:08 +02:00
Ruben Verborgh
a06a7ff685 fix: Determine body presence according to RFC7230
Fixes https://github.com/solid/community-server/issues/121
2020-09-03 10:12:16 +02:00
Ruben Verborgh
85e3117efe refactor: Drop CONTENT_TYPE prefix 2020-09-03 09:52:48 +02:00
Ruben Verborgh
c5c5d13570 refactor: Replace dataType by binary flag 2020-09-03 09:52:48 +02:00
Ruben Verborgh
385e1a4cdf change: Support all PUT operations, error later 2020-09-03 09:02:20 +02:00
Ruben Verborgh
4965b476c9 feat: Send server identification 2020-09-02 16:33:20 +02:00
Ruben Verborgh
273626a799 fix: Ensure main handler ends 2020-09-02 16:33:20 +02:00
Joachim Van Herwegen
199d657097 refactor: Remove overused "Simple" prefix 2020-09-02 15:42:13 +02:00
Joachim Van Herwegen
3931d5f664 feat: Integrate ChainedConverter into the server 2020-09-01 15:39:10 +02:00
Joachim Van Herwegen
af4a82f4c1 feat: Dynamically determine matching types in ChainedConverter 2020-09-01 15:39:10 +02:00
Joachim Van Herwegen
734f7e7f0f feat: Create RepresentationConverter that chains other converters 2020-09-01 15:39:10 +02:00
Ruben Taelman
2c3ae4eded Add generic QuadToRdfConverter 2020-09-01 11:49:49 +02:00
Ruben Taelman
f08e97b80c fix: failing conversion test due to N3 update 2020-09-01 09:00:15 +02:00
Ruben Taelman
e88e680ed7 feat: add support for parsing more RDF formats using rdf-parse 2020-08-31 12:01:47 +02:00
Ruben Taelman
3387092fc3 Move base normalization to RuntimeConfig 2020-08-31 09:24:40 +02:00
Joachim Van Herwegen
86d5f367d5 feat: Support link and slug headers in SimpleBodyParser 2020-08-27 15:51:07 +02:00
Ruben Taelman
48740e5cba style: improve linting of imports
A new plugin is used that offers autofixing capabilities.
2020-08-26 13:20:19 +02:00
Ruben Taelman
5126356c94
feat: Move runtime config into dedicated component, Closes #67
* Move runtime config into dedicated component, Closes #67

* Migrate FileResourceStore to RuntimeConfig
2020-08-26 10:25:47 +02:00
Joachim Van Herwegen
4bc1dcdd1b fix: Remove duplicate checks
These were added when setting TypeScript settings to strict,
but should not be needed due to how AsyncHandlers should be used.
2020-08-25 15:12:01 +02:00
Ruben Taelman
5649903226
fix: Move ACL init into dedicated Setup component 2020-08-25 11:11:29 +02:00
smessie
aa510bc6b8
fix: Release lock only when stream ends or is abandoned (#60)
* fix: Release lock only when stream has ended reading or an error occurs

* refactor: Refactor code and tests

* refactor: Move function mock to onBefore and remove unnecessary data drain

* fix: Make functions protected, add extra listener and add extra tests

* fix: Add extra TSDoc comment

* fix: Adjust tests to expect both end and close event

* refactor: Move test to other file

* refactor: make lockedRun method-independent

* fix: ensure lock release happens only once

* fix: make locked resources time out

* fix: destroy readable on error

Co-authored-by: Ruben Verborgh <ruben@verborgh.org>
2020-08-20 10:51:19 +02:00
Joachim Van Herwegen
b489d69bad fix: Use posix path library to be OS independent 2020-08-18 14:34:32 +02:00
smessie
381dae42f6
feat: Add file based ResourceStore (#52)
* feat: Add file resource store

* test: Write some tests for FileResourceStore

* fix: Reformat code and fix various small things from reviews

* fix: Change constants to just be the corresponding URL

* fix: Remove extra unnecessary wrap in a Promise

* fix: Write some more tests and fix related bugs

* fix: Use old way to import fs promises to support older Node versions

* refactor: Refactor code and tests

* refactor: Refactor and better document code

* fix: Change comparison with undefined by typeof check

* fix: Invert typeof check
2020-08-18 14:19:25 +02:00
Joachim Van Herwegen
e06d0bc8c5 feat: Add more extensive permission parsing support 2020-08-18 11:21:48 +02:00
Joachim Van Herwegen
769b49293c feat: Integrate acl with rest of server 2020-08-18 10:32:07 +02:00
Joachim Van Herwegen
0545ca121e feat: Add acl support 2020-08-18 10:32:07 +02:00
Joachim Van Herwegen
011822e859 fix: Make SimpleResourceStore behaviour closer to expected 2020-08-18 10:32:07 +02:00
Joachim Van Herwegen
4403421c49 feat: Integrate data conversion with rest of server 2020-08-17 15:38:26 +02:00
Joachim Van Herwegen
5e1bb10f81 feat: Convert data from ResourceStore based on preferences 2020-08-17 15:38:26 +02:00
Joachim Van Herwegen
d6a35f9954 fix: Make Patch more consistent with other Representations 2020-08-17 15:38:26 +02:00
Joachim Van Herwegen
14db5fed91 feat: Specifiy constants in separate file 2020-07-28 12:00:17 +02:00
Joachim Van Herwegen
aaba113563 fix: Set max-len to 120 2020-07-24 15:10:34 +02:00
Joachim Van Herwegen
dcff424f58 fix: Enable strict TypeScript settings 2020-07-24 13:30:34 +02:00
Joachim Van Herwegen
4001050588 fix: Have SimpleResourceStore return text/turtle by default 2020-07-23 11:17:53 +02:00
Joachim Van Herwegen
0e486cf6a6 feat: Integrate PATCH functionality 2020-07-23 10:55:53 +02:00
Joachim Van Herwegen
04a12c723e feat: Add support for SPARQL updates on ResourceStores 2020-07-23 10:55:53 +02:00
Joachim Van Herwegen
482991cb9a feat: Add OperationHandler for PATCH 2020-07-23 10:55:53 +02:00
Joachim Van Herwegen
95c65c86a7 feat: Add BodyParser for SPARQL updates 2020-07-23 10:55:53 +02:00
Joachim Van Herwegen
4ac9e92d06 fix: Remove all instances of return undefined
Resolves #26
2020-07-23 08:52:44 +02:00
Joachim Van Herwegen
a9b811a5a3 feature: Add lock functionality 2020-07-17 15:26:32 +02:00
Joachim Van Herwegen
ccd3f1738c fix: Prevent server from crashing if requested data can't be handled 2020-07-17 11:41:46 +02:00
Joachim Van Herwegen
ea788ba406 fix: Throw correct error for invalid triple data 2020-07-17 11:41:46 +02:00
Joachim Van Herwegen
a9dc59bf78 feat: Set up server using express 2020-07-15 10:59:45 +02:00
Joachim Van Herwegen
c53ab5ed9b fix: Prevent data from being drained when read
Comments were also added and URI generation takes slash into account
2020-07-15 10:59:45 +02:00
Joachim Van Herwegen
cff9790b6e fix: Take host into account when extracting identifier 2020-07-15 10:59:45 +02:00
Joachim Van Herwegen
64a3f90831 feat: Validate Accept* headers while parsing 2020-07-08 11:20:28 +02:00
Joachim Van Herwegen
9d9f7df5d1 feat: Fully support Accept* headers 2020-07-08 11:20:28 +02:00
Joachim Van Herwegen
618005675f feat: add simple response writer 2020-06-24 14:08:56 +02:00
Joachim Van Herwegen
fe8749390c feat: add simple operation handlers 2020-06-24 14:08:56 +02:00
Joachim Van Herwegen
12fd00e3b8 feat: add simple resource store 2020-06-24 14:08:56 +02:00