@@ -25,7 +25,7 @@ import { withServerApi } from './internalApi';
25
25
import TelemetryReporter from './telemetryReporter' ;
26
26
import { addHostToHostFile , checkNewHostInHostkeys } from './ssh/hostfile' ;
27
27
import { HeartbeatManager } from './heartbeat' ;
28
- import { getGitpodVersion , GitpodVersion , isFeatureSupported , isOauthInspectSupported , ScopeFeature } from './featureSupport' ;
28
+ import { getGitpodVersion , isFeatureSupported , isOauthInspectSupported , ScopeFeature } from './featureSupport' ;
29
29
import SSHConfiguration from './ssh/sshConfig' ;
30
30
import { ExperimentalSettings , isUserOverrideSetting } from './experiments' ;
31
31
import { ISyncExtension , NoSettingsSyncSession , NoSyncStoreError , parseSyncData , SettingsSync , SyncResource } from './settingsSync' ;
@@ -861,23 +861,20 @@ export default class RemoteConnector extends Disposable {
861
861
}
862
862
}
863
863
864
- private async startHeartBeat ( session : vscode . AuthenticationSession , connectionInfo : SSHConnectionParams , gitpodVersion : GitpodVersion ) {
864
+ private async startHeartBeat ( session : vscode . AuthenticationSession , connectionInfo : SSHConnectionParams ) {
865
865
if ( this . heartbeatManager ) {
866
866
return ;
867
867
}
868
868
869
869
this . heartbeatManager = new HeartbeatManager ( connectionInfo . gitpodHost , connectionInfo . workspaceId , connectionInfo . instanceId , ! ! connectionInfo . debugWorkspace , session . accessToken , this . publicApi , this . logger , this . telemetry ) ;
870
870
871
- // gitpod remote extension installation is async so sometimes gitpod-desktop will activate before gitpod-remote
872
- // let's try a few times for it to finish install
873
871
try {
872
+ // TODO: remove this in the future, gitpod-remote no longer has the heartbeat logic, it's just here until users
873
+ // update to the latest version of gitpod-remote
874
874
await retry ( async ( ) => {
875
875
await vscode . commands . executeCommand ( '__gitpod.cancelGitpodRemoteHeartbeat' ) ;
876
876
} , 3000 , 15 ) ;
877
- this . telemetry . sendTelemetryEvent ( 'vscode_desktop_heartbeat_state' , { enabled : String ( true ) , gitpodHost : connectionInfo . gitpodHost , workspaceId : connectionInfo . workspaceId , instanceId : connectionInfo . instanceId , debugWorkspace : String ( ! ! connectionInfo . debugWorkspace ) , gitpodVersion : gitpodVersion . raw } ) ;
878
877
} catch {
879
- this . logger . error ( `Could not execute '__gitpod.cancelGitpodRemoteHeartbeat' command` ) ;
880
- this . telemetry . sendTelemetryEvent ( 'vscode_desktop_heartbeat_state' , { enabled : String ( false ) , gitpodHost : connectionInfo . gitpodHost , workspaceId : connectionInfo . workspaceId , instanceId : connectionInfo . instanceId , debugWorkspace : String ( ! ! connectionInfo . debugWorkspace ) , gitpodVersion : gitpodVersion . raw } ) ;
881
878
}
882
879
}
883
880
@@ -1030,7 +1027,7 @@ export default class RemoteConnector extends Disposable {
1030
1027
1031
1028
const heartbeatSupported = session . scopes . includes ( ScopeFeature . LocalHeartbeat ) ;
1032
1029
if ( heartbeatSupported ) {
1033
- this . startHeartBeat ( session , connectionInfo , gitpodVersion ) ;
1030
+ this . startHeartBeat ( session , connectionInfo ) ;
1034
1031
} else {
1035
1032
this . logger . warn ( `Local heartbeat not supported in ${ connectionInfo . gitpodHost } , using version ${ gitpodVersion . raw } ` ) ;
1036
1033
}
0 commit comments