Skip to content

Commit

Permalink
Merge branch 'main' into sm-pq-metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
malhotrashivam committed Mar 15, 2024
2 parents a529fc2 + 1c8c11f commit 48906dd
Show file tree
Hide file tree
Showing 8,553 changed files with 74,115 additions and 50,319 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
4 changes: 2 additions & 2 deletions .github/workflows/create-docs-issues.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = async ({ github, context }) => {
const ISSUE_REPO_NAME = "deephaven.io";
const ISSUE_REPO_NAME = "deephaven-docs-community";
const ISSUE_TYPES = ["Community"];

const body =
Expand All @@ -15,7 +15,7 @@ module.exports = async ({ github, context }) => {
repo: ISSUE_REPO_NAME,
title: `${context.payload.pull_request.title}`,
body,
labels: [type, "documentation", "triage", "autogenerated"],
labels: ["triage", "autogenerated"],
})
);

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,5 +113,5 @@ jobs:
if: ${{ startsWith(github.ref, 'refs/heads/release/v') }}
env:
NODE_AUTH_TOKEN: ${{ secrets.DEEPHAVENBOT_NPM_TOKEN }}
run: npm publish --tag latest web/client-api/types/build/deephaven-jsapi-types-*.tgz
run: npm publish --provenance --tag latest web/client-api/types/build/deephaven-jsapi-types-*.tgz
continue-on-error: true
10 changes: 1 addition & 9 deletions Base/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ sourceSets {

// TODO (core#116): Gradle test fixtures
task jarTests(type: Jar, dependsOn: testClasses) {
classifier = 'tests'
archiveClassifier = 'tests'
from sourceSets.test.output
}
configurations {
Expand All @@ -44,11 +44,3 @@ configurations {
artifacts {
tests jarTests
}

spotless {
java {
targetExclude(
'**/ringbuffer/Aggregating*RingBuffer*.java'
)
}
}
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/ArrayUtil.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import io.deephaven.base.verify.Require;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/AtomicUtil.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import java.util.concurrent.atomic.AtomicInteger;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Base64.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

/* copied from java.util.prefs; but allow the class to be public */
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/ClampUtil.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

public class ClampUtil {
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/ClassUtil.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import org.apache.commons.lang3.ClassUtils;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/CompareUtils.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

public class CompareUtils {
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Copyable.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

public interface Copyable<T> extends SafeCloneable<T> {
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Encodeable.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import java.io.DataInput;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/FIFOMutex.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import java.util.concurrent.atomic.AtomicReference;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/FIFOSemaphore.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import io.deephaven.base.verify.Assert;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Factory.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

public interface Factory<T> {
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/FatalErrorHandler.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

public interface FatalErrorHandlerFactory {
Expand Down
77 changes: 74 additions & 3 deletions Base/src/main/java/io/deephaven/base/FileUtils.java
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import io.deephaven.base.verify.Assert;
import io.deephaven.base.verify.Require;
import org.jetbrains.annotations.Nullable;

import java.io.*;
import java.net.URI;
import java.net.URISyntaxException;
import java.nio.file.Path;
import java.util.ArrayList;

public class FileUtils {
Expand Down Expand Up @@ -249,4 +252,72 @@ public boolean accept(File pathname) {
|| (pathname.isFile() && (normalFileFilter == null || normalFileFilter.accept(pathname)));
}
}

/**
* Take the file source path or URI string and convert it to a URI object.
*
* @param source The file source path or URI
* @param isDirectory Whether the source is a directory
* @return The URI object
*/
public static URI convertToURI(final String source, final boolean isDirectory) {
if (source.isEmpty()) {
throw new IllegalArgumentException("Cannot convert empty source to URI");
}
final URI uri;
try {
uri = new URI(source);
} catch (final URISyntaxException e) {
// If the URI is invalid, assume it's a file path
return convertToURI(new File(source), isDirectory);
}
if (uri.getScheme() == null) {
// Convert to a "file" URI
return convertToURI(new File(source), isDirectory);
}
return uri;
}

/**
* Takes a file and convert it to a URI object with {@code "file"} scheme. This method is preferred instead of
* {@link File#toURI()} because {@link File#toURI()} internally calls {@link File#isDirectory()}, which typically
* invokes the {@code stat} system call, resulting in filesystem metadata access.
*
* @param file The file
* @param isDirectory Whether the source file is a directory
* @return The URI object
*/
public static URI convertToURI(final File file, final boolean isDirectory) {
String absPath = file.getAbsolutePath();
if (File.separatorChar != '/') {
absPath = absPath.replace(File.separatorChar, '/');
}
if (absPath.charAt(0) != '/') {
absPath = "/" + absPath;
}
if (isDirectory && absPath.charAt(absPath.length() - 1) != '/') {
absPath = absPath + "/";
}
if (absPath.startsWith("//")) {
absPath = "//" + absPath;
}
try {
return new URI("file", null, absPath, null);
} catch (final URISyntaxException e) {
throw new IllegalStateException("Failed to convert file to URI: " + file, e);
}
}

/**
* Takes a path and convert it to a URI object with {@code "file"} scheme. This method is preferred instead of
* {@link Path#toUri()} because {@link Path#toUri()} internally invokes the {@code stat} system call, resulting in
* filesystem metadata access.
*
* @param path The path
* @param isDirectory Whether the file is a directory
* @return The URI object
*/
public static URI convertToURI(final Path path, final boolean isDirectory) {
return convertToURI(path.toFile(), isDirectory);
}
}
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Lazy.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import java.util.function.Supplier;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/LockFreeArrayQueue.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import io.deephaven.base.queue.ConcurrentQueue;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import io.deephaven.base.verify.Assert;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/LowGarbageArrayList.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import io.deephaven.base.verify.Assert;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/LowGarbageArraySet.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import java.util.AbstractSet;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/MathUtil.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

/**
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Pair.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import org.jetbrains.annotations.NotNull;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Predicate.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

public class Predicate {
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/RAPriQueue.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import java.util.Arrays;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/Reference.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

// --------------------------------------------------------------------
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/RingBuffer.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

import java.util.Arrays;
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/SafeCloneable.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

/**
Expand Down
6 changes: 3 additions & 3 deletions Base/src/main/java/io/deephaven/base/SleepUtil.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Copyright (c) 2016-2022 Deephaven Data Labs and Patent Pending
*/
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.base;

public class SleepUtil {
Expand Down
Loading

0 comments on commit 48906dd

Please sign in to comment.