Skip to content

Commit

Permalink
Added Support for Porxy.
Browse files Browse the repository at this point in the history
Code Cleanup for Pubnub, PubnubCoreBase, PNConfiguration class,
Code Cleanup - removed dead codes in various files and removed old PubnubHttpClient footprints.
  • Loading branch information
mohitpubnub committed Oct 22, 2024
1 parent d6500c9 commit 7a5244e
Show file tree
Hide file tree
Showing 13 changed files with 163 additions and 1,808 deletions.
1 change: 0 additions & 1 deletion src/Api/PubnubApi/ClientNetworkStatus.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using System;
using System.Threading;
using System.Threading.Tasks;
using System.Globalization;
using System.Collections.Generic;
Expand Down
27 changes: 0 additions & 27 deletions src/Api/PubnubApi/Interface/IPubnubHttp.cs

This file was deleted.

100 changes: 0 additions & 100 deletions src/Api/PubnubApi/Interface/IUrlRequestBuilder.cs

This file was deleted.

36 changes: 6 additions & 30 deletions src/Api/PubnubApi/PNConfiguration.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
using PubnubApi.Security.Crypto;
using System;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;

namespace PubnubApi
{
Expand All @@ -22,24 +19,15 @@ internal void ResetUuidSetFromConstructor()

public int PresenceTimeout
{
get
{
return presenceHeartbeatTimeout;
}
get => presenceHeartbeatTimeout;
set
{
presenceHeartbeatTimeout = value;
SetPresenceTimeoutWithCustomInterval(presenceHeartbeatTimeout, (presenceHeartbeatTimeout / 2) - 1);
}
}

public int PresenceInterval
{
get
{
return presenceHeartbeatInterval;
}
}
public int PresenceInterval => presenceHeartbeatInterval;

public bool Secure { get; set; }

Expand All @@ -61,10 +49,7 @@ public int PresenceInterval
[Obsolete("Uuid is deprecated, please use UserId instead.")]
public string Uuid
{
get
{
return userId.ToString();
}
get => userId.ToString();
set
{
if (userId != null && !uuidSetFromConstructor)
Expand All @@ -85,10 +70,7 @@ public string Uuid

public UserId UserId
{
get
{
return userId;
}
get => userId;
set
{
if (uuidSetFromConstructor)
Expand Down Expand Up @@ -138,12 +120,6 @@ public PNReconnectionPolicy ReconnectionPolicy {

public int RequestMessageCountThreshold { get; set; } = 100;

public bool UseClassicHttpWebRequest { get; set; }

public bool UseTaskFactoryAsyncInsteadOfHttpClient { get; set; }

public bool EnableTelemetry { get; set; } = true;

public int MaximumMessagesCacheSize { get; set; }

public bool DedupOnSubscribe { get; set; }
Expand Down Expand Up @@ -217,8 +193,8 @@ private void setDefaultRetryConfigurationFromPolicy(PNReconnectionPolicy policy)

public PNConfiguration SetPresenceTimeoutWithCustomInterval(int timeout, int interval)
{
this.presenceHeartbeatTimeout = timeout;
this.presenceHeartbeatInterval = interval;
presenceHeartbeatTimeout = timeout;
presenceHeartbeatInterval = interval;

return this;
}
Expand Down
Loading

0 comments on commit 7a5244e

Please sign in to comment.