You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by li...@apache.org on 2021/08/12 08:57:26 UTC

[servicecomb-kie] branch ssl updated (557b09e -> 4fb6c9e)

This is an automated email from the ASF dual-hosted git repository.

littlecui pushed a change to branch ssl
in repository https://gitbox.apache.org/repos/asf/servicecomb-kie.git.


 discard 557b09e  Fix: log print without error message
     new 4fb6c9e  Fix: TLS config not work

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (557b09e)
            \
             N -- N -- N   refs/heads/ssl (4fb6c9e)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:

[servicecomb-kie] 01/01: Fix: TLS config not work

Posted by li...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

littlecui pushed a commit to branch ssl
in repository https://gitbox.apache.org/repos/asf/servicecomb-kie.git

commit 4fb6c9efe4071e7c9a06376d68cb52285cc36d2e
Author: little-cui <su...@qq.com>
AuthorDate: Thu Aug 12 16:51:07 2021 +0800

    Fix: TLS config not work
---
 server/config/struct.go  | 17 ++++++++++-------
 server/datasource/dao.go | 13 ++++++++-----
 2 files changed, 18 insertions(+), 12 deletions(-)

diff --git a/server/config/struct.go b/server/config/struct.go
index 1a0a05d..357a84b 100644
--- a/server/config/struct.go
+++ b/server/config/struct.go
@@ -31,13 +31,16 @@ type Config struct {
 
 //DB is yaml file struct to set persistent config
 type DB struct {
-	URI        string `yaml:"uri"`
-	Kind       string `yaml:"kind"`
-	PoolSize   int    `yaml:"poolSize"`
-	SSLEnabled bool   `yaml:"sslEnabled"`
-	RootCA     string `yaml:"rootCAFile"`
-	Timeout    string `yaml:"timeout"`
-	VerifyPeer bool   `yaml:"verifyPeer"`
+	URI         string `yaml:"uri"`
+	Kind        string `yaml:"kind"`
+	PoolSize    int    `yaml:"poolSize"`
+	SSLEnabled  bool   `yaml:"sslEnabled"`
+	RootCA      string `yaml:"rootCAFile"`
+	CertFile    string `yaml:"certFile"`
+	KeyFile     string `yaml:"keyFile"`
+	CertPwdFile string `yaml:"certPwdFile"`
+	Timeout     string `yaml:"timeout"`
+	VerifyPeer  bool   `yaml:"verifyPeer"`
 }
 
 //RBAC is rbac config
diff --git a/server/datasource/dao.go b/server/datasource/dao.go
index bb91425..b181100 100644
--- a/server/datasource/dao.go
+++ b/server/datasource/dao.go
@@ -135,11 +135,14 @@ func Init(c config.DB) error {
 		timeout = DefaultTimeout
 	}
 	dbc := &Config{
-		URI:        c.URI,
-		PoolSize:   c.PoolSize,
-		SSLEnabled: c.SSLEnabled,
-		RootCA:     c.RootCA,
-		Timeout:    timeout,
+		URI:         c.URI,
+		PoolSize:    c.PoolSize,
+		SSLEnabled:  c.SSLEnabled,
+		RootCA:      c.RootCA,
+		CertFile:    c.CertFile,
+		CertPwdFile: c.CertPwdFile,
+		KeyFile:     c.KeyFile,
+		Timeout:     timeout,
 	}
 	if b, err = f(dbc); err != nil {
 		return err