Skip to content

Commit 5712c01

Browse files
committed
2025.1 Code Drop
1 parent b439d94 commit 5712c01

30 files changed

+2714
-193
lines changed

.p4ignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ hs_err_pid*
1616
.project
1717

1818
target/
19+
build/
1920

2021
*.prefs
2122

LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2024, Perforce Software, Inc. All rights reserved.
1+
Copyright (c) 2025, Perforce Software, Inc. All rights reserved.
22

33

44
BY INSTALLING OR DOWNLOADING THE SOFTWARE, YOU ARE ACCEPTING AND AGREEING TO THE TERMS OF

RELEASE.md

Lines changed: 58 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
Release Notes for
2-
P4Java, the Perforce Java API
2+
P4Java, P4 API for Java
33

4-
Version 2024.2
4+
Version 2025.1
55

66
Introduction
77

8-
P4Java is a Java-native API for accessing Perforce SCM
8+
P4Java is a Java-native API for accessing P4 SCM
99
services from within Java applications, servlets, plugins,
1010
and other Java contexts.
1111

@@ -18,23 +18,37 @@ Introduction
1818

1919
Please send all feedback to support@perforce.com
2020

21+
--------------------------------------------------------------------------
22+
23+
Important Product Rebrand Notice
24+
25+
Helix Core is now P4
26+
Perforce has a new look and logo that reflects our place in DevOps
27+
workflows. As part of these changes, Helix Core is now P4. Name updates
28+
and new icons to align with the P4 branding will be rolled out soon.
29+
To learn more, see:
30+
https://www.perforce.com/blog/vcs/introducing-the-P4-platform
31+
32+
--------------------------------------------------------------------------
33+
2134
Requirements
2235

23-
* Perforce server at Release 2021.1 or higher.
36+
* This release of P4Java supports the 2025.1 P4 Server. Older releases
37+
might work but are not supported.
2438

2539
* Java: full standard JDK 11 or later. Implementation as
2640
discussed in "Known Limitations" below.
2741

2842
* SSL: unlimited strength JCE (Java Cryptography Extension) package for
29-
256-bit encryption level SSL connection to a secure Perforce server.
43+
256-bit encryption level SSL connection to a secure P4 server.
3044

3145
SSL and Trust
3246

33-
Perforce server 2021.1 or higher supports 256-bit SSL connections
47+
P4 server 2021.1 or higher supports 256-bit SSL connections
3448
and trust establishment via accepting the fingerprint of the SSL
3549
certificate's public key. The standard JDK comes with 128-bit
3650
encryption level ciphers. In order to use P4Java to connect to
37-
a secure Perforce server, you must download and install the
51+
a secure P4 server, you must download and install the
3852
unlimited strength JCE package for your JDK version.
3953

4054
To make a secure connection using P4Java, simply append 'ssl'
@@ -43,7 +57,7 @@ SSL and Trust
4357
trust using the IOptionsServer's 'addTrust' method. See example
4458
code snippet below:
4559

46-
// Create a P4Java SSL connection to a secure Perforce server
60+
// Create a P4Java SSL connection to a secure P4 server
4761
try {
4862
String serverUri = "p4javassl://perforce:1667";
4963
Properties props = null;
@@ -60,7 +74,7 @@ SSL and Trust
6074
}
6175

6276
P4Java 2020.1 has changed the default TLS support to TLSv1.2 for use
63-
with Perforce server 2019.1 or greater this can be modified using the
77+
with P4 server 2019.1 or greater this can be modified using the
6478
JVM option:
6579

6680
java -DsecureSocketEnabledProtocols=TLSv1.2
@@ -98,21 +112,21 @@ Known Limitations
98112
correctly on the platforms listed above under "Requirements".
99113

100114
* P4Java can not reliably be used in Unicode contexts where files
101-
have been added to a Perforce server as "shiftjis" when they are
115+
have been added to a P4 server as "shiftjis" when they are
102116
in fact CP932 (or MS932) encoded, and vice-versa. The usual
103117
symptoms of this problem include being unable to sync or submit
104118
affected files, with an error message that includes the string
105119
"Translation of file content failed". This is a known problem due
106120
to the inability to define a robust round-trip encoding / decoding
107121
between these encodings and the inaccurate use of "shiftjis" to
108-
mean either true shift-jis or CP932 by the Perforce server and
122+
mean either true shift-jis or CP932 by the P4 server and
109123
many Windows tools. There is currently no workaround known.
110124

111-
* The Perforce server (2021.1 or higher) only support 256-bit
125+
* The P4 server (2021.1 or higher) only support 256-bit
112126
encryption. Due to current US export control restrictions
113127
for some countries, the standard JDK package only comes with
114128
128-bit encryption level ciphers. In order to use P4Java to
115-
connect to a secure Perforce server, those living in eligible
129+
connect to a secure P4 server, those living in eligible
116130
countries may download the unlimited strength JCE (Java
117131
Cryptography Extension) version and replace the current
118132
default cryptography jar files with the unlimited strength
@@ -123,6 +137,30 @@ Known Limitations
123137
124138
* P4Java would not support file operations on altsync enabled clients.
125139

140+
-------------------------------------------
141+
Updates in 2025.1 (2025.1/2785811) (2025/06/24)
142+
143+
#2772096 (Job #125523)
144+
Added support of move match detection using multiple threads in
145+
"p4 move" command
146+
147+
#2770906 (Job #125805)
148+
Added support of move match detection using multiple threads in
149+
"p4 reconcile" command
150+
151+
#2766066 (Job #127060)
152+
Fixed a bug in p4 resolve -am to add network errors to the file path
153+
154+
#2764407 (Job #125107)
155+
Added support to --sync-time option
156+
157+
#2764369, #2764794 (Job #125781)
158+
Added support for P4D 2025.1
159+
160+
#2744711 (Job #125654)
161+
Fixed a bug in undoFile which always checks out files for delete regardless
162+
of the file's original file action
163+
126164
-------------------------------------------
127165
Updates in 2024.2 (2024.2/2695691) (2024/12/13)
128166

@@ -191,6 +229,13 @@ Updates in 2024.1 (2024.1/2612262) (2024/06/12)
191229
#2597531 (Job #112324)
192230
Fixed inconsistent handling of quotes in ViewMap for Label.
193231

232+
-------------------------------------------
233+
Updates in 2023.2 Patch 2 (2023.2/2746548) (2025/04/09)
234+
235+
#2743446 (Job #124765)
236+
Fixed behaviour of item being 0 bytes after detection of conflict when
237+
synced through proxy.
238+
194239
-------------------------------------------
195240
Updates in 2023.2 Patch 1 (2023.2/2581742) (2024/04/05)
196241

build.gradle

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ plugins {
22
id 'java-library'
33
id 'maven-publish'
44
id 'signing'
5-
}
5+
id "io.github.gradle-nexus.publish-plugin" version "2.0.0"
6+
}
67

78
group = 'com.perforce'
89
version = project.hasProperty('ver') ? project.ext.ver : 'PREP-TEST_ONLY'
@@ -89,22 +90,11 @@ publishing {
8990
}
9091

9192
repositories {
92-
def mavenUser = project.hasProperty('mavenUser') ? project.ext.mavenUser : ''
93-
def mavenPassword = project.hasProperty('mavenPassword') ? project.ext.mavenPassword : ''
9493
def artifactoryUser = project.hasProperty('artifactoryUser') ? project.ext.artifactoryUser : ''
9594
def artifactoryPassword = project.hasProperty('artifactoryPassword') ? project.ext.artifactoryPassword : ''
96-
def mavenStagingUrl = project.hasProperty('mavenStagingUrl') ? project.ext.mavenStagingUrl : ''
9795
def artifactorySnapshotUrl = project.hasProperty('artifactorySnapshotUrl') ? project.ext.artifactorySnapshotUrl : ''
9896
def artifactoryReleaseUrl = project.hasProperty('artifactoryReleaseUrl') ? project.ext.artifactoryReleaseUrl : ''
9997

100-
maven {
101-
name = 'p4mavencentral-staging'
102-
url = mavenStagingUrl
103-
credentials {
104-
username = mavenUser
105-
password = mavenPassword
106-
}
107-
}
10898
maven {
10999
name = 'artifactory-snapshots'
110100
url = artifactorySnapshotUrl
@@ -124,6 +114,19 @@ publishing {
124114
}
125115
}
126116

117+
nexusPublishing {
118+
def mavenUser = project.hasProperty('mavenUser') ? project.ext.mavenUser : ''
119+
def mavenPassword = project.hasProperty('mavenPassword') ? project.ext.mavenPassword : ''
120+
repositories {
121+
sonatype {
122+
nexusUrl = uri('https://ossrh-staging-api.central.sonatype.com/service/local/')
123+
snapshotRepositoryUrl = uri('https://central.sonatype.com/repository/maven-snapshots/')
124+
username = mavenUser
125+
password = mavenPassword
126+
}
127+
}
128+
}
129+
127130
java {
128131
withSourcesJar()
129132
withJavadocJar()

src/main/java/com/perforce/p4java/client/IClient.java

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1174,6 +1174,34 @@ public interface IClient extends IClientSummary, IWhereDelegator {
11741174
*/
11751175
List<IFileSpec> reconcileFiles(List<IFileSpec> fileSpecs, ReconcileFilesOptions opts) throws P4JavaException;
11761176

1177+
/**
1178+
* Open files for add, delete, and/or edit to reconcile client with workspace
1179+
* changes made outside of Perforce.
1180+
* <p>
1181+
* 'p4 reconcile' finds unopened files in a client's workspace and detects the
1182+
* following:
1183+
* <p>
1184+
* 1. files in depot missing from workspace, but still on have list.
1185+
* <p>
1186+
* 2. files on workspace that are not in depot.
1187+
* <p>
1188+
* 3. files modified in workpace that are not opened for edit.
1189+
* <p>
1190+
* By default, the files matching each condition above in the path are reconciled
1191+
* by opening files for delete (scenario 1), add (scenario 2), and/or edit (scenario 3).
1192+
* No file arguments are given here, hence, reconcile and status default to the current
1193+
* working directory.
1194+
*
1195+
* @param opts possibly-null ReconcileFilesOptions object specifying method options.
1196+
* @return a non-null but possibly-empty list of IFileSpec objects
1197+
* representing the opened files. Not all fields in these specs
1198+
* will be valid or set.
1199+
* @throws P4JavaException if an error occurs processing this method and its parameters
1200+
* @see com.perforce.p4java.option.client.ReconcileFilesOptions
1201+
* @since 2025.1
1202+
*/
1203+
List<IFileSpec> reconcileFiles(ReconcileFilesOptions opts) throws P4JavaException;
1204+
11771205
/**
11781206
* Open files for add, delete, and/or edit to reconcile client with workspace
11791207
* changes made outside of Perforce.

0 commit comments

Comments
 (0)