IDEA-CR-62611: IDEA-236152 disable reporting statistics

GitOrigin-RevId: 1947b96d0f7f62892f6e9d09454eea2af798a291
This commit is contained in:
Anastasia Ivanova
2020-06-15 05:42:50 +03:00
committed by intellij-monorepo-bot
parent fefac91728
commit 3fc26cb662
27 changed files with 53 additions and 40 deletions
@@ -1,11 +1,11 @@
// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.configurationStore
import com.intellij.openapi.components.*
import com.intellij.openapi.project.Project
import com.intellij.util.xmlb.annotations.Attribute
@State(name = "ProjectId", storages = [(Storage(StoragePathMacros.WORKSPACE_FILE))])
@State(name = "ProjectId", storages = [(Storage(StoragePathMacros.WORKSPACE_FILE))], reportStatistic = false)
internal class ProjectIdManager : SimplePersistentStateComponent<ProjectIdState>(ProjectIdState()) {
companion object {
fun getInstance(project: Project) = project.service<ProjectIdManager>()
@@ -1,4 +1,4 @@
// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.credentialStore
import com.intellij.ide.passwordSafe.impl.getDefaultKeePassDbFile
@@ -10,7 +10,7 @@ import com.intellij.util.text.nullize
import com.intellij.util.xmlb.annotations.OptionTag
@Service
@State(name = "PasswordSafe", storages = [Storage(value = "security.xml", roamingType = RoamingType.DISABLED)])
@State(name = "PasswordSafe", storages = [Storage(value = "security.xml", roamingType = RoamingType.DISABLED)], reportStatistic = false)
class PasswordSafeSettings : PersistentStateComponentWithModificationTracker<PasswordSafeSettings.PasswordSafeOptions> {
companion object {
@JvmField
@@ -59,7 +59,7 @@ import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReadWriteLock;
import java.util.function.IntPredicate;
@State(name = "FileBasedIndex", storages = @Storage(StoragePathMacros.CACHE_FILE))
@State(name = "FileBasedIndex", storages = @Storage(StoragePathMacros.CACHE_FILE), reportStatistic = false)
public final class StubIndexImpl extends StubIndexEx implements PersistentStateComponent<StubIndexState> {
private static final AtomicReference<Boolean> ourForcedClean = new AtomicReference<>(null);
static final Logger LOG = Logger.getInstance(StubIndexImpl.class);
@@ -51,7 +51,7 @@ import java.util.regex.Pattern;
import static com.intellij.openapi.util.Pair.pair;
@State(name = "HttpConfigurable", storages = @Storage("proxy.settings.xml"))
@State(name = "HttpConfigurable", storages = @Storage("proxy.settings.xml"), reportStatistic = false)
public class HttpConfigurable implements PersistentStateComponent<HttpConfigurable>, Disposable {
private static final Logger LOG = Logger.getInstance(HttpConfigurable.class);
private static final File PROXY_CREDENTIALS_FILE = new File(PathManager.getOptionsPath(), "proxy.settings.pwd");
@@ -1,4 +1,4 @@
// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.util.net.ssl;
import com.intellij.openapi.application.Application;
@@ -63,7 +63,7 @@ import java.util.concurrent.atomic.AtomicReference;
*
* @author Mikhail Golubev
*/
@State(name = "CertificateManager", storages = @Storage("certificates.xml"))
@State(name = "CertificateManager", storages = @Storage("certificates.xml"), reportStatistic = false)
public final class CertificateManager implements PersistentStateComponent<CertificateManager.Config> {
@NonNls public static final String COMPONENT_NAME = "Certificate Manager";
@NonNls public static final String DEFAULT_PATH = FileUtil.join(PathManager.getConfigPath(), "ssl", "cacerts");
@@ -26,7 +26,10 @@ import java.util.Set;
import static com.intellij.internal.statistic.utils.PluginInfoDetectorKt.getPluginInfo;
@State(name = "FeatureUsageStatistics", storages = @Storage(value = UsageStatisticsPersistenceComponent.USAGE_STATISTICS_XML, roamingType = RoamingType.DISABLED))
@State(
name = "FeatureUsageStatistics",
storages = @Storage(value = UsageStatisticsPersistenceComponent.USAGE_STATISTICS_XML, roamingType = RoamingType.DISABLED),
reportStatistic = false)
public final class FeatureUsageTrackerImpl extends FeatureUsageTracker implements PersistentStateComponent<Element> {
private static final int HOUR = 1000 * 60 * 60;
private static final long DAY = HOUR * 24;
@@ -59,7 +59,7 @@ import kotlin.collections.component2
/**
* Used directly by IntelliJ IDEA.
*/
@State(name = "RecentProjectsManager", storages = [Storage(value = "recentProjects.xml", roamingType = RoamingType.DISABLED)])
@State(name = "RecentProjectsManager", storages = [Storage(value = "recentProjects.xml", roamingType = RoamingType.DISABLED)], reportStatistic = false)
open class RecentProjectsManagerBase : RecentProjectsManager(), PersistentStateComponent<RecentProjectManagerState>, ModificationTracker {
companion object {
const val MAX_PROJECTS_IN_MAIN_MENU = 6
@@ -609,7 +609,9 @@ private fun convertToSystemIndependentPaths(list: MutableList<String>) {
}
@Service
@State(name = "RecentDirectoryProjectsManager", storages = [Storage(value = "recentProjectDirectories.xml", roamingType = RoamingType.DISABLED, deprecated = true)])
@State(name = "RecentDirectoryProjectsManager",
storages = [Storage(value = "recentProjectDirectories.xml", roamingType = RoamingType.DISABLED, deprecated = true)],
reportStatistic = false)
private class OldRecentDirectoryProjectsManager : PersistentStateComponent<RecentProjectManagerState> {
var loadedState: RecentProjectManagerState? = null
@@ -1,4 +1,4 @@
// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.ide.util;
import com.intellij.openapi.components.RoamingType;
@@ -9,6 +9,6 @@ import com.intellij.openapi.components.StoragePathMacros;
@State(name = "PropertiesComponent", storages = {
@Storage(value = StoragePathMacros.NON_ROAMABLE_FILE, roamingType = RoamingType.DISABLED),
@Storage(value = "options.xml", roamingType = RoamingType.DISABLED, deprecated = true)
})
}, reportStatistic = false)
public class AppPropertiesComponentImpl extends PropertiesComponentImpl {
}
@@ -65,7 +65,7 @@ import java.util.function.Predicate;
@State(name = "IdeDocumentHistory", storages = {
@Storage(StoragePathMacros.PRODUCT_WORKSPACE_FILE),
@Storage(value = StoragePathMacros.WORKSPACE_FILE, deprecated = true)
})
}, reportStatistic = false)
public class IdeDocumentHistoryImpl extends IdeDocumentHistory implements Disposable, PersistentStateComponent<IdeDocumentHistoryImpl.RecentlyChangedFilesState> {
private static final Logger LOG = Logger.getInstance(IdeDocumentHistoryImpl.class);
@@ -15,7 +15,7 @@ import com.intellij.util.xmlb.annotations.XMap
@State(name = "ActionsLocalSummary", storages = [
Storage("actionSummary.xml", roamingType = RoamingType.DISABLED),
Storage("actions_summary.xml", deprecated = true)
])
], reportStatistic = false)
class ActionsLocalSummary : SimplePersistentStateComponent<ActionsLocalSummaryState>(ActionsLocalSummaryState()) {
fun getActionsStats(): Map<String, ActionSummary> = state.data.toMap()
}
@@ -11,7 +11,8 @@ import org.jetbrains.annotations.Nullable;
@State(
name = "UsagesStatistic",
storages = @Storage(value = UsageStatisticsPersistenceComponent.USAGE_STATISTICS_XML, roamingType = RoamingType.DISABLED)
storages = @Storage(value = UsageStatisticsPersistenceComponent.USAGE_STATISTICS_XML, roamingType = RoamingType.DISABLED),
reportStatistic = false
)
@Service
public final class UsageStatisticsPersistenceComponent implements PersistentStateComponent<Element> {
@@ -1,4 +1,4 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.vcs.log.data.index;
import com.intellij.openapi.Disposable;
@@ -14,7 +14,8 @@ import java.util.EventListener;
import java.util.SortedSet;
import java.util.TreeSet;
@State(name = "Vcs.Log.Big.Repositories", storages = {@Storage(value = "vcs.log.big.repos.xml", roamingType = RoamingType.DISABLED)})
@State(name = "Vcs.Log.Big.Repositories", storages = {@Storage(value = "vcs.log.big.repos.xml", roamingType = RoamingType.DISABLED)},
reportStatistic = false)
public class VcsLogBigRepositoriesList implements PersistentStateComponent<VcsLogBigRepositoriesList.State> {
@NotNull private final Object myLock = new Object();
@NotNull private final EventDispatcher<Listener> myDispatcher = EventDispatcher.create(Listener.class);
@@ -27,7 +27,8 @@ import org.jetbrains.annotations.NonNls;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
@State(name = "CvsApplicationLevelConfiguration", storages = @Storage(value = "other.xml", roamingType = RoamingType.DISABLED))
@State(name = "CvsApplicationLevelConfiguration", storages = @Storage(value = "other.xml", roamingType = RoamingType.DISABLED),
reportStatistic = false)
public class CvsApplicationLevelConfiguration implements PersistentStateComponent<Element> {
private static final Logger LOG = Logger.getInstance(CvsApplicationLevelConfiguration.class);
@@ -1,4 +1,4 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package git4idea.config;
import com.intellij.openapi.components.*;
@@ -15,7 +15,8 @@ import java.util.TreeMap;
*/
@State(
name = "SSHConnectionSettings",
storages = @Storage(value = "security.xml", roamingType = RoamingType.DISABLED)
storages = @Storage(value = "security.xml", roamingType = RoamingType.DISABLED),
reportStatistic = false
)
public class SSHConnectionSettings implements PersistentStateComponent<SSHConnectionSettings.State> {
/**
@@ -9,7 +9,8 @@ import git4idea.rebase.GitRebaseUtils
@State(
name = "GitRewordedCommitMessages",
storages = [Storage(file = StoragePathMacros.WORKSPACE_FILE, roamingType = RoamingType.DISABLED)]
storages = [Storage(file = StoragePathMacros.WORKSPACE_FILE, roamingType = RoamingType.DISABLED)],
reportStatistic = false
)
internal class GitRewordedCommitMessageProvider :
SimplePersistentStateComponent<GitRewordedCommitMessagesInfo>(GitRewordedCommitMessagesInfo()) {
@@ -301,7 +301,7 @@ private val BRANCH_TREE_TRANSFER_HANDLER = object : TransferHandler() {
override fun getSourceActions(c: JComponent) = COPY_OR_MOVE
}
@State(name = "BranchesTreeState", storages = [Storage(StoragePathMacros.WORKSPACE_FILE)])
@State(name = "BranchesTreeState", storages = [Storage(StoragePathMacros.WORKSPACE_FILE)], reportStatistic = false)
internal class BranchesTreeStateHolder : PersistentStateComponent<TreeState> {
private lateinit var branchesTree: FilteringBranchesTree
private lateinit var treeState: TreeState
@@ -25,7 +25,7 @@ internal val GithubAccount.isGHAccount: Boolean get() = server.isGithubDotCom
@State(name = "GithubAccounts", storages = [
Storage(value = "github.xml"),
Storage(value = "github_settings.xml", deprecated = true)
])
], reportStatistic = false)
internal class GithubAccountManager : PersistentStateComponent<Array<GithubAccount>> {
var accounts: Set<GithubAccount> by observable(setOf()) { _, oldValue, newValue ->
oldValue.filter { it !in newValue }.forEach(this::accountRemoved)
@@ -12,7 +12,7 @@ import org.jetbrains.plugins.github.util.GithubNotifications
*
* TODO: auto-detection
*/
@State(name = "GithubDefaultAccount", storages = [Storage(StoragePathMacros.WORKSPACE_FILE)])
@State(name = "GithubDefaultAccount", storages = [Storage(StoragePathMacros.WORKSPACE_FILE)], reportStatistic = false)
internal class GithubProjectDefaultAccountHolder(private val project: Project) : PersistentStateComponent<AccountState> {
var account: GithubAccount? = null
@@ -4,7 +4,7 @@ package org.jetbrains.plugins.github.pullrequest.config
import com.intellij.openapi.components.*
import com.intellij.openapi.project.Project
@State(name = "GithubPullRequestsUISettings", storages = [Storage(StoragePathMacros.WORKSPACE_FILE)])
@State(name = "GithubPullRequestsUISettings", storages = [Storage(StoragePathMacros.WORKSPACE_FILE)], reportStatistic = false)
class GithubPullRequestsProjectUISettings : PersistentStateComponentWithModificationTracker<GithubPullRequestsProjectUISettings.SettingsState> {
private var state: SettingsState = SettingsState()
@@ -1,4 +1,4 @@
// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package org.jetbrains.plugins.github.util;
import com.intellij.openapi.components.*;
@@ -10,7 +10,7 @@ import org.jetbrains.plugins.github.api.GHRepositoryPath;
/**
* @author Aleksey Pivovarov
*/
@State(name = "GithubProjectSettings", storages = @Storage(StoragePathMacros.WORKSPACE_FILE))
@State(name = "GithubProjectSettings", storages = @Storage(StoragePathMacros.WORKSPACE_FILE), reportStatistic = false)
public class GithubProjectSettings implements PersistentStateComponent<GithubProjectSettings.State> {
private State myState = new State();
@@ -1,4 +1,4 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.lang.properties;
import com.intellij.injected.editor.VirtualFileWindow;
@@ -19,7 +19,8 @@ import java.util.Map;
@State(
name = "LastSelectedPropertiesFileStore",
storages = @Storage(value = "lastSelectedPropertiesFile.xml", roamingType = RoamingType.DISABLED)
storages = @Storage(value = "lastSelectedPropertiesFile.xml", roamingType = RoamingType.DISABLED),
reportStatistic = false
)
public class LastSelectedPropertiesFileStore implements PersistentStateComponent<Element> {
private final Map<String, String> lastSelectedUrls = new LinkedHashMap<>();
+2 -2
View File
@@ -1,4 +1,4 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package org.jetbrains.settingsRepository
import com.intellij.openapi.components.PersistentStateComponent
@@ -7,7 +7,7 @@ import com.intellij.openapi.components.Storage
import com.intellij.openapi.components.StoragePathMacros
import com.intellij.util.xmlb.XmlSerializerUtil
@State(name = "IcsProjectId", storages = [(Storage(StoragePathMacros.WORKSPACE_FILE))])
@State(name = "IcsProjectId", storages = [(Storage(StoragePathMacros.WORKSPACE_FILE))], reportStatistic = false)
class ProjectId : PersistentStateComponent<ProjectId> {
var uid: String? = null
var path: String? = null
@@ -1,9 +1,9 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.stats.personalization.impl
import com.intellij.openapi.components.RoamingType
import com.intellij.openapi.components.State
import com.intellij.openapi.components.Storage
@State(name = "ApplicationUserFactors", storages = [(Storage(value = "completion.factors.user.xml", roamingType = RoamingType.DISABLED))])
@State(name = "ApplicationUserFactors", storages = [(Storage(value = "completion.factors.user.xml", roamingType = RoamingType.DISABLED))], reportStatistic = false)
class ApplicationUserFactorStorage : UserFactorStorageBase()
@@ -1,4 +1,4 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.stats.personalization.impl
@@ -12,5 +12,6 @@ import com.intellij.openapi.components.StoragePathMacros
@State(name = "ProjectUserFactors", storages = [
Storage(StoragePathMacros.CACHE_FILE),
Storage(StoragePathMacros.WORKSPACE_FILE, deprecated = true)
])
],
reportStatistic = false)
class ProjectUserFactorStorage : UserFactorStorageBase()
@@ -29,7 +29,7 @@ import static org.jetbrains.idea.svn.IdeaSVNConfigFile.SERVERS_FILE_NAME;
import static org.jetbrains.idea.svn.SvnUtil.SYSTEM_CONFIGURATION_PATH;
import static org.jetbrains.idea.svn.SvnUtil.USER_CONFIGURATION_PATH;
@State(name = "SvnConfiguration", storages = @Storage(StoragePathMacros.WORKSPACE_FILE))
@State(name = "SvnConfiguration", storages = @Storage(StoragePathMacros.WORKSPACE_FILE), reportStatistic = false)
public class SvnConfiguration implements PersistentStateComponent<SvnConfigurationState>, Disposable {
public final static int ourMaxAnnotateRevisionsDefault = 500;
@@ -12,7 +12,7 @@ import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
@State(name = "PyPackageService", storages = @Storage(value = "packages.xml", roamingType = RoamingType.DISABLED))
@State(name = "PyPackageService", storages = @Storage(value = "packages.xml", roamingType = RoamingType.DISABLED), reportStatistic = false)
public class PyPackageService implements
PersistentStateComponent<PyPackageService> {
public volatile Map<String, Boolean> sdkToUsersite = new ConcurrentHashMap<>();
@@ -1,4 +1,4 @@
// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.spellchecker.state;
import com.intellij.openapi.components.*;
@@ -9,7 +9,8 @@ import org.jetbrains.annotations.NotNull;
@State(
name = "CachedDictionaryState",
storages = @Storage(value = "cachedDictionary.xml", roamingType = RoamingType.DISABLED)
storages = @Storage(value = "cachedDictionary.xml", roamingType = RoamingType.DISABLED),
reportStatistic = false
)
public class CachedDictionaryState extends DictionaryState implements PersistentStateComponent<DictionaryState> {
public static final String DEFAULT_NAME = "cached";