@@ -124,6 +124,53 @@ class Configuration @JvmOverloads constructor(
124
124
)
125
125
}
126
126
127
+ @Deprecated(
128
+ " backward compatibility for https://github.com/jasync-sql/jasync-sql/issues/359" ,
129
+ ReplaceWith (" copy()" ),
130
+ DeprecationLevel .ERROR ,
131
+ )
132
+ fun copy (
133
+ username : String? = null,
134
+ host : String? = null,
135
+ port : Int? = null,
136
+ password : String? = null,
137
+ database : String? = null,
138
+ ssl : SSLConfiguration ? = null,
139
+ charset : Charset ? = null,
140
+ maximumMessageSize : Int ,
141
+ allocator : ByteBufAllocator ? = null,
142
+ connectionTimeout : Int ,
143
+ queryTimeout : Duration ? = null,
144
+ applicationName : String? = null,
145
+ interceptors : List <Supplier <QueryInterceptor >>? = null,
146
+ eventLoopGroup : EventLoopGroup ? = null,
147
+ executionContext : Executor ? = null,
148
+ currentSchema : String? = null,
149
+ socketPath : String? = null,
150
+ ): Configuration {
151
+ return Configuration (
152
+ username = username ? : this .username,
153
+ host = host ? : this .host,
154
+ port = port ? : this .port,
155
+ password = password ? : this .password,
156
+ database = database ? : this .database,
157
+ ssl = ssl ? : this .ssl,
158
+ charset = charset ? : this .charset,
159
+ maximumMessageSize = maximumMessageSize,
160
+ allocator = allocator ? : this .allocator,
161
+ connectionTimeout = connectionTimeout,
162
+ queryTimeout = queryTimeout ? : this .queryTimeout,
163
+ applicationName = applicationName ? : this .applicationName,
164
+ interceptors = interceptors ? : this .interceptors,
165
+ eventLoopGroup = eventLoopGroup ? : this .eventLoopGroup,
166
+ executionContext = executionContext ? : this .executionContext,
167
+ currentSchema = currentSchema ? : this .currentSchema,
168
+ socketPath = socketPath ? : this .socketPath,
169
+ credentialsProvider = this .credentialsProvider,
170
+ rsaPublicKey = this .rsaPublicKey,
171
+ )
172
+ }
173
+
127
174
override fun equals (other : Any? ): Boolean {
128
175
if (this == = other) return true
129
176
if (javaClass != other?.javaClass) return false
0 commit comments