@midwayjs/consul 3.0.0-beta.1 → 3.0.0-beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,41 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.0.0-beta.5](https://github.com/midwayjs/midway/compare/v3.0.0-beta.4...v3.0.0-beta.5) (2021-11-25)
7
+
8
+ **Note:** Version bump only for package @midwayjs/consul
9
+
10
+
11
+
12
+
13
+
14
+ # [3.0.0-beta.4](https://github.com/midwayjs/midway/compare/v3.0.0-beta.3...v3.0.0-beta.4) (2021-11-24)
15
+
16
+ **Note:** Version bump only for package @midwayjs/consul
17
+
18
+
19
+
20
+
21
+
22
+ # [3.0.0-beta.3](https://github.com/midwayjs/midway/compare/v3.0.0-beta.2...v3.0.0-beta.3) (2021-11-18)
23
+
24
+
25
+ ### Features
26
+
27
+ * add component and framework config definition ([#1367](https://github.com/midwayjs/midway/issues/1367)) ([b2fe615](https://github.com/midwayjs/midway/commit/b2fe6157f99659471ff1333eca0b86bb889f61a3))
28
+
29
+
30
+
31
+
32
+
33
+ # [3.0.0-beta.2](https://github.com/midwayjs/midway/compare/v3.0.0-beta.1...v3.0.0-beta.2) (2021-11-16)
34
+
35
+ **Note:** Version bump only for package @midwayjs/consul
36
+
37
+
38
+
39
+
40
+
6
41
  # [3.0.0-beta.1](https://github.com/midwayjs/midway/compare/v2.12.4...v3.0.0-beta.1) (2021-11-14)
7
42
 
8
43
  **Note:** Version bump only for package @midwayjs/consul
@@ -11,8 +11,8 @@ var __metadata = (this && this.__metadata) || function (k, v) {
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.ConsulConfiguration = void 0;
13
13
  const decorator_1 = require("@midwayjs/decorator");
14
- const path_1 = require("path");
15
14
  const provider_1 = require("./lib/provider");
15
+ const DefaultConfig = require("./config/config.default");
16
16
  let ConsulConfiguration = class ConsulConfiguration {
17
17
  get consulProvider() {
18
18
  const symbol = Symbol('consulProvider');
@@ -80,7 +80,11 @@ __decorate([
80
80
  ConsulConfiguration = __decorate([
81
81
  (0, decorator_1.Configuration)({
82
82
  namespace: 'consul',
83
- importConfigs: [(0, path_1.join)(__dirname, 'config')],
83
+ importConfigs: [
84
+ {
85
+ default: DefaultConfig,
86
+ },
87
+ ],
84
88
  })
85
89
  ], ConsulConfiguration);
86
90
  exports.ConsulConfiguration = ConsulConfiguration;
@@ -1,5 +1,5 @@
1
- import * as Consul from "consul";
2
- import { ConsulOptions } from "consul";
1
+ import * as Consul from 'consul';
2
+ import { ConsulOptions } from 'consul';
3
3
  import RegisterOptions = Consul.Agent.Service.RegisterOptions;
4
4
  export interface IServiceBalancer {
5
5
  /**
@@ -65,4 +65,10 @@ export interface IConsulRegisterInfoOptions extends RegisterOptions {
65
65
  status?: string;
66
66
  };
67
67
  }
68
+ declare module '@midwayjs/core/dist/interface' {
69
+ interface MidwayConfig {
70
+ consul?: IConsulProviderInfoOptions;
71
+ service?: IConsulRegisterInfoOptions;
72
+ }
73
+ }
68
74
  //# sourceMappingURL=interface.d.ts.map
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@midwayjs/consul",
3
3
  "description": "midway consul",
4
- "version": "3.0.0-beta.1",
4
+ "version": "3.0.0-beta.5",
5
5
  "main": "dist/index",
6
6
  "typings": "dist/index.d.ts",
7
7
  "files": [
@@ -9,10 +9,10 @@
9
9
  "dist/**/*.d.ts"
10
10
  ],
11
11
  "devDependencies": {
12
- "@midwayjs/core": "^3.0.0-beta.1",
13
- "@midwayjs/decorator": "^3.0.0-beta.1",
14
- "@midwayjs/koa": "^3.0.0-beta.1",
15
- "@midwayjs/mock": "^3.0.0-beta.1",
12
+ "@midwayjs/core": "^3.0.0-beta.5",
13
+ "@midwayjs/decorator": "^3.0.0-beta.5",
14
+ "@midwayjs/koa": "^3.0.0-beta.5",
15
+ "@midwayjs/mock": "^3.0.0-beta.5",
16
16
  "@types/consul": "^0.23.34",
17
17
  "@types/sinon": "^10.0.2",
18
18
  "nock": "^13.0.11"
@@ -39,5 +39,5 @@
39
39
  "type": "git",
40
40
  "url": "https://github.com/midwayjs/midway.git"
41
41
  },
42
- "gitHead": "72e4d20c678e65a5440c4e9a6d3b70046daa497c"
42
+ "gitHead": "ab0bf05ae6d13f6435db2f7223202be61d585a1b"
43
43
  }