- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我无法在 rPi 上运行 ScadaLTS。
Aug 17, 2017 7:01:14 AM org.apache.catalina.startup.ClassLoaderFactory validateFile
WARNING: Problem with directory [/usr/share/tomcat7/common/classes], exists: [false], isDirectory: [false], canRead: [false]
Aug 17, 2017 7:01:14 AM org.apache.catalina.startup.ClassLoaderFactory validateFile
WARNING: Problem with directory [/usr/share/tomcat7/common], exists: [false], isDirectory: [false], canRead: [false]
Aug 17, 2017 7:01:14 AM org.apache.catalina.startup.ClassLoaderFactory validateFile
WARNING: Problem with directory [/usr/share/tomcat7/server/classes], exists: [false], isDirectory: [false], canRead: [false]
Aug 17, 2017 7:01:14 AM org.apache.catalina.startup.ClassLoaderFactory validateFile
WARNING: Problem with directory [/usr/share/tomcat7/server], exists: [false], isDirectory: [false], canRead: [false]
Aug 17, 2017 7:01:14 AM org.apache.catalina.startup.ClassLoaderFactory validateFile
WARNING: Problem with directory [/usr/share/tomcat7/shared/classes], exists: [false], isDirectory: [false], canRead: [false]
Aug 17, 2017 7:01:14 AM org.apache.catalina.startup.ClassLoaderFactory validateFile
WARNING: Problem with directory [/usr/share/tomcat7/shared], exists: [false], isDirectory: [false], canRead: [false]
Aug 17, 2017 7:01:16 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Aug 17, 2017 7:01:16 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1613 ms
Aug 17, 2017 7:01:16 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Aug 17, 2017 7:01:16 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.56 (Debian)
Aug 17, 2017 7:01:16 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive /var/lib/tomcat7/webapps/ScadaBR.war
Aug 17, 2017 7:01:29 AM org.apache.catalina.core.StandardContext checkUnusualURLPattern
INFO: Suspicious url pattern: "/**" in context [/ScadaBR] - see sections 12.1 and 12.2 of the Servlet specification
Aug 17, 2017 7:01:30 AM org.apache.tomcat.jdbc.pool.ConnectionPool init
WARNING: maxIdle is larger than maxActive, setting maxIdle to: 80
Aug 17, 2017 7:01:31 AM org.apache.tomcat.jdbc.pool.ConnectionPool init
SEVERE: Unable to create initial connections of pool.
java.sql.SQLException
at org.apache.tomcat.jdbc.pool.PooledConnection.connectUsingDriver(PooledConnection.java:254)
at org.apache.tomcat.jdbc.pool.PooledConnection.connect(PooledConnection.java:182)
at org.apache.tomcat.jdbc.pool.ConnectionPool.createConnection(ConnectionPool.java:701)
at org.apache.tomcat.jdbc.pool.ConnectionPool.borrowConnection(ConnectionPool.java:635)
at org.apache.tomcat.jdbc.pool.ConnectionPool.init(ConnectionPool.java:486)
at org.apache.tomcat.jdbc.pool.ConnectionPool.<init>(ConnectionPool.java:144)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.pCreatePool(DataSourceProxy.java:116)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.createPool(DataSourceProxy.java:103)
at org.apache.tomcat.jdbc.pool.DataSourceFactory.createDataSource(DataSourceFactory.java:554)
at org.apache.tomcat.jdbc.pool.DataSourceFactory.getObjectInstance(DataSourceFactory.java:242)
at org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:141)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:321)
at org.apache.naming.NamingContext.lookup(NamingContext.java:842)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.NamingContext.lookup(NamingContext.java:830)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.NamingContext.lookup(NamingContext.java:830)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.NamingContext.lookup(NamingContext.java:830)
at org.apache.naming.NamingContext.lookup(NamingContext.java:167)
at org.apache.catalina.core.NamingContextListener.addResource(NamingContextListener.java:1110)
at org.apache.catalina.core.NamingContextListener.createNamingContext(NamingContextListener.java:689)
at org.apache.catalina.core.NamingContextListener.lifecycleEvent(NamingContextListener.java:273)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5413)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1083)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1879)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NullPointerException
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:348)
at org.apache.tomcat.jdbc.pool.PooledConnection.connectUsingDriver(PooledConnection.java:246)
... 36 more
Aug 17, 2017 7:01:31 AM org.apache.naming.NamingContext lookup
WARNING: Unexpected exception resolving reference
java.sql.SQLException
at org.apache.tomcat.jdbc.pool.PooledConnection.connectUsingDriver(PooledConnection.java:254)
at org.apache.tomcat.jdbc.pool.PooledConnection.connect(PooledConnection.java:182)
at org.apache.tomcat.jdbc.pool.ConnectionPool.createConnection(ConnectionPool.java:701)
at org.apache.tomcat.jdbc.pool.ConnectionPool.borrowConnection(ConnectionPool.java:635)
at org.apache.tomcat.jdbc.pool.ConnectionPool.init(ConnectionPool.java:486)
at org.apache.tomcat.jdbc.pool.ConnectionPool.<init>(ConnectionPool.java:144)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.pCreatePool(DataSourceProxy.java:116)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.createPool(DataSourceProxy.java:103)
at org.apache.tomcat.jdbc.pool.DataSourceFactory.createDataSource(DataSourceFactory.java:554)
at org.apache.tomcat.jdbc.pool.DataSourceFactory.getObjectInstance(DataSourceFactory.java:242)
at org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:141)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:321)
at org.apache.naming.NamingContext.lookup(NamingContext.java:842)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.NamingContext.lookup(NamingContext.java:830)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.NamingContext.lookup(NamingContext.java:830)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.NamingContext.lookup(NamingContext.java:830)
at org.apache.naming.NamingContext.lookup(NamingContext.java:167)
at org.apache.catalina.core.NamingContextListener.addResource(NamingContextListener.java:1110)
at org.apache.catalina.core.NamingContextListener.createNamingContext(NamingContextListener.java:689)
at org.apache.catalina.core.NamingContextListener.lifecycleEvent(NamingContextListener.java:273)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5413)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1083)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1879)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NullPointerException
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:348)
at org.apache.tomcat.jdbc.pool.PooledConnection.connectUsingDriver(PooledConnection.java:246)
... 36 more
Aug 17, 2017 7:01:31 AM org.apache.catalina.core.NamingContextListener addResource
WARNING: Failed to register in JMX: javax.naming.NamingException
WARN 2017-08-17 07:01:32,986 (org.springframework.security.core.SpringSecurityCoreVersion.performVersionChecks:78) - **** You are advised to use Spring 4.3.4.RELEASE or later with this version. You are running: 4.3.2.RELEASE
INFO 2017-08-17 07:01:35,506 (com.serotonin.mango.MangoContextListener.contextInitialized:89) - Mango context starting
INFO 2017-08-17 07:01:38,144 (com.serotonin.mango.MangoContextListener.contextInitialized:138) - Mango context started
INFO 2017-08-17 07:01:38,405 (com.serotonin.mango.MangoContextListener.contextInitialized:141) - Cache point hierarchy initialized
INFO 2017-08-17 07:01:38,447 (com.serotonin.mango.MangoContextListener.contextInitialized:148) - Cache views hierarchy initialized
WARN 2017-08-17 07:01:46,356 (org.springframework.context.support.AbstractApplicationContext.refresh:549) - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'handshakeHandler' defined in org.scada_lts.web.ws.config.WebSocketConfig: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.web.socket.server.HandshakeHandler]: Factory method 'handshakeHandler' threw exception; nested exception is java.lang.IllegalStateException: No suitable default RequestUpgradeStrategy found
ERROR 2017-08-17 07:01:46,367 (org.springframework.web.servlet.FrameworkServlet.initServletBean:502) - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'handshakeHandler' defined in org.scada_lts.web.ws.config.WebSocketConfig: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.web.socket.server.HandshakeHandler]: Factory method 'handshakeHandler' threw exception; nested exception is java.lang.IllegalStateException: No suitable default RequestUpgradeStrategy found
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:599)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1123)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1018)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:510)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:776)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:861)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:541)
at org.springframework.web.servlet.FrameworkServlet.configureAndRefreshWebApplicationContext(FrameworkServlet.java:668)
at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:634)
at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:682)
at org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext(FrameworkServlet.java:553)
at org.springframework.web.servlet.FrameworkServlet.initServletBean(FrameworkServlet.java:494)
at org.springframework.web.servlet.HttpServletBean.init(HttpServletBean.java:136)
at javax.servlet.GenericServlet.init(GenericServlet.java:158)
at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1284)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1197)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1087)
at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5264)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5551)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1083)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1879)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.web.socket.server.HandshakeHandler]: Factory method 'handshakeHandler' threw exception; nested exception is java.lang.IllegalStateException: No suitable default RequestUpgradeStrategy found
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:189)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588)
... 34 more
Caused by: java.lang.IllegalStateException: No suitable default RequestUpgradeStrategy found
at org.springframework.web.socket.server.support.AbstractHandshakeHandler.initRequestUpgradeStrategy(AbstractHandshakeHandler.java:143)
at org.springframework.web.socket.server.support.AbstractHandshakeHandler.<init>(AbstractHandshakeHandler.java:109)
at org.springframework.web.socket.server.support.DefaultHandshakeHandler.<init>(DefaultHandshakeHandler.java:35)
at org.scada_lts.web.ws.config.ScadaHandshakeHandler.<init>(ScadaHandshakeHandler.java:19)
at org.scada_lts.web.ws.config.WebSocketConfig.handshakeHandler(WebSocketConfig.java:55)
at org.scada_lts.web.ws.config.WebSocketConfig$$EnhancerBySpringCGLIB$$7f30e4a1.CGLIB$handshakeHandler$0(<generated>)
at org.scada_lts.web.ws.config.WebSocketConfig$$EnhancerBySpringCGLIB$$7f30e4a1$$FastClassBySpringCGLIB$$9dac466d.invoke(<generated>)
at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)
at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:356)
at org.scada_lts.web.ws.config.WebSocketConfig$$EnhancerBySpringCGLIB$$7f30e4a1.handshakeHandler(<generated>)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162)
... 35 more
Aug 17, 2017 7:01:48 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deployment of web application archive /var/lib/tomcat7/webapps/ScadaBR.war has finished in 31,513 ms
Aug 17, 2017 7:01:48 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive /var/lib/tomcat7/webapps/ScadaLTS.war
Aug 17, 2017 7:01:49 AM org.apache.tomcat.jdbc.pool.ConnectionPool init
WARNING: maxIdle is larger than maxActive, setting maxIdle to: 80
Aug 17, 2017 7:01:49 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deployment of web application archive /var/lib/tomcat7/webapps/ScadaLTS.war has finished in 849 ms
Aug 17, 2017 7:01:49 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /var/lib/tomcat7/webapps/ROOT
Aug 17, 2017 7:01:49 AM org.apache.tomcat.jdbc.pool.ConnectionPool init
WARNING: maxIdle is larger than maxActive, setting maxIdle to: 80
Aug 17, 2017 7:01:50 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deployment of web application directory /var/lib/tomcat7/webapps/ROOT has finished in 767 ms
Aug 17, 2017 7:01:50 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Aug 17, 2017 7:01:50 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 33475 ms
我将 mysql-connetors 复制到 tomcat7 库:
sudo ln -s/var/lib/tomcat7/webapps/ScadaBR/WEB-INF/lib/mysql-connector-java-3.1.8-bin.jar/usr/share/tomcat7/lib/mysql-connector- java-3.1.8-bin.jar
sudo ln -s/var/lib/tomcat7/webapps/ScadaBR/WEB-INF/lib/mysql-connector-java-5.1.38-bin.jar/usr/share/tomcat7/lib/mysql-connector- java-5.1.38-bin.jar
sudo ln -s/var/lib/tomcat7/webapps/ScadaBR/WEB-INF/lib/mysql-connector-java-5.1.7-bin.jar/usr/share/tomcat7/lib/mysql-connector- java-5.1.7-bin.jar
所以我认为这不是问题,但我不知道是什么 - 有什么建议吗?
最佳答案
没关系。
可以通过几种方式配置 ScadaLTS 以连接数据库。
<强>1。直接连接数据库
在 ScadaLTS/WebContent/WEB-INF/env.properties 中配置
db.type=mysql
db.url=jdbc:mysql://localhost:3306/scadalts
db.username=xxxxx
db.password=xxxxx
db.pool.maxActive=10
db.pool.maxIdle=10
不需要附加到 tomcat mysql-connetor* 库。
<强>2。使用 JNDI 连接到数据库(默认)
在 ScadaLTS/WebContent/WEB-INF/env.properties 中配置
db.type=mysql
db.datasource=true
db.datasourceName=java:comp/env/jdbc/scadalts
#db.url=jdbc:mysql://localhost:3306/scadalts (commented for comparison)
#db.username=xxxxx (commented for comparison)
#db.password=xxxxx (commented for comparison)
#db.pool.maxActive=10 (commented for comparison)
#db.pool.maxIdle=10 (commented for comparison)
Tomcat的配置/tomcat/conf/context.xml
<?xml version="1.0" encoding="UTF-8"?>
<Context>
<WatchedResource>WEB-INF/web.xml</WatchedResource>
<Resource name="jdbc/scadalts"
auth="Container"
type="javax.sql.DataSource"
factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"
testWhileIdle="true"
testOnBorrow="true"
testOnReturn="false"
validationQuery="SELECT 1"
validationInterval="30000"
timeBetweenEvictionRunsMillis="30000"
maxActive="80"
minIdle="10"
maxWait="10000"
initialSize="10"
removeAbandonedTimeout="1000"
removeAbandoned="true"
abandonWhenPercentageFull="75"
logAbandoned="true"
minEvictableIdleTimeMillis="30000"
jmxEnabled="true"
jdbcInterceptors="org.apache.tomcat.jdbc.pool.interceptor.ConnectionState;
org.apache.tomcat.jdbc.pool.interceptor.StatementFinalizer;
org.apache.tomcat.jdbc.pool.interceptor.ResetAbandonedTimer;
org.apache.tomcat.jdbc.pool.interceptor.SlowQueryReport(threshold=1500)"
username="xxxxx"
password="xxxxx"
driverClassName="com.mysql.jdbc.Driver"
defaultTransactionIsolation="READ_COMMITTED"
url="jdbc:mysql://localhost:3306/scadalts"
/>
<!--
<Parameter name="javamelody.storage-directory" value="/var/log/tomcat7/javamelody" override="false"/>
-->
需要复制mysql-connector-*到tomcat/libs目录
More about JNDI Datasource HOW-TO
总而言之,你将 mysql-connector 复制到 tomcat/lib,这很好。
Configured system available in docker scadalts-dev
如果您仍然遇到连接问题,那么您正在检查:
在 ScadaLTS/WebContent/WEB-INF/env.properties 中配置
db.type=mysql
db.datasource=true
db.datasourceName=java:comp/env/jdbc/scadalts
Tomcat的配置/tomcat/conf/context.xml
<?xml version="1.0" encoding="UTF-8"?>
<Context>
...
username="xxxxx"
password="xxxxx"
driverClassName="com.mysql.jdbc.Driver"
...
url="jdbc:mysql://localhost:3306/scadalts"
/>
...
</Context>
关于mysql - ScadaLTS 在树莓派上运行 - tomcat7 ConnectionPool init,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45729160/
何时使用 init、带参数的 init 或 iOS 8 (Swift) 中的便利 init, Objective-C 中的 convenience init 等价于什么? 最佳答案 你的类将有一个必需
我正在阅读这个 First Search Program - Artificial Intelligence for Robotics 算法,我正在阅读它的 Python 代码。在这里,我们创建了一个
我觉得答案很明显,但我一直无法弄清楚,这对我来说似乎是一个反复出现的问题。基本上我想做这样的事情: extension NSData { convenience init(JSONObject
cloud-init 是在首次启动时在虚拟机上执行各种配置的包。您必须使用您的配置配置一个文件,然后将其扔到您的 VM 上,然后对其进行虚拟化。 但它究竟是如何工作的呢?用户数据如何发送到 VM,cl
我目前正在与 CoreOS 打交道,到目前为止,我认为我已经掌握了总体思路和概念。我还没有得到的一件事是执行 cloud-init . 我明白 cloud-init是一个为 CoreOS 做一些配置的
部署项目后,当客户端第一次向 TestServlet 发送请求时,服务器会创建 testServlet 对象,然后调用第一个 init() 方法(init(ServletConfig config))
是否有可能在 convenience init 中以某种方式解包可选 init? convenience init(...) { self.init?(...) ?? self.init() }
使用时 write_files使用 cloud-init,是否可以附加内容?如果是这样,如何? write_files: [ { "path": "/home/user/some-file
我对 Ansible 比较陌生,我创建了一个剧本,可以在“裸”服务器上安装 Tomcat 配置。我想知道如何解决能够更新 init.d 脚本的问题,同时避免在脚本没有更改时在剧本开始时停止服务。这是基
我打算在 iOS 中使用参数调用 init 方法中的默认 init 方法。像这样: -(id)init{ self = [super init]; if (self) {
Objective C 规范(来自 Apple)第 49 页指出每个声明实例变量的类都必须提供一个 init 方法来初始化它们 我的问题 -为什么这是必要的? NSObject 不会为实例初始化 iV
所以我有一个带有指定初始化器的类,它为每个存储的属性取值。我所有存储的属性也有一个默认值,所以我假设这个类有一个默认的初始化。 在我指定的 init 中,我调用 super.init() 问题是,如果
我对此有些困惑: class Person { var name: String var age: Int init(){ name = “Tim”
我有一个带有两个初始化方法的对象。其中一个接受 NSDictionary,另一个接受一大堆 String 变量。我想调用 NSDictionary init,然后从那里将我的字典转换为字符串,然后用我
我正在尝试为我的类创建一个方便的初始化:User。我之前为另一个类(class)做过这个,并且 - 再次创建它 - 我使用了相同的代码,只是我的用户类(class)有所不同。 这是我的用户类: imp
我已经通读了以下秘诀,它展示了一种使用 Google Cloud Endpoints 后端为 AngularJS 前端提供动力的方法: https://cloud.google.com/resourc
本文整理了Java中com.netflix.zuul.init.ZuulFiltersModule.()方法的一些代码示例,展示了ZuulFiltersModule.()的具体用法。这些代码示例主要来
我想实现一个 初始化 下功能 box.once() 在 Tarantool 中只执行一次,但是,只有在 时才对我有用初始化 已成功执行。 问题 : 如何使“onceinit”记录只有在 init 成功
如果在Xcode中创建新的游戏模板项目,则默认GameViewController将使用以下初始化程序实例化游戏场景: let scene = SKScene(fileNamed: "GameScen
我有一个 MKPolyline我要实现的 subblas NSCoding , IE。 @interface RSRoutePolyline : MKPolyline I asked a quest
我是一名优秀的程序员,十分优秀!