mirror of
https://github.com/xerial/snappy-java.git
synced 2025-04-08 19:35:08 +02:00
#84: 1.0.5.3 release. Append UUID to the extracted lib file name
This commit is contained in:
parent
4e91ac909e
commit
89277ddb7a
2
pom.xml
2
pom.xml
@ -4,7 +4,7 @@
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.xerial.snappy</groupId>
|
||||
<artifactId>snappy-java</artifactId>
|
||||
<version>1.0.5.2</version>
|
||||
<version>1.0.5.3</version>
|
||||
<name>Snappy for Java</name>
|
||||
<description>snappy-java: A fast compression/decompression library</description>
|
||||
<packaging>bundle</packaging>
|
||||
|
@ -38,10 +38,7 @@ import java.security.DigestInputStream;
|
||||
import java.security.MessageDigest;
|
||||
import java.security.NoSuchAlgorithmException;
|
||||
import java.security.ProtectionDomain;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Enumeration;
|
||||
import java.util.List;
|
||||
import java.util.Properties;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* <b>Internal only - Do not use this class.</b> This class loads a native
|
||||
@ -366,8 +363,10 @@ public class SnappyLoader
|
||||
*/
|
||||
private static File extractLibraryFile(String libFolderForCurrentOS, String libraryFileName, String targetFolder) {
|
||||
String nativeLibraryFilePath = libFolderForCurrentOS + "/" + libraryFileName;
|
||||
final String prefix = "snappy-" + getVersion() + "-";
|
||||
String extractedLibFileName = prefix + libraryFileName;
|
||||
|
||||
// Attach UUID to the native library file to ensure multiple class loaders can read the libsnappy-java multiple times.
|
||||
String uuid = UUID.randomUUID().toString();
|
||||
String extractedLibFileName = String.format("snappy-%s-%s-%s", getVersion(), uuid, libraryFileName);
|
||||
File extractedLibFile = new File(targetFolder, extractedLibFileName);
|
||||
|
||||
try {
|
||||
|
Loading…
x
Reference in New Issue
Block a user