Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion oak-examples/standalone/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@
<version>1.0.2</version>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
<version>${groovy.version}</version>
</dependency>
Expand Down
2 changes: 1 addition & 1 deletion oak-examples/webapp/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
<version>1.0.2</version>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
<version>${groovy.version}</version>
</dependency>
Expand Down
4 changes: 2 additions & 2 deletions oak-parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
<testcontainers.version>2.0.5</testcontainers.version>
<pax-exam.version>4.14.0</pax-exam.version>
<pax-url.version>2.6.17</pax-url.version>
<groovy.version>3.0.25</groovy.version>
<groovy.version>4.0.33</groovy.version>
<netty.version>4.1.136.Final</netty.version>
<aws.sdk.version>2.36.3</aws.sdk.version>
<!-- determines the bytecode version (i.e. the minimum JRE required to run the build artifact) -->
Expand Down Expand Up @@ -240,7 +240,7 @@
<plugin>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<version>3.0.2</version>
<version>4.3.1</version>
</plugin>
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
Expand Down
15 changes: 6 additions & 9 deletions oak-run/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
<jetty.version>9.4.53.v20231009</jetty.version>
<!--
Size History:
+ 4 MB (Groovy 3.0.25 -> 4.0.33, OAK-12355)
+ 88 MB (Ben-manes Caffeine, OAK-12148)
+ 87 MB (Aws Sdk 2.x, OAK-11935)
+ 84 MB (RDB/Tomcat, OAK-10752)
Expand All @@ -53,7 +54,7 @@
+ 41 MB build failing on the release profile (OAK-6250)
+ 38 MB. Initial value. Current 35MB plus a 10%
-->
<max.jar.size>92274688</max.jar.size>
<max.jar.size>96274688</max.jar.size>
</properties>

<build>
Expand Down Expand Up @@ -273,28 +274,24 @@
<artifactId>jopt-simple</artifactId>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
<version>${groovy.version}</version>
<classifier>indy</classifier>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-json</artifactId>
<version>${groovy.version}</version>
<classifier>indy</classifier>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-cli-picocli</artifactId>
<version>${groovy.version}</version>
<classifier>indy</classifier>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-groovysh</artifactId>
<version>${groovy.version}</version>
<classifier>indy</classifier>
</dependency>
<dependency>
<groupId>org.mongodb</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,21 +23,51 @@ import groovy.transform.TypeCheckingMode
import jline.Terminal
import jline.TerminalFactory
import jline.console.history.FileHistory
import org.apache.jackrabbit.oak.console.commands.CdCommand
import org.apache.jackrabbit.oak.console.commands.CheckpointCommand
import org.apache.jackrabbit.oak.console.commands.ExportCommand
import org.apache.jackrabbit.oak.console.commands.ExportRelevantDocumentsCommand
import org.apache.jackrabbit.oak.console.commands.LsCommand
import org.apache.jackrabbit.oak.console.commands.LsdDocumentCommand
import org.apache.jackrabbit.oak.console.commands.LuceneCommand
import org.apache.jackrabbit.oak.console.commands.OakHelpCommand
import org.apache.jackrabbit.oak.console.commands.PnCommand
import org.apache.jackrabbit.oak.console.commands.PrintDocumentCommand
import org.apache.jackrabbit.oak.console.commands.RefreshCommand
import org.apache.jackrabbit.oak.console.commands.RetrieveCommand
import org.apache.jackrabbit.oak.run.commons.Utils
import org.apache.jackrabbit.oak.console.commands.*
import org.apache.jackrabbit.oak.plugins.document.DocumentNodeStore
import org.apache.groovy.groovysh.AnsiDetector
import org.apache.groovy.groovysh.ExitNotification
import org.apache.groovy.groovysh.Groovysh
import org.apache.groovy.groovysh.InteractiveShellRunner
import org.apache.groovy.groovysh.Command as ShellCommand
import org.apache.groovy.groovysh.commands.AliasCommand
import org.apache.groovy.groovysh.commands.ClearCommand
import org.apache.groovy.groovysh.commands.DisplayCommand
import org.apache.groovy.groovysh.commands.DocCommand
import org.apache.groovy.groovysh.commands.EditCommand
import org.apache.groovy.groovysh.commands.ExitCommand
import org.apache.groovy.groovysh.commands.HistoryCommand
import org.apache.groovy.groovysh.commands.ImportCommand
import org.apache.groovy.groovysh.commands.InspectCommand
import org.apache.groovy.groovysh.commands.LoadCommand
import org.apache.groovy.groovysh.commands.PurgeCommand
import org.apache.groovy.groovysh.commands.RecordCommand
import org.apache.groovy.groovysh.commands.RegisterCommand
import org.apache.groovy.groovysh.commands.SaveCommand
import org.apache.groovy.groovysh.commands.SetCommand
import org.apache.groovy.groovysh.commands.ShowCommand
import org.codehaus.groovy.runtime.StackTraceUtils
import org.codehaus.groovy.tools.shell.*
import org.codehaus.groovy.tools.shell.Command as ShellCommand
import org.codehaus.groovy.tools.shell.commands.*
import org.codehaus.groovy.tools.shell.util.Logger
import org.codehaus.groovy.tools.shell.IO
import org.codehaus.groovy.tools.shell.util.Preferences
import org.fusesource.jansi.Ansi
import org.fusesource.jansi.AnsiConsole
import org.fusesource.jansi.AnsiRenderer

/**
* Some part of logic is based on usage in org.codehaus.groovy.tools.shell.Main
* Some part of logic is based on usage in org.apache.groovy.tools.shell.Main
*/
@CompileStatic
class GroovyConsole {
Expand Down Expand Up @@ -175,7 +205,7 @@ class GroovyConsole {
throw new IllegalStateException("Error hook is not set")
}
if (cause instanceof MissingPropertyException) {
if (cause.type && cause.type.canonicalName == Interpreter.SCRIPT_FILENAME) {
if (cause.type && cause.type.canonicalName == "groovysh_evaluate") {
io.err.println("@|bold,red Unknown property|@: " + cause.property)
return
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ import jline.console.completer.Completer
import org.apache.jackrabbit.oak.commons.PathUtils
import org.apache.jackrabbit.oak.commons.collections.IterableUtils
import org.apache.jackrabbit.oak.console.ConsoleSession
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.codehaus.groovy.tools.shell.util.SimpleCompletor
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh
import org.apache.groovy.groovysh.util.SimpleCompleter

class CdCommand extends CommandSupport{
public static final String COMMAND_NAME = 'change-dir'
Expand All @@ -35,7 +35,7 @@ class CdCommand extends CommandSupport{

@Override
protected List<Completer> createCompleters() {
SimpleCompletor completor = new SimpleCompletor(){
SimpleCompleter completor = new SimpleCompleter(){
@Override
SortedSet getCandidates() {
SortedSet<String> names = new TreeSet<String>()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ package org.apache.jackrabbit.oak.console.commands

import groovy.transform.CompileStatic
import org.apache.jackrabbit.oak.console.ConsoleSession
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh

import java.util.concurrent.TimeUnit

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ package org.apache.jackrabbit.oak.console.commands
import org.apache.jackrabbit.oak.commons.PathUtils
import org.apache.jackrabbit.oak.console.ConsoleSession
import org.apache.jackrabbit.oak.exporter.NodeStateSerializer
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh
import groovy.cli.picocli.CliBuilder

class ExportCommand extends CommandSupport{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ import org.apache.jackrabbit.oak.plugins.document.DocumentNodeStore
import org.apache.jackrabbit.oak.plugins.document.DocumentStore
import org.apache.jackrabbit.oak.plugins.document.NodeDocument
import org.apache.jackrabbit.oak.plugins.document.util.Utils
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh
import groovy.cli.picocli.CliBuilder

class ExportRelevantDocumentsCommand extends CommandSupport {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ package org.apache.jackrabbit.oak.console.commands
import groovy.transform.CompileStatic
import org.apache.jackrabbit.oak.commons.collections.IterableUtils
import org.apache.jackrabbit.oak.console.ConsoleSession
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh

@CompileStatic
class LsCommand extends CommandSupport{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ import org.apache.jackrabbit.oak.plugins.document.DocumentNodeStore
import org.apache.jackrabbit.oak.plugins.document.NodeDocument
import org.apache.jackrabbit.oak.plugins.document.Path
import org.apache.jackrabbit.oak.plugins.document.util.Utils
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh

import static org.apache.jackrabbit.oak.plugins.document.Collection.NODES

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ import org.apache.lucene.index.DirectoryReader
import org.apache.lucene.store.Directory
import org.apache.lucene.store.FSDirectory
import org.apache.lucene.store.IOContext
import org.codehaus.groovy.tools.shell.ComplexCommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.ComplexCommandSupport
import org.apache.groovy.groovysh.Groovysh
import org.apache.jackrabbit.oak.spi.state.NodeBuilder as OakNodeBuilder


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@
*/
package org.apache.jackrabbit.oak.console.commands

import org.codehaus.groovy.tools.shell.Command
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.codehaus.groovy.tools.shell.completion.CommandNameCompleter
import org.apache.groovy.groovysh.Command
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh
import org.apache.groovy.groovysh.completion.CommandNameCompleter

/**
* Copy of org.codehaus.groovy.tools.shell.commands.HelpCommand to customize
* Copy of org.apache.groovy.tools.shell.commands.HelpCommand to customize
* the banner
*/
class OakHelpCommand extends CommandSupport{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ package org.apache.jackrabbit.oak.console.commands
import groovy.transform.CompileStatic
import org.apache.jackrabbit.oak.console.ConsoleSession
import org.apache.jackrabbit.oak.nodestate.NodeStateHelper
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh

@CompileStatic
class PnCommand extends CommandSupport{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ import org.apache.jackrabbit.oak.console.ConsoleSession
import org.apache.jackrabbit.oak.plugins.document.DocumentNodeStore
import org.apache.jackrabbit.oak.plugins.document.NodeDocument
import org.apache.jackrabbit.oak.plugins.document.util.Utils
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh
import org.json.simple.JSONObject
import org.json.simple.JSONValue

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ package org.apache.jackrabbit.oak.console.commands

import groovy.transform.CompileStatic
import org.apache.jackrabbit.oak.console.ConsoleSession
import org.codehaus.groovy.tools.shell.ComplexCommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.ComplexCommandSupport
import org.apache.groovy.groovysh.Groovysh

@CompileStatic
class RefreshCommand extends ComplexCommandSupport{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ package org.apache.jackrabbit.oak.console.commands

import groovy.transform.CompileStatic
import org.apache.jackrabbit.oak.console.ConsoleSession
import org.codehaus.groovy.tools.shell.CommandSupport
import org.codehaus.groovy.tools.shell.Groovysh
import org.apache.groovy.groovysh.CommandSupport
import org.apache.groovy.groovysh.Groovysh

@CompileStatic
class RetrieveCommand extends CommandSupport{
Expand Down
Loading