Skip to content

Commit

Permalink
Deprecated grant method in Java API. (#335)
Browse files Browse the repository at this point in the history
* Deprecated grant method in Java API.

* PubNub SDK v10.4.2 release.

---------

Co-authored-by: PubNub Release Bot <120067856+pubnub-release-bot@users.noreply.github.com>
  • Loading branch information
marcin-cebo and pubnub-release-bot authored Feb 25, 2025
1 parent 3b7aa64 commit f3ecdda
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 7 deletions.
13 changes: 9 additions & 4 deletions .pubnub.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: kotlin
version: 10.4.1
version: 10.4.2
schema: 1
scm: github.com/pubnub/kotlin
files:
- build/libs/pubnub-kotlin-10.4.1-all.jar
- build/libs/pubnub-kotlin-10.4.2-all.jar
sdks:
-
type: library
Expand All @@ -23,8 +23,8 @@ sdks:
-
distribution-type: library
distribution-repository: maven
package-name: pubnub-kotlin-10.4.1
location: https://repo.maven.apache.org/maven2/com/pubnub/pubnub-kotlin/10.4.1/pubnub-kotlin-10.4.1.jar
package-name: pubnub-kotlin-10.4.2
location: https://repo.maven.apache.org/maven2/com/pubnub/pubnub-kotlin/10.4.2/pubnub-kotlin-10.4.2.jar
supported-platforms:
supported-operating-systems:
Android:
Expand Down Expand Up @@ -121,6 +121,11 @@ sdks:
license-url: https://www.apache.org/licenses/LICENSE-2.0.txt
is-required: Required
changelog:
- date: 2025-02-25
version: v10.4.2
changes:
- type: bug
text: "Added deprecation warning to grant methods."
- date: 2025-01-24
version: v10.4.1
changes:
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
## v10.4.2
February 25 2025

#### Fixed
- Added deprecation warning to grant methods.

## v10.4.1
January 24 2025

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ You will need the publish and subscribe keys to authenticate your app. Get your
<dependency>
<groupId>com.pubnub</groupId>
<artifactId>pubnub-kotlin</artifactId>
<version>10.4.1</version>
<version>10.4.2</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ RELEASE_SIGNING_ENABLED=true
SONATYPE_HOST=DEFAULT
SONATYPE_AUTOMATIC_RELEASE=false
GROUP=com.pubnub
VERSION_NAME=10.4.1
VERSION_NAME=10.4.2
POM_PACKAGING=jar

POM_NAME=PubNub SDK
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,13 @@ interface PubNub : EventEmitter, StatusEmitter {
* - Channel level privileges are based on a combination of `subscribeKey` and `channel` name.
* - User level privileges are based on the combination of `subscribeKey`, `channel`, and `auth_key`.
*/
@Deprecated(
level = DeprecationLevel.WARNING,
message = "This function is deprecated. Use the grantToken(ttl)",
replaceWith = ReplaceWith(
"grantToken(ttl)"
)
)
fun grant(): Grant

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class PubNubImplTest : BaseTest() {
fun getVersionAndTimeStamp() {
val version = PubNubImpl.SDK_VERSION
val timeStamp = PubNubImpl.timestamp()
assertEquals("10.4.1", version)
assertEquals("10.4.2", version)
assertTrue(timeStamp > 0)
}

Expand Down

0 comments on commit f3ecdda

Please # to comment.