From e6ec5a509bf55d77af7b898f851aec239a669526 Mon Sep 17 00:00:00 2001 From: fatedier Date: Tue, 12 Mar 2024 15:14:13 +0800 Subject: [PATCH] update release notes (#4055) --- Release.md | 9 +++++++++ cmd/frpc/sub/root.go | 2 +- cmd/frps/root.go | 2 +- pkg/config/v1/plugin.go | 2 +- pkg/config/v1/proxy.go | 2 +- pkg/config/v1/visitor.go | 2 +- pkg/util/version/version.go | 2 +- test/e2e/v1/plugin/client.go | 3 ++- 8 files changed, 17 insertions(+), 7 deletions(-) diff --git a/Release.md b/Release.md index c0d90bb..babea4c 100644 --- a/Release.md +++ b/Release.md @@ -1,3 +1,12 @@ +### Notable Changes + +* The minimum supported Go version has been updated to `1.22`. In the new version of Go, the default minimum supported TLS version has been changed to `TLS 1.2`. +* The default value of `--strict-config` has been changed from `false` to `true`. If your configuration file uses a non-existent configuration item or has a spelling error, the application will throw an error. This startup parameter was introduced in version `v0.53.0`. If you wish to continue using the old behavior, you need to explicitly set `--strict-config=false`. + ### Features * Proxy supports configuring annotations, which will be displayed in the frps dashboard. + +### Changes + +* Removed dependencies on the forked version of kcp-go and beego log, kcp-go now uses the upstream version, and golib/log replaces beego log. diff --git a/cmd/frpc/sub/root.go b/cmd/frpc/sub/root.go index a496d07..b844ddf 100644 --- a/cmd/frpc/sub/root.go +++ b/cmd/frpc/sub/root.go @@ -46,7 +46,7 @@ func init() { rootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "c", "./frpc.ini", "config file of frpc") rootCmd.PersistentFlags().StringVarP(&cfgDir, "config_dir", "", "", "config directory, run one frpc service for each file in config directory") rootCmd.PersistentFlags().BoolVarP(&showVersion, "version", "v", false, "version of frpc") - rootCmd.PersistentFlags().BoolVarP(&strictConfigMode, "strict_config", "", false, "strict config parsing mode, unknown fields will cause an error") + rootCmd.PersistentFlags().BoolVarP(&strictConfigMode, "strict_config", "", true, "strict config parsing mode, unknown fields will cause an errors") } var rootCmd = &cobra.Command{ diff --git a/cmd/frps/root.go b/cmd/frps/root.go index d69df5f..fff487d 100644 --- a/cmd/frps/root.go +++ b/cmd/frps/root.go @@ -40,7 +40,7 @@ var ( func init() { rootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "c", "", "config file of frps") rootCmd.PersistentFlags().BoolVarP(&showVersion, "version", "v", false, "version of frps") - rootCmd.PersistentFlags().BoolVarP(&strictConfigMode, "strict_config", "", false, "strict config parsing mode, unknown fields will cause error") + rootCmd.PersistentFlags().BoolVarP(&strictConfigMode, "strict_config", "", true, "strict config parsing mode, unknown fields will cause errors") config.RegisterServerConfigFlags(rootCmd, &serverCfg) } diff --git a/pkg/config/v1/plugin.go b/pkg/config/v1/plugin.go index db9d0d1..5602a81 100644 --- a/pkg/config/v1/plugin.go +++ b/pkg/config/v1/plugin.go @@ -57,7 +57,7 @@ func (c *TypedClientPluginOptions) UnmarshalJSON(b []byte) error { } if err := decoder.Decode(options); err != nil { - return err + return fmt.Errorf("unmarshal ClientPluginOptions error: %v", err) } c.ClientPluginOptions = options return nil diff --git a/pkg/config/v1/proxy.go b/pkg/config/v1/proxy.go index cf87037..c906543 100644 --- a/pkg/config/v1/proxy.go +++ b/pkg/config/v1/proxy.go @@ -186,7 +186,7 @@ func (c *TypedProxyConfig) UnmarshalJSON(b []byte) error { decoder.DisallowUnknownFields() } if err := decoder.Decode(configurer); err != nil { - return err + return fmt.Errorf("unmarshal ProxyConfig error: %v", err) } c.ProxyConfigurer = configurer return nil diff --git a/pkg/config/v1/visitor.go b/pkg/config/v1/visitor.go index a9b2411..e9fa166 100644 --- a/pkg/config/v1/visitor.go +++ b/pkg/config/v1/visitor.go @@ -114,7 +114,7 @@ func (c *TypedVisitorConfig) UnmarshalJSON(b []byte) error { decoder.DisallowUnknownFields() } if err := decoder.Decode(configurer); err != nil { - return err + return fmt.Errorf("unmarshal VisitorConfig error: %v", err) } c.VisitorConfigurer = configurer return nil diff --git a/pkg/util/version/version.go b/pkg/util/version/version.go index 27ed32e..c25574d 100644 --- a/pkg/util/version/version.go +++ b/pkg/util/version/version.go @@ -14,7 +14,7 @@ package version -var version = "0.54.0" +var version = "0.55.0" func Full() string { return version diff --git a/test/e2e/v1/plugin/client.go b/test/e2e/v1/plugin/client.go index f544570..476adb8 100644 --- a/test/e2e/v1/plugin/client.go +++ b/test/e2e/v1/plugin/client.go @@ -30,10 +30,11 @@ var _ = ginkgo.Describe("[Feature: Client-Plugins]", func() { name = "%s" type = "tcp" remotePort = {{ .%s }} + `+extra, proxyName, portName) + fmt.Sprintf(` [proxies.plugin] type = "unix_domain_socket" unixPath = "{{ .%s }}" - `+extra, proxyName, portName, framework.UDSEchoServerAddr) + `, framework.UDSEchoServerAddr) } tests := []struct {