An arrow function does not have its own bindings to this or super, this is inherited from the scope. In regular function, this is the function itself (it has its own scope).
In Vue, the parent-child component relationship can be summarized as props down, events up. The parent passes data down to the child via props, and the child sends messages to the parent via events…
Pass Data Between Parent and Child Components
props and $emit
Using props to share data from parent to child
Emitting custom events to share data from child to parent
parent.vue
<template> <div style="padding: 10px 10px 10px 10px"> <h2>This is the parent page</h2> <div> <button @click="onSendClick">Send to Child</button> </div> <div> Received from child by emit: {{receiveFromChild}} </div> <Child :name="childName" @receiveFromChild="onReceiveFromChild"/> </div> </template>
For 8.0.12 and earlier: Use SSL when communicating with the server (true/false), default is ‘true’ when connecting to MySQL 5.5.45+, 5.6.26+ or 5.7.6+, otherwise default is ‘false’.
For 8.0.13 and later: Default is ‘true’. DEPRECATED. See sslMode property description for details.
Default Value: true
Since Version: 3.0.2
autoReconnect
Should the driver try to re-establish stale and/or dead connections
Default Value: false
Since Version: 1.1
maxReconnects
Maximum number of reconnects to attempt if autoReconnect is true, default is ‘3’.
useSSL=true autoReconnect=true
Others
Timeout
initialTimeout
If autoReconnect is enabled, the initial time to wait between re-connect attempts (in seconds, defaults to ‘2’).
Default Value: 2
Since Version: 1.1
connectTimeout
Timeout for socket connect (in milliseconds), with 0 being no timeout. Only works on JDK-1.4 or newer. Defaults to ‘0’.
Default Value: 0
Since Version: 3.0.1
socketTimeout
Timeout (in milliseconds) on network socket operations (0, the default means no timeout).
Using MyBatis to query DATETIME type column data from MySQL table, if the column value is 0000-00-00 00:00:00, the program will throw exception Java.sql.SQLException. The following are the column properties.
pubtime DATETIME NULLDEFAULTNULL
Error Info
Error attempting to get column 'pubtime' from result set. Cause: java.sql.SQLException: Zero date value prohibited ; Zero date value prohibited; nested exception is java.sql.SQLException: Zero date value prohibited org.springframework.dao.TransientDataAccessResourceException: Error attempting to get column 'pubtime' from result set. Cause: java.sql.SQLException: Zero date value prohibited ; Zero date value prohibited; nested exception is java.sql.SQLException: Zero date value prohibited
Solutions
To set up zeroDateTimeBehavior=convertToNull in JdbcUrl. zeroDateTimeBehavior values can be EXCEPTION, ROUND, and CONVERT_TO_NULL. The default value of zeroDateTimeBehavior is EXCEPTION.
Using @Component inject the bean to the Spring IoC container.
Using @Value read application configurations of Spring into non-static fields.
Implements InitializingBean override afterPropertiesSet() method. Assigning non-static field values to static field values in afterPropertiesSet() method.