-
b0e25b431c
ToHTTPServer now returns the exported field http.Handler instead of an unexported type
Adrien Marquès
2020-04-04 10:39:02 +0200
-
b1498e59c1
clarity rename: dynamic package to dynfunc
Adrien Marquès
2020-04-04 10:36:52 +0200
-
eb690cf862
add api errors for storage
Adrien Marquès
2020-04-04 10:08:11 +0200
-
e1606273dd
remove useless func type
Adrien Marquès
2020-04-04 10:05:27 +0200
-
8fa18cd61b
enforce dynamic signature check: no input struct allowed when no input is specified
Adrien Marquès
2020-04-04 10:02:48 +0200
-
db4429b329
ignore empty param renames when creating the spec, not after
Adrien Marquès
2020-03-29 19:33:26 +0200
-
b48c1d07bf
test: spec add checkOutput() tests for : nil type (ignore type check) ; invalid last output (not api.Error)
Adrien Marquès
2020-03-29 19:31:08 +0200
-
307021bc88
test: spec checkOutput() method
Adrien Marquès
2020-03-29 19:23:13 +0200
-
261e25c127
fix: invert conversion check
Adrien Marquès
2020-03-29 19:23:02 +0200
-
438e308f71
merge duplicate errors
Adrien Marquès
2020-03-29 19:22:43 +0200
-
7e42c1b6d9
test: spec checkInput() method
Adrien Marquès
2020-03-29 19:14:12 +0200
-
66985dfbd0
forbid unexported input/output name
Adrien Marquès
2020-03-29 19:13:07 +0200
-
-
4877d0ea23
Merge branch 'feature/dynamic-handler-signature' of go/aicra into 0.3.0
v0.3.0
master
Adrien Marquès
2020-03-29 15:10:04 +0000
-
-
8a0a20294c
rename output fields to original name (not rename)
Adrien Marquès
2020-03-29 17:01:24 +0200
-
d7acf771ad
implement the dynamic handler : fill input struct, do the call, fill return struct
Adrien Marquès
2020-03-29 17:01:02 +0200
-
a5424d8941
parse output in internal/config to find the datatype's reflect.Type()
Adrien Marquès
2020-03-29 16:59:32 +0200
-
a3daab7de4
dynamic handler output struct must be a pointer; no more a regular struct
Adrien Marquès
2020-03-29 16:58:53 +0200
-
00e2a96c79
fix: ErrNoMatchFound error
Adrien Marquès
2020-03-29 16:22:32 +0200
-
e7dd1e7a56
migrate handler from api to aicra; check for service when setting handler
Adrien Marquès
2020-03-29 15:04:12 +0200
-
081e48002f
create dynamic package to handle reflection at runtime to check for handlers signature
Adrien Marquès
2020-03-29 15:00:22 +0200
-
974f58fb8e
parse 'out' for internal config
Adrien Marquès
2020-03-29 14:18:38 +0200
-
ca2be1415d
enforce 'name' for capture or query parameters
Adrien Marquès
2020-03-29 14:18:05 +0200
-
b15bb578ce
delegate from internal.service to parameter.Validate()
Adrien Marquès
2020-03-29 14:12:47 +0200
-
76cc2f5279
replace datatype.Kind() with Type()
Adrien Marquès
2020-03-28 19:11:23 +0100
-
8cfa2235d6
add Kind() method to datatype.T interface and to config parameter
Adrien Marquès
2020-03-28 18:48:27 +0100
-
-
cb7f22e03d
remove useless readme assets
Adrien Marquès
2020-03-28 15:45:56 +0100
-
d3e8d48bc3
Merge branch 'refactor/const-api-errors' of go/aicra into 0.3.0
Adrien Marquès
2020-03-28 14:01:08 +0000
-
-
af09466013
migrate api.response to const errors; make HandlerFn return an api.Error; rename http HandlFunc to Handle;
Adrien Marquès
2020-03-28 14:57:28 +0100
-
5504e4b3ec
make api errors int; allow for const defaults
Adrien Marquès
2020-03-28 14:51:49 +0100
-
-
2f9534a3b0
Merge branch 'refactor/config-validator' of go/aicra into 0.3.0
Adrien Marquès
2020-03-28 11:33:34 +0000
-
-
49cf06d5d8
implement validator interface for config.server; refactor
Adrien Marquès
2020-03-28 12:31:44 +0100
-
af3ffa7d6a
implement validator interface for config.service; rename for readability
Adrien Marquès
2020-03-28 12:30:57 +0100
-
dac9aa4298
implement validator interface for config.parameter
Adrien Marquès
2020-03-28 12:28:58 +0100
-
54705b7472
create validator interface for config
Adrien Marquès
2020-03-28 12:26:11 +0100
-
5f3aa5967d
provide datatype registry to every type to allow for recursive datatypes : slices, maps, structs
Adrien Marquès
2020-03-22 16:50:10 +0100
-
eef94ff998
also check method when finding missing handlers
Adrien Marquès
2020-03-22 16:37:43 +0100
-
-
97cf19d7b4
update readme
Adrien Marquès
2020-03-22 15:03:35 +0100
-
d57f60c710
set content-type to json before writing response
Adrien Marquès
2020-03-22 14:05:47 +0100
-
ad6de97979
fix: actually get service handler
Adrien Marquès
2020-03-22 14:05:32 +0100
-
2ee48560b6
make ToHTTPServer() check for missing handlers
Adrien Marquès
2020-03-21 16:53:19 +0100
-
a15a5c1f7a
fix: register mismatch when no brace capture
Adrien Marquès
2020-03-21 15:58:05 +0100
-
5fe983c486
display both services in pattern collision error messages
Adrien Marquès
2020-03-21 15:57:35 +0100
-
3017cc5ba9
add method tests for pattern collision
Adrien Marquès
2020-03-21 15:52:07 +0100
-
9c3166397f
add tests for service collision
Adrien Marquès
2020-03-21 15:49:07 +0100
-
e3adbf48ca
consider collision only if every part is matching
Adrien Marquès
2020-03-21 15:48:59 +0100
-
0e6dfbe580
make pattern collission error message explicit
Adrien Marquès
2020-03-21 15:15:33 +0100
-
d6c22b5ff0
adapt server to previous api changes
Adrien Marquès
2020-03-21 14:49:36 +0100
-
9a5b0dd6e3
remove Parameter type, only keep method parseParameter()
Adrien Marquès
2020-03-21 14:45:39 +0100
-
149ec9a9a0
internal/reqdata Parse() does not return errors anymore
Adrien Marquès
2020-03-21 14:20:26 +0100
-
3a258400c0
remove api useless errors : UnkonwnMethod and UncallableMethod
Adrien Marquès
2020-03-21 14:19:35 +0100
-
9475fe4526
use private errors do avoid overlapping types among packages
Adrien Marquès
2020-03-21 14:19:14 +0100
-
3606f9984d
update tests for internal/reqdata set
Adrien Marquès
2020-03-20 22:36:15 +0100
-
7b812c6648
get data from multipart components
Adrien Marquès
2020-03-20 22:35:53 +0100
-
dc34d9a81a
wrap multipart errors in dedicated error : ErrInvalidMultipart
Adrien Marquès
2020-03-20 22:35:30 +0100
-
cdbe4cceac
ignore io.EOF while parsing multipart
Adrien Marquès
2020-03-20 22:27:01 +0100
-
03d5e87c37
wrap json parser into dedicated error : ErrInvalidJSON
Adrien Marquès
2020-03-20 22:26:43 +0100
-
c7aa87c660
ignore EOF when parsing form as json
Adrien Marquès
2020-03-20 22:18:34 +0100
-
0f62fc25a0
use request.URL.RequestURI() insteaf of request.RequestURI() ; it is not the same
Adrien Marquès
2020-03-20 22:09:38 +0100
-
8c539370aa
remove cerr
Adrien Marquès
2020-03-16 12:53:48 +0100
-
acd0e73438
remove typecheck
Adrien Marquès
2020-03-16 12:53:37 +0100
-
b38a9a8111
refactor internal/reqdata to work with thew new config
Adrien Marquès
2020-03-16 12:50:30 +0100
-
93b31b9718
keep references to Form parameters
Adrien Marquès
2020-03-16 11:48:44 +0100
-
12417f7f1c
reference query parameters in config.Service
Adrien Marquès
2020-03-16 11:32:37 +0100
-
e7f10723a6
check for undefined brace captures + make tests parallel
Adrien Marquès
2020-03-16 10:56:26 +0100
-
c32b038da2
make splitURL public
Adrien Marquès
2020-03-16 09:26:10 +0100
-
1b4922693b
move config -> internal.config and config.datatype to datatype
Adrien Marquès
2020-03-16 09:20:00 +0100
-
4e0d669029
make config.Service members public
Adrien Marquès
2020-03-16 09:01:51 +0100
-
2c1b9cf5ff
make captures public
Adrien Marquès
2020-03-15 01:38:49 +0100
-
d1ab4fefb0
add brace captures and check between param and pattern (keep them so no need to check them at each req)
Adrien Marquès
2020-03-15 01:37:28 +0100
-
32aff3e07f
bcupdate: add service.Match, parameter.assignDataType, service.matchPattern, server.collide
Adrien Marquès
2020-03-15 00:27:54 +0100
-
6a144a9a93
rename Builder into semantic DataType
Adrien Marquès
2020-03-14 16:16:30 +0100
-
511070196b
add validator to service input parameter
Adrien Marquès
2020-03-14 16:14:04 +0100
-
e12c52b88f
migrate typecheck.builtin into config.datatype.builtin
Adrien Marquès
2020-03-14 16:13:38 +0100
-
003fe4d2e7
create config.datatype replacing typecheck
Adrien Marquès
2020-03-14 16:13:05 +0100
-
a6f5083f0d
bcupdate: make config flat, rewrite, simplify, test
Adrien Marquès
2020-03-14 15:24:17 +0100
-
acdba4121b
rename ambiguous variable
Adrien Marquès
2020-03-09 19:12:26 +0100
-
43c758b615
Merge branch '0.2.0' of go/aicra into master
v0.2.0
0.2.0
Adrien Marquès
2020-03-08 15:28:41 +0000
-
-
9103d752c3
upgrade go version to 1.14
Adrien Marquès
2020-03-08 16:17:55 +0100
-
1225e3b1f2
refactor server handler, rename for readability
Adrien Marquès
2020-03-03 18:36:52 +0100
-
682e20a959
test primitive types : bool, float64
Adrien Marquès
2020-03-02 22:49:17 +0100
-
ec152aec4b
fix parsing primitive types instead of erroring unknown type
Adrien Marquès
2020-03-02 22:45:58 +0100
-
ccf6577bc5
test bool slice vs. json bool slice
Adrien Marquès
2020-03-02 22:42:59 +0100
-
5dad0ecc39
test string slice vs. json string slice
Adrien Marquès
2020-03-02 22:42:45 +0100
-
4cb62ea122
fix parsing non-string slice values
Adrien Marquès
2020-03-02 22:42:17 +0100
-
313b91bb7f
remove outdated tests
Adrien Marquès
2020-03-02 22:34:34 +0100
-
5741ec597b
[breaking] do not return first element of 1-sized slices as it, return a slice
Adrien Marquès
2020-03-02 22:24:36 +0100
-
7e7eb3ac29
fix returning first element of 1-sized slice instead of the slice
Adrien Marquès
2020-03-02 22:20:28 +0100
-
e132a5af42
test conversion from 1-sized slice to first element (bool vs json boolean primitive)
Adrien Marquès
2020-03-02 22:19:28 +0100
-
41d166529c
test json invalid float primitives ; only valid when wrapped
Adrien Marquès
2020-03-02 22:01:16 +0100
-
45675713e7
fix formatting type
Adrien Marquès
2020-03-02 22:00:39 +0100
-
0395d763d6
test json invalid boolean primitives ; only valid when wrapped
Adrien Marquès
2020-03-02 21:56:05 +0100
-
4d663fc56c
test string slice as string ; invalid json but valid when wrapped
Adrien Marquès
2020-03-02 21:51:06 +0100
-
43fb3bb7c9
test uint builtin typecheck overflow values for []byte
Adrien Marquès
2020-03-01 21:43:28 +0100
-
8fbe3dc178
test regex for builtin string typecheck
Adrien Marquès
2020-03-01 21:41:20 +0100
-
98878eb127
test simple string parameter
Adrien Marquès
2020-03-01 21:34:14 +0100
-
fab09b2a5b
fix: mark parameter as parsed after successful parsing
Adrien Marquès
2020-02-28 18:41:05 +0100
-
b890fa0ccc
return error when parsing parameters
Adrien Marquès
2020-02-28 17:50:55 +0100
-
edc49d9915
expand store.go coverage to 100% with a tricky test
Adrien Marquès
2019-11-21 23:21:59 +0100
-
f076f3a88a
replace bytes.NewBufferString() with strings.NewReader()
Adrien Marquès
2019-11-21 23:00:42 +0100
-
727737ae67
test multipart body paramters
Adrien Marquès
2019-11-21 22:58:03 +0100