question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NoClassDefFoundError: joda...

See original GitHub issue

Description

On mvn docker:run, tasks succeed, but output is:

# using d-m-p 1.17.1
Exception in thread "Thread-1" java.lang.NoClassDefFoundError: org/joda/time/format/ISODateTimeFormat$Constants
        at org.joda.time.format.ISODateTimeFormat.dateTime(ISODateTimeFormat.java:773)
        at io.fabric8.maven.docker.util.Timestamp.<init>(Timestamp.java:60)
# using d-m-p 1.19.1
Exception in thread "Thread-1" java.lang.NoClassDefFoundError: org/joda/time/format/DateTimeFormatterBuilder$Fraction
        at org.joda.time.format.DateTimeFormatterBuilder.appendFraction(DateTimeFormatterBuilder.java:579)

As my container is started, this might only happen when there is a problem with starting the given container.

Info

  • d-m-p version : 1.19.1 (also 1.17.1)
  • Maven version (mvn -v) : 3.3.9
  • Docker version : 1.12.5
<plugin>
				<groupId>io.fabric8</groupId>
				<artifactId>docker-maven-plugin</artifactId>
				<configuration>
					<verbose>true</verbose>
					<showLogs>true</showLogs>
					<images>
						<image>
							<name>%g/attributesetdb</name>
							<alias>attributesetdb</alias>
							<build>
<dockerFileDir>${project.basedir}/dockerfiles/mysql</dockerFileDir>
							</build>
							<run>
								<ports>
									<port>13306:3306</port>
									<port>20023:22</port>
								</ports>
							</run>
						</image>
					</images>
				</configuration>
			</plugin>

Dockerfile:

FROM mysql:5.7

Note that This docker definition is probably invalid, I am in the process of debugging it. This issue though is not about the failure to start a container, but about the joda-time exception.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
llorllalecommented, Nov 3, 2017

Had this same issue. The build consistently failed with NoClassDefFoundError with some class from joda-time, although the exact class in question would vary. Solved it by deleting the cached copy from my .m2 and running the build again (thereby prompting maven to download it again).

0reactions
jakaarlcommented, Oct 21, 2019

Removing the log from my wait does make the stack trace disappear.

Read more comments on GitHub >

github_iconTop Results From Across the Web

java.lang.NoClassDefFoundError: org/joda/time/Chronology
NoClassDefFoundError : org/joda/time/Chronology ... This seems strange, considering that I have downloaded the latest joda time jar file from ...
Read more >
[hibernate-validator] NoClassDefFoundError: org/joda/time ...
Original exception that caused the problem: java.lang.NoClassDefFoundError: org/joda/time/ReadableInstant at sun.misc.Unsafe.
Read more >
java.lang.NoClassDefFoundError: org/joda/time/DateTimeZone
My Oracle Support Banner. CSDT Developer Tools Command Fails: java.lang.NoClassDefFoundError: org/joda/time/DateTimeZone (Doc ID 2870672.1).
Read more >
[build:3161] java.lang.NoClassDefFoundError : org/joda/time ...
NoClassDefFoundError : org/joda/time/ReadablePeriod: org/joda/time/ReadablePeriod. I used datetime expression 'now#shortDate' in node factory in actions ...
Read more >
org.joda.time Class Hierarchy (Joda-Time 2.12.1 API) - Joda.org
Hierarchy For Package org.joda.time. Package Hierarchies: All Packages. Class Hierarchy. java.lang.Object.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found