Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance Groovy classloader experience #4596

Merged
merged 22 commits into from
Oct 16, 2023
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
244332c
WIP
niloc132 Sep 20, 2023
f358b19
Existing tests and new ones pass checkpoint
niloc132 Sep 22, 2023
13a52ef
Test checkpoint
niloc132 Sep 22, 2023
b792d98
Formatted wip
niloc132 Sep 25, 2023
7829979
Merge branch 'main' into groovy-classloader
niloc132 Sep 29, 2023
6350a44
Comment out failing tests
niloc132 Sep 29, 2023
6430a18
Seems to be working now, need to finalize/cleanup/test
niloc132 Oct 3, 2023
20173c0
Separating groovy import configs fully
niloc132 Oct 4, 2023
1edebd9
Fix apparent whitespace change, add missing @after, revert changes
niloc132 Oct 4, 2023
d598e24
Revert changes meant for another branch
niloc132 Oct 4, 2023
6fd97cc
Merge branch 'main' into groovy-classloader
niloc132 Oct 4, 2023
97bebb4
Another extra newline?
niloc132 Oct 4, 2023
8c0ed1e
Update engine/table/src/main/java/io/deephaven/engine/util/GroovyDeep…
niloc132 Oct 5, 2023
f86dd36
Clean up test comments
niloc132 Oct 5, 2023
c92bcf9
review suggested renames, import cleanups
niloc132 Oct 5, 2023
763a887
Added tests for import aliasing
niloc132 Oct 5, 2023
bc670ba
Merge branch 'main' into groovy-classloader
niloc132 Oct 5, 2023
ac404fb
Restore ExecContext import, fix comments and whitespace
niloc132 Oct 5, 2023
625080d
Add a test to ensure imported groovy is available for formulas
niloc132 Oct 6, 2023
9a073f1
Review feedback
niloc132 Oct 12, 2023
12267fa
Merge branch 'main' into groovy-classloader
niloc132 Oct 12, 2023
7c9b700
remove console imports from being included in scripts
niloc132 Oct 16, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions engine/table/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ dependencies {
testImplementation project(':extensions-parquet-table')
testImplementation project(':extensions-source-support')
testImplementation project(':Numerics')
testImplementation project(':extensions-suanshu')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we still need this? thought it was deprecated

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added for test classpaths only, as an example used in DHE tests for groovy parameter disambiguation hit one of these methods.


Classpaths.inheritJUnitClassic(project, 'testImplementation')

Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
import static io.deephaven.function.Random.*;
import static io.deephaven.function.Sort.*;
import static io.deephaven.gui.color.Color.*;

import static io.deephaven.time.DateTimeUtils.*;
import static io.deephaven.time.calendar.StaticCalendarMethods.*;
import static io.deephaven.util.QueryConstants.*;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
import static io.deephaven.function.Random.*;
import static io.deephaven.function.Sort.*;
import static io.deephaven.gui.color.Color.*;

import static io.deephaven.time.DateTimeUtils.*;
import static io.deephaven.time.calendar.StaticCalendarMethods.*;
import static io.deephaven.util.QueryConstants.*;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import io.deephaven.engine.testutil.junit4.EngineCleanup;
import io.deephaven.util.SafeCloseable;
import org.jetbrains.annotations.NotNull;
import org.junit.After;
import org.junit.Before;
import org.junit.Rule;
import org.junit.Test;
Expand All @@ -31,7 +32,11 @@ public void setUp() {
.captureQueryScope()
.captureUpdateGraph()
.build().open();
}

@After
public void tearDown() {
executionContext.close();
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how we got away with not closing the exec context before, are we possibly just opening other context on top of it and never checking that none were leaked?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing is helpful to ensure that we are setting it before every test that needs it. It is otherwise not an error to not "close" an open execution at this time. Thanks for finding that it was missing here!

}

// @Test
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package io.deephaven.engine.util.scripts

println "Hello from script."
println "Hello 1 from script."
println "Hello 2 from script."
println "Hello 3 from script."
throw new RuntimeException("Busted")
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
package io.deephaven.engine.util.scripts

throw new RuntimeException("Busted Short")