FlashDevelop 5.1 StackFrame Panel Triggers Internal Debugger Exception - actionscript-3

What setting/feature am I not configuring properly to have my StackFrame Panel back to a working state?
OS: Windows 10 64bit
IDE: FlashDevelop 5.1.1.1 for .NET 3.5 (32bit and 64bit behave the same)
Lang: ActionScript 3.0 SDK: Flex 4.6 + AIR
21.0 (Tried Several versions of each)
Player: Flash Player(SA) Debug ver 21.0
Java: JDK/JRE 7u80
Libs: AppWarp42.swc, AppWarpLibS2-1.0.8.swc, Assets.swc (Custom) and starling.swc(disabled)
Expected Behaviour:
Errors triggered during debugging pops up the StackFrame Panel with frame calls that can be clicked.
Actual Behaviour:
When starting the debugger(manually or autorun enabled) via FlashDevelop, everything is good until an error occurs. Instead of showing the stack trace, I get an Internal Debugger Error and anytime I attempt to set a previous StackFrame to the current frame, the same error retriggers:
Internal Error
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
flash.tools.debugger.NoResponseException: Timeout occurred while waiting for debugging response from Flash Player for 1000 milliseconds
************** Loaded Assemblies **************
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8689 (QFE.050727-8600)
CodeBase: file:///C:/Windows/Microsoft.NET/Framework64/v2.0.50727/mscorlib.dll
----------------------------------------
FlashDevelop
Assembly Version: 5.0.0.0
Win32 Version: 5.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/FlashDevelop64.exe
----------------------------------------
PluginCore
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/PluginCore.DLL
----------------------------------------
System.Windows.Forms
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8670 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8690 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Drawing
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8681 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System.Xml
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8679 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Core
Assembly Version: 3.5.0.0
Win32 Version: 3.5.30729.8693 built by: QFE
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Core/3.5.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
AirProperties
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/AirProperties.DLL
----------------------------------------
AS2Context
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/AS2Context.DLL
----------------------------------------
ASCompletion
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/ASCompletion.DLL
----------------------------------------
AS3Context
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/AS3Context.DLL
----------------------------------------
XMLCompletion
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/XMLCompletion.DLL
----------------------------------------
Aga
Assembly Version: 1.7.0.1
Win32 Version: 1.7.0.1
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Aga.DLL
----------------------------------------
ASClassWizard
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/ASClassWizard.DLL
----------------------------------------
BasicCompletion
Assembly Version: 1.0.0.18867
Win32 Version: 1.0.0.18867
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/BasicCompletion.DLL
----------------------------------------
BookmarkPanel
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/BookmarkPanel.DLL
----------------------------------------
BridgeSettings
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/BridgeSettings.DLL
----------------------------------------
CodeAnalyzer
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/CodeAnalyzer.DLL
----------------------------------------
CodeFormatter
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/CodeFormatter.DLL
----------------------------------------
Antlr3
Assembly Version: 3.1.3.42154
Win32 Version: 3.1.3.42154
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Antlr3.DLL
----------------------------------------
CodeRefactor
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/CodeRefactor.DLL
----------------------------------------
CssCompletion
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/CssCompletion.DLL
----------------------------------------
DataEncoder
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/DataEncoder.DLL
----------------------------------------
fdb.j4n
Assembly Version: 0.0.0.0
Win32 Version: 0.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/fdb.j4n.DLL
----------------------------------------
jni4net.n-0.8.8.0
Assembly Version: 0.8.8.0
Win32 Version: 0.8.8.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/jni4net.n-0.8.8.0.DLL
----------------------------------------
FileExplorer
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/FileExplorer.DLL
----------------------------------------
FlashConnect
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/FlashConnect.DLL
----------------------------------------
FlashDebugger
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/FlashDebugger.DLL
----------------------------------------
FlashLogViewer
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/FlashLogViewer.DLL
----------------------------------------
FlashViewer
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/FlashViewer.DLL
----------------------------------------
HaXeContext
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/HaXeContext.DLL
----------------------------------------
jni4net.n.w32.v20-0.8.8.0
Assembly Version: 0.8.8.0
Win32 Version: 0.8.8.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/jni4net.n.w32.v20-0.8.8.0.DLL
----------------------------------------
LayoutManager
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/LayoutManager.DLL
----------------------------------------
System.Design
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8670 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Design/2.0.0.0__b03f5f7f11d50a3a/System.Design.dll
----------------------------------------
LoomContext
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/LoomContext.DLL
----------------------------------------
ProjectManager
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/ProjectManager.DLL
----------------------------------------
MacroManager
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/MacroManager.DLL
----------------------------------------
OutputPanel
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/OutputPanel.DLL
----------------------------------------
PHPContext
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/PHPContext.DLL
----------------------------------------
SwfOp
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/SwfOp.DLL
----------------------------------------
System.Runtime.Remoting
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8670 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Runtime.Remoting/2.0.0.0__b77a5c561934e089/System.Runtime.Remoting.dll
----------------------------------------
ResultsPanel
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/ResultsPanel.DLL
----------------------------------------
SourceControl
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/SourceControl.DLL
----------------------------------------
StartPage
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/StartPage.DLL
----------------------------------------
System.Web
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8670 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_64/System.Web/2.0.0.0__b03f5f7f11d50a3a/System.Web.dll
----------------------------------------
TaskListPanel
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/TaskListPanel.DLL
----------------------------------------
WakaTime
Assembly Version: 1.1.0.0
Win32 Version: 1.1.0.0
CodeBase: file:///C:/Users/Jeramey/AppData/Local/FlashDevelop/Plugins/WakaTime.dll
----------------------------------------
System.Configuration
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8670 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
4y8lvnbq
Assembly Version: 1.0.0.0
Win32 Version: 2.0.50727.8690 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
qipjfbig
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8690 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
8brvfzkj
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8690 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Runtime.Serialization.Formatters.Soap
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.8670 (QFE.050727-8600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Runtime.Serialization.Formatters.Soap/2.0.0.0__b03f5f7f11d50a3a/System.Runtime.Serialization.Formatters.Soap.dll
----------------------------------------
net.sf.jni4net.jni.dynammic
Assembly Version: 0.0.0.0
Win32 Version: 0.8.8.0
CodeBase: file:///C:/Program%20Files%20(x86)/FlashDevelop/Plugins/jni4net.n-0.8.8.0.dll
----------------------------------------
************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.
For example:
<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>
When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.
I have tried the following corrective steps without any improvement:
Reset FlashDevelop(FD) Settings
Reinstalled FD
Rolled back FD to previous versions
Rolled back Flash Player to previous versions (12 was the farthest I went)
Rolled back Java JDK and JRE versions 7u79, 7u80, 8u91 and 8u92
Created new project (Different issues arise)
Set all apps that run to Administrative Access
Verified Network ports and port securities for apps
Looped through the last 20 revisions of project from SVN
Searched for the elusive "machine.config" file
I look forward to illuminating my blind spot, thanks all.

Related

Issue when connect .Net app inside a Docker container to remote Mysql Server

I have a Mysql database installed on a remote server(IP: 172.17.56.104)(Mysql not containerized). I also have a Selenium project to run test, when the test run, the test result is inserted to database. Everything is working. Now I containerize the Selenium project and run the test using docker-compose, it shows an timeout in connection to database, I guess the code inside the container cannot connect to the remote database. Hopefully somebody can give me a suggestion for this.
Dockerfile:
FROM mcr.microsoft.com/dotnet/runtime:6.0 AS base
WORKDIR /app
EXPOSE 4444
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
WORKDIR /src
COPY ["MyProject/MyProject.csproj", "MyProject/"]
RUN dotnet restore "MyProject/MyProject.csproj"
COPY . .
WORKDIR "/src/MyProject"
RUN dotnet build "MyProject.csproj" -c Release -o /app/build
ENV CONNECTION_STRING "server=172.17.56.104;Database=dbname;user id=dbusername;password=dbpassword;port=3306"
ENV RERUN_FAILED_COUNT "0"
FROM build AS Test
WORKDIR "/src/MyProject"
CMD ["dotnet", "test"]`
docker-compose.yml
version: "3"
services:
selenium:
image: selenium/hub
ports:
- 4442:4442
- 4443:4443
- 4444:4444
networks:
- docker_network
chrome:
image: selenium/node-chrome
shm_size: 2gb
depends_on:
- selenium
environment:
- SE_EVENT_BUS_HOST=selenium
- SE_EVENT_BUS_PUBLISH_PORT=4442
- SE_EVENT_BUS_SUBSCRIBE_PORT=4443
- SE_NODE_OVERRIDE_MAX_SESSIONS=true
- SE_NODE_MAX_SESSIONS=5
ports:
- 5901:5900
networks:
- docker_network
test:
image: mytest
depends_on:
- selenium
- chrome
ports:
- 4445:4444
volumes:
- ./Result:/src/Result
networks:
- docker_network
networks:
docker_network:
In test service, I use port mapping 4445:4444, I guess the traffic would go from the container port 4444 to the port 4445 on my PC and connect to the remote DB. I'm not sure this's correct or not.
When I run docker-compose up, it shows this exception
DBConnect:System.TimeoutException: Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.
test-1 | at MySql.Data.Common.StreamCreator.GetTcpStream(MySqlConnectionStringBuilder settings, MyNetworkStream& networkStream)
test-1 | at MySql.Data.Common.StreamCreator.GetStream(MySqlConnectionStringBuilder settings, MyNetworkStream& networkStream)
test-1 | at MySql.Data.MySqlClient.NativeDriver.Open()
test-1 | at MySql.Data.MySqlClient.Driver.Open()
test-1 | at MySql.Data.MySqlClient.Driver.Create(MySqlConnectionStringBuilder settings)
test-1 | at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnection()
test-1 | at MySql.Data.MySqlClient.MySqlPool.GetPooledConnection()
test-1 | at MySql.Data.MySqlClient.MySqlPool.TryToGetDriver()
test-1 | at MySql.Data.MySqlClient.MySqlPool.GetConnection()
test-1 | at MySql.Data.MySqlClient.MySqlConnection.Open()`
Try to ping some external address like 8.8.8.8 from inside your container, with terminal. If the ping is ok, then the problem is maybe on the side of mysql server. Some ports or something.
And check your docker_network settings, maybe you should use host network, but i don't think so.

docker container using mysql:5.7 take almost half of my RAM (16 Go)

I have a weird behavior with a docker image...
When I try to run mysql:5.7, the memory usage rise and fall... then stay up to half of my memory: 16Go
Demo:
https://asciinema.org/a/4siHwUlRrZPMlheJ9xgLu67Fi
Do you know why / how I could fix it?
I'm on a fresh setup.
$ docker info
Client:
Context: default
Debug Mode: false
Plugins:
buildx: Docker Buildx (Docker Inc., v0.8.2-docker)
compose: Docker Compose (Docker Inc., 2.6.0)
Server:
Containers: 0
Running: 0
Paused: 0
Stopped: 0
Images: 15
Server Version: 20.10.16
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: false
userxattr: false
Logging Driver: json-file
Cgroup Driver: systemd
Cgroup Version: 2
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: io.containerd.runc.v2 io.containerd.runtime.v1.linux runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 96df0994faabc1944fc614e52b0b3c6feb609a57.m
runc version:
init version: de40ad0
Security Options:
apparmor
seccomp
Profile: default
cgroupns
Kernel Version: 5.15.48-1-MANJARO
Operating System: Manjaro Linux
OSType: linux
Architecture: x86_64
CPUs: 12
Total Memory: 31.02GiB
Name: xps9570
ID: WVWN:YLQE:G4EQ:BJQM:4OFS:FJ7A:LL2A:G7AA:ITUJ:DN7B:OD6D:JYZE
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false

docker-compse.yml spring boot mysql configuration [duplicate]

This question already has an answer here:
Configuring Spring boot Docker and Mysql
(1 answer)
Closed 3 years ago.
I have been trying to configure docker for my spring boot application with MySQL. But, I keep getting communications link failure error after running
docker compose up
Here's a snapshot of the error
spring-batch_1 | 2019-11-14 06:23:43.713 INFO 1 --- [ main]
com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Starting...
spring-batch_1 | 2019-11-14 06:23:43.918 ERROR 1 --- [ main]
com.zaxxer.hikari.pool.HikariPool : HikariPool-1 - Exception during pool
initialization.
spring-batch_1 |
spring-batch_1 | com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link
failure
spring-batch_1 |
spring-batch_1 | The last packet sent successfully to the server was 0 milliseconds ago. The
driver has not received any packets from the server.
spring-batch_1 | at
com.mysql.cj.jdbc.exceptions.SQLError.createCommunicationsException(SQLError.java:174) ~[ .
mysql-connector-java-8.0.18.jar!/:8.0.18]
spring-batch_1 | at
com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException
(SQLExceptionsMapping.java:64 ) ~[mysql-connector-java-8.0.18.jar!/:8.0.18]
spring-batch_1 | at
com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:836) ~[mysql-connector-java-
8.0.18.jar!/:8.0.18]
spring-batch_1 | at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:456) ~
[mysql-connector-java-8.0.18.jar!/:8.0.18]
spring-batch_1 | at
com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:246) ~[mysql-connector-java-
8.0.18.jar!/:8.0.18]
spring-batch_1 | at
com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:199) ~[mysql-
connector-java-8.0.18.jar!/:8.0.18]
spring-batch_1 | at
com.zaxxer.hikari.util.DriverDataSource.getConnection(DriverDataSource.java:138) ~[HikariCP-
3.4.1.jar!/:na]
spring-batch_1 | at com.zaxxer.hikari.pool.PoolBase.newConnection(PoolBase.java:353) ~
[HikariCP-3.4.1.jar!/:na]
spring-batch_1 | at com.zaxxer.hikari.pool.PoolBase.newPoolEntry(PoolBase.java:201) ~
[HikariCP-3.4.1.jar!/:na]
spring-batch_1 | at
com.zaxxer.hikari.pool.HikariPool.createPoolEntry(HikariPool.java:473) ~[HikariCP-
3.4.1.jar!/:na]
spring-batch_1 | at
com.zaxxer.hikari.pool.HikariPool.checkFailFast(HikariPool.java:562) ~[HikariCP-
3.4.1.jar!/:na]
spring-batch_1 | at com.zaxxer.hikari.pool.HikariPool.<init>(HikariPool.java:115) ~ .
[HikariCP-3.4.1.jar!/:na]
spring-batch_1 | at
com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:112) ~[HikariCP-
3.4.1.jar!/:na]
spring-batch_1 | at
com.zaxxer.hikari.HikariDataSource$$FastClassBySpringCGLIB$$eeb1ae86.invoke(<generated>) ~ .
[HikariCP-3.4.1.jar!/:na]
spring-batch_1 | at
org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218) ~[spring-core-
5.2.1.RELEASE.jar!/:5.2.1.RELEASE]
spring-batch_1 | at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint
(CglibAopProxy.java:769) ~[spring-aop-5.2.1.RELEASE.jar!/:5.2.1.RELEASE]
spring-batch_1 | at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed
(ReflectiveMethodInvocation.java:163) ~[spring-aop-5.2.1.RELEASE.jar!/:5.2.1.RELEASE]
spring-batch_1 | at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed
(CglibAopProxy.java:747) ~[spring-aop-5.2.1.RELEASE.jar!/:5.2.1.RELEASE]
spring-batch_1 | at
org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed
(DelegatingIntroductionInterceptor.java:136) ~[spring-aop-5.2.1.RELEASE.jar!/:5.2.1.RELEASE]
Here's my docker-compose.yml file
version: "3.3"
services:
mysql:
restart: always
image: mysql:latest
ports:
- 6033:3306
expose:
- 6033
volumes:
- db_data:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=root#123
- MYSQL_DATABASE=micro_services
- MYSQL_USER=root
- MYSQL_PASSWORD=root#123
spring-batch:
restart: always
image: ioesandeep/product-service:0.0.1-SNAPSHOT
ports:
- "8082:8082"
environment:
SPRING_DATASOURCE_URL: jdbc:mysql://127.0.0.1:6033/micro_services
SPRING_DATASOURCE_USERNAME: root
SPRING_DATASOURCE_PASSWORD: root#123
SPRING_JPA_DATABASE: mysql
depends_on:
- mysql
volumes:
db_data: {}
and here's my dockerfile which is used to build my spring-batch image
FROM openjdk:11-jdk
VOLUME /tmp
ARG JAR_FILE
ADD ${JAR_FILE} product.jar
ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/product.jar"]
I am using dockerfile-maven-plugin from com.spotify to build the image.
Here's my application.properties file for the spring boot and hibernate
spring.application.name=product
server.port=8082
spring.jpa.hibernate.ddl-auto=create-drop
spring.datasource.url=jdbc:mysql://127.0.0.1:6033/micro_services
spring.datasource.username=root
spring.datasource.password=root#123
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
spring.jpa.database=mysql
spring.batch.initialize-schema=always
spring.batch.job.enabled=false
Docker version 18.09.2, build 6247962
mysql Ver 8.0.18 for macos10.14 on x86_64 (MySQL Community Server - GPL)
Images
mysql latest c8ee894bd2bd 4 weeks ago
openjdk 11-jdk a7e47afa852b 3 weeks ago
I have tried a lot many configurations for the docker-compose file but every time I get the same error. I am not sure what am I missing in the configuration. I have been trying to get this up for over 2 days now. I would really appreciate a quick help.
Thanks
You have your SPRING_DATASOURCE_URL as localhost (127.0.0.1):
SPRING_DATASOURCE_URL: jdbc:mysql://127.0.0.1:6033/micro_services
Which as far as your spring-batch container is concerned is itself NOT the host machine so it will not be able to connect.
You will need to change it to reference the mysql container like:
SPRING_DATASOURCE_URL: jdbc:mysql://mysql:6033/micro_services

Unable to link mysql docker container with spring boot application - Communications link failure

I am new to Docker. I am using Spring boot micro service. It's running well On my local machine. Now, I need to create a docker image for my application. It has a dependency on Mysql server. I am using docker-compose to create my containers. I am getting a communications link failure error while running my custom image (spring boot application). The Mysql image is running well independently.
My yml file :
version: '2'
services:
mysql-dev:
image: mysql:5.7
container_name: mysql-dev
environment:
MYSQL_ROOT_PASSWORD: "password"
MYSQL_DATABASE: "onlinetutorialspoint"
networks:
- my_mysql_net
ports:
- 3306:3308
spring_boot_db_service:
depends_on:
- mysql-dev
image: spring_boot_db_service
ports:
- 8181:8181
links:
- mysql-dev:mysql
networks:
- my_mysql_net
networks:
my_mysql_net:
driver: bridge
application properties file :
db.driver: com.mysql.jdbc.Driver
spring.datasource.url = jdbc:mysql://mysql-dev:3308/onlinetutorialspoint?useSSL=false
spring.datasource.username = root
spring.datasource.password = password
Full Error Message :
spring_boot_db_service_1 | 2019-01-28 13:34:06.955 INFO 1 --- [
main] org.hibernate.cfg.Environment : HHH000206:
hibernate.properties not found spring_boot_db_service_1 | 2019-01-28
13:34:07.000 INFO 1 --- [ main]
o.hibernate.annotations.common.Version : HCANN000001: Hibernate
Commons Annotations {5.0.1.Final} spring_boot_db_service_1 |
2019-01-28 13:34:08.430 WARN 1 --- [ main]
o.h.e.j.e.i.JdbcEnvironmentInitiator : HHH000342: Could not obtain
connection to query metadata : Communications link failure
spring_boot_db_service_1 | spring_boot_db_service_1 | The last
packet sent successfully to the server was 0 milliseconds ago. The
driver has not received any packets from the server.
spring_boot_db_service_1 | 2019-01-28 13:34:08.443 INFO 1 --- [
main] org.hibernate.dialect.Dialect : HHH000400: Using
dialect: org.hibernate.dialect.MySQL5Dialect spring_boot_db_service_1
| 2019-01-28 13:34:08.459 INFO 1 --- [ main]
o.h.e.j.e.i.LobCreatorBuilderImpl : HHH000422: Disabling
contextual LOB creation as connection was null
spring_boot_db_service_1 | 2019-01-28 13:34:08.921 WARN 1 --- [
main] ConfigServletWebServerApplicationContext : Exception encountered
during context initialization - cancelling refresh attempt:
org.springframework.beans.factory.UnsatisfiedDependencyException:
Error creating bean with name 'dbServiceImpl': Unsatisfied dependency
expressed through field 'dbServiceDao'; nested exception is
org.springframework.beans.factory.UnsatisfiedDependencyException:
Error creating bean with name 'dbServiceDaoImpl': Unsatisfied dependency expressed through field 'sessionFactory'; nested exception
is org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'sessionFactory' defined in class path
resource [com/htc/dbservice/configuration/DBConfiguration.class]:
Invocation of init method failed; nested exception is
org.hibernate.MappingException: Could not get constructor for
org.hibernate.persister.entity.SingleTableEntityPersister
spring_boot_db_service_1 | 2019-01-28 13:34:08.923 WARN 1 --- [
main] o.s.b.f.support.DisposableBeanAdapter : Invocation of destroy
method 'close' failed on bean with name 'eurekaRegistration':
org.springframework.beans.factory.BeanCreationNotAllowedException:
Error creating bean with name
'org.springframework.cloud.netflix.eureka.EurekaClientAutoConfiguration$RefreshableEurekaClientConfiguration':
Singleton bean creation not allowed while singletons of this factory
are in destruction (Do not request a bean from a BeanFactory in a
destroy method implementation!) spring_boot_db_service_1 | 2019-01-28
13:34:08.926 INFO 1 --- [ main]
o.apache.catalina.core.StandardService : Stopping service [Tomcat]
docker_spring_boot_db_service_1 exited with code 1
Did you change the default mysql port? if not, you are pointing to wrong port number.
When you map the port to pubilsh the service externally, the order is
<host-port>:<container-port>
services:
mysql-dev:
image: mysql:5.7
container_name: mysql-dev
environment:
MYSQL_ROOT_PASSWORD: "password"
MYSQL_DATABASE: "onlinetutorialspoint"
networks:
- my_mysql_net
ports:
- 3308:3306
And using docker-compose and connecting both services to the same network you can connect directly to the container without pubishing the mysql port to the external network.
Try to change your spring app pointing to mysql-dev:3306, or try to connect to the container spring_boot_db_service using
docker-compose exec spring_boot_db_service bash
and make a connectivity test to the database container.

Unable to start mysql with docker on Ubuntu 16.04

Am Unable to start mysql with docker on Ubuntu. Get the following error:
db_1_cc1214d5085c | ERROR: mysqld failed while attempting to check
config db_1_cc1214d5085c | command was: "mysqld --verbose --help"
db_1_cc1214d5085c | db_1_cc1214d5085c | mysqld: error while loading
shared libraries: libpthread.so.0: cannot stat shared object:
Permission denied
Content of docker compose file:
version: '2.4'
services:
db:
image: mysql:5.7
ports:
- "32000:3306"
environment:
MYSQL_ROOT_PASSWORD: root
# restart: always
volumes:
- ./data/db:/var/lib/mysql
Docker details:
Client:
Version: 18.09.0
API version: 1.39
Go version: go1.10.4
Git commit: 4d60db4
Built: Wed Nov 7 00:48:57 2018
OS/Arch: linux/amd64
Experimental: false
Server: Docker Engine - Community
Engine:
Version: 18.09.0
API version: 1.39 (minimum version 1.12)
Go version: go1.10.4
Git commit: 4d60db4
Built: Wed Nov 7 00:16:44 2018
OS/Arch: linux/amd64
Experimental: false
Also worth noting is that there is a non dockerized versionof MySQL installed and running on this server. Any help will be appreciated.
To start mysql service you'll need to have something like this in your docker-compose file
version: '3'
services:
<service-name>:
image: mysql:5.7
container_name: <container-name>
ports:
- "<host-port>:<container-port>"
environment:
- MYSQL_ROOT_PASSWORD=<root-password>
- MYSQL_DATABASE=<database-name>
volumes:
- <host-dir>:/var/lib/mysql
networks: ['stack']
networks:
stack:
driver: bridge
Make sure that <host-dir> you have permission with the current user executing the docker-compose up command.
The networks is used if you have multiple services that want to connect to the database they all should consume the same network which is stack in this example
looks like a permission problem on your host.