1 |
|
2 |
|
3 | <a name="0.5.0"></a>
|
4 | ## [0.5.0](https://github.com/miter-framework/miter/compare/0.4.0...HEAD) (_Future_)
|
5 |
|
6 | Big things planned! More unit tests! Less ORM quirks! More awesomeness!
|
7 |
|
8 |
|
9 |
|
10 | <a name="0.4.0"></a>
|
11 | ## [0.4.0](https://github.com/miter-framework/miter/compare/0.3.0...0.4.0) (2017-07-26)
|
12 |
|
13 | ### Features
|
14 |
|
15 | * **orm:** allow update queries to have includes if returning = true
|
16 | * **orm:** allow deeply-nested associations to be implicitly included in where query
|
17 | * **orm:** extract performCreate and performUpdate hooks in CrudController
|
18 | * **orm:** allow TransactionService.run to create detached transactions
|
19 | * **orm:** allow the Transaction decorator to create detached transactions
|
20 | * **test:** add unit tests for JwtBasePolicy
|
21 | * **injector:** add cache and deps options to providers that use factory functions
|
22 | * **injector:** allow metadata to be defined and injected into provide factory functions
|
23 | * **logger:** infer subsystem based on the name of the injectable the logger is injected into
|
24 | * **injector:** allow injectables to define custom factory function providers
|
25 |
|
26 | ### Bug Fixes
|
27 |
|
28 | * **orm:** add implicit include only if the value is non-null and has no id
|
29 |
|
30 | ### Breaking Changes
|
31 |
|
32 | * Server.logger is now private.
|
33 | If you need an instance of a logger, you can dependency inject Logger or LoggerCore.
|
34 | If you need to do this through code, you can manually grab the logger like this:
|
35 | ```typescript
|
36 | import { Miter, LoggerCore, Logger } from 'miter';
|
37 | let server = await Miter.launch({ ... });
|
38 | let logger: Logger = server.injector.resolveInjectable(LoggerCore).getSubsystem('my-subsystem');
|
39 | ```
|
40 | * The Logger methods no longer accept a subsystem. This includes `log`, `trace`, `error`, `info`, `warn`, and `verbose`.
|
41 | Instead of requiring the subsystem every time you need to log a message, the logger will use the name of the class the logger is injected into.
|
42 | If you want to provide a specific subsystem, you can use the new Name decorator to override the default behavior.
|
43 | In this example, the class is 'TransactionService' but the subsystem is 'transactions':
|
44 | ```
|
45 | @Injectable()
|
46 | @Name('transactions')
|
47 | export class TransactionService {
|
48 | constructor(private logger: Logger) {
|
49 | logger.info('This message will use my overridden subsystem name');
|
50 | }
|
51 | }
|
52 | ```
|
53 | * The constructors for JwtBasePolicy, JwtPolicy, and RequiredJwtPolicy now require a LoggerCore instead of a logger.
|
54 | If you provide your own implementation of one of these classes, make sure you update them to the correct type.
|
55 | * Injector.resolveDependency throws more errors.
|
56 | Previously it silently swallowed some circular dependency errors, and it only logged falsey injections.
|
57 | Now it will fail fast when one of these errors occur.
|
58 |
|
59 |
|
60 |
|
61 | <a name="0.3.0"></a>
|
62 | ## [0.3.0](https://github.com/miter-framework/miter/compare/0.2.0...0.3.0) (2017-06-05)
|
63 |
|
64 | ### Features
|
65 |
|
66 | * **build:** remove pre-commit hook that sometimes broke development pipeline
|
67 | * **build:** upgrade to typescript@2.3.0
|
68 | * **router:** add res.sendFiles as a replacement for express.static
|
69 | * **orm:** allow where queries to filter by details on associated tabled
|
70 | * **orm:** allow has-many associations in where queries
|
71 | * **orm:** allow nested includes using dot-notation
|
72 | * **tests:** add lots, lots more unit tests
|
73 |
|
74 | ### Bug Fixes
|
75 |
|
76 | * **services:** only shut down services if they started successfully
|
77 | * **router:** add multiple routes on the same method in the order they are listed as decorators
|
78 | * **orm:** only attempt to connect to a sql server if the orm is not disabled
|
79 | * **orm:** transform included association results instead of simply copying the values
|
80 | * **tests:** add double quotes around the mocha test path to ensure all tests are included
|
81 |
|
82 |
|
83 |
|
84 | <a name="0.2.0"></a>
|
85 | ## [0.2.0](https://github.com/miter-framework/miter/compare/0.1.4...0.2.0) (2017-05-05)
|
86 |
|
87 | ### Features
|
88 |
|
89 | * **repository:** add README.md sample controller and project information
|
90 | * **repository:** add CHANGELOG.md to record changes between versions
|
91 | * **ci:** add .travis.yml and enable TravisCI builds
|
92 | * **tests:** add a unit testing framework and test the built-in services and utility functions
|
93 | * **middleware:** gracefully handle an empty array of middleware functions
|
94 | * **orm:** add the Sanitize decorator to ensure private data is removed before serializing it
|
95 | * **orm:** add Flag decorator as a shorthand for a non-null boolean column with "false" as the default value
|
96 | * **router:** allow users to mount controllers on other controllers
|
97 | * **router:** allow routes to await res.sendFile
|
98 | * **router:** allow controllers to dynamically change route policies at runtime
|
99 | * **crud-controller:** add findOne route to the CrudController
|
100 |
|
101 | ### Bug Fixes
|
102 |
|
103 | * **repl-service:** only create the ReadLine interface if you inject the ReplService
|
104 | * **orm:** allow SQL and and or queries to be objects or arrays
|
105 |
|
106 |
|
107 |
|
108 | <a name="0.1.4"></a>
|
109 | ## [0.1.4](https://github.com/miter-framework/miter/tree/0.1.4) (2017-04-05)
|
110 |
|
111 | Changes before this point in time have not been recorded here.
|