Release new version 5.0.4

This commit is contained in:
Grahame Grieve 2020-05-27 11:06:30 +10:00
parent c66bfec06b
commit 998d1e0afc
15 changed files with 57 additions and 50 deletions

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -540,43 +540,45 @@ public class PackageCacheManager {
NpmPackage pck = null;
String packRoot = Utilities.path(cacheFolder, id+"#"+v);
try {
Utilities.createDirectory(packRoot);
Utilities.clearDirectory(packRoot);
// ok, now we have a lock on it... check if something created it while we were waiting
if (!new File(packRoot).exists()) {
Utilities.createDirectory(packRoot);
Utilities.clearDirectory(packRoot);
int i = 0;
int c = 0;
int size = 0;
for (Entry<String, NpmPackageFolder> e : npm.getFolders().entrySet()) {
String dir = e.getKey().equals("package") ? Utilities.path(packRoot, "package") : Utilities.path(packRoot, "package", e.getKey());;
if (!(new File(dir).exists()))
Utilities.createDirectory(dir);
for (Entry<String, byte[]> fe : e.getValue().getContent().entrySet()) {
String fn = Utilities.path(dir, fe.getKey());
byte[] cnt = fe.getValue();
TextFile.bytesToFile(cnt, fn);
size = size + cnt.length;
i++;
if (progress && i % 50 == 0) {
c++;
System.out.print(".");
if (c == 120) {
System.out.println("");
System.out.print(" ");
c = 2;
}
}
int i = 0;
int c = 0;
int size = 0;
for (Entry<String, NpmPackageFolder> e : npm.getFolders().entrySet()) {
String dir = e.getKey().equals("package") ? Utilities.path(packRoot, "package") : Utilities.path(packRoot, "package", e.getKey());;
if (!(new File(dir).exists()))
Utilities.createDirectory(dir);
for (Entry<String, byte[]> fe : e.getValue().getContent().entrySet()) {
String fn = Utilities.path(dir, fe.getKey());
byte[] cnt = fe.getValue();
TextFile.bytesToFile(cnt, fn);
size = size + cnt.length;
i++;
if (progress && i % 50 == 0) {
c++;
System.out.print(".");
if (c == 120) {
System.out.println("");
System.out.print(" ");
c = 2;
}
}
}
}
IniFile ini = new IniFile(Utilities.path(cacheFolder, "packages.ini"));
ini.setTimeStampFormat("yyyyMMddhhmmss");
ini.setTimestampProperty("packages", id+"#"+v, Timestamp.from(Instant.now()), null);
ini.setIntegerProperty("package-sizes", id+"#"+v, size, null);
ini.save();
if (progress)
System.out.println(" done.");
}
IniFile ini = new IniFile(Utilities.path(cacheFolder, "packages.ini"));
ini.setTimeStampFormat("yyyyMMddhhmmss");
ini.setTimestampProperty("packages", id+"#"+v, Timestamp.from(Instant.now()), null);
ini.setIntegerProperty("package-sizes", id+"#"+v, size, null);
ini.save();
if (progress)
System.out.println(" done.");
pck = loadPackageInfo(packRoot);
if (!id.equals(JSONUtil.str(npm.getNpm(), "name")) || !v.equals(JSONUtil.str(npm.getNpm(), "version"))) {
if (!id.equals(JSONUtil.str(npm.getNpm(), "name"))) {

View File

@ -18,7 +18,7 @@ public class PackageCacheTests {
PackageCacheManager cache = new PackageCacheManager(true, ToolsVersion.TOOLS_VERSION);
cache.clear();
Assertions.assertTrue(cache.listPackages().isEmpty());
NpmPackage npm = cache.loadPackage("hl7.fhir.pubpack", "0.0.5");
NpmPackage npm = cache.loadPackage("hl7.fhir.pubpack", "0.0.3");
npm.loadAllFiles();
Assertions.assertNotNull(npm);
File dir = new File(Utilities.path("[tmp]", "cache"));

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.core</artifactId>
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

View File

@ -13,7 +13,7 @@
each other. It is fine to bump the point version of this POM without affecting
HAPI FHIR.
-->
<version>5.0.3-SNAPSHOT</version>
<version>5.0.4-SNAPSHOT</version>
<properties>
<hapi_fhir_version>5.0.0</hapi_fhir_version>

View File

@ -6,6 +6,11 @@ title: FHIR Validator Release Notes
## Current (not released yet)
(no changes yet)
## v5.0.4 (2020-05-27)
(no changes yet)
## v5.0.3 (2020-05-26)
@ -199,4 +204,4 @@ title: FHIR Validator Release Notes
## v4.1.60 (2020-02-02)
* This
* This

View File

@ -1,7 +1,7 @@
@echo off
set oldver=5.0.2
set newver=5.0.3
set oldver=5.0.3
set newver=5.0.4
echo ..
echo =========================================================================
@ -15,7 +15,7 @@ call "C:\tools\fnr.exe" -dir "C:\work\org.hl7.fhir\build" -fileMask "*.xml" -fin
call "C:\tools\fnr.exe" -dir "C:\work\org.hl7.fhir\fhir-ig-publisher" -fileMask "*.xml" -find "%oldver%-SNAPSHOT" -replace "%newver%-SNAPSHOT" -count 2
call "C:\tools\fnr.exe" -dir "C:\work\org.hl7.fhir\latest-ig-publisher" -fileMask "*.html" -find "%oldver%" -replace "%newver%" -count 1
call "C:\tools\fnr.exe" -dir "C:\work\org.hl7.fhir\latest-ig-publisher" -fileMask "*.json" -find "%oldver%" -replace "%newver%" -count 1
call mvn clean deploy -Dmaven.test.redirectTestOutputToFile=false -DdeployAtEnd=true
rem call mvn clean deploy -Dmaven.test.redirectTestOutputToFile=false -DdeployAtEnd=true
IF %ERRORLEVEL% NEQ 0 (
GOTO DONE
)