Skip to content

Commit 60126ae

Browse files
authored
Merge pull request #2723 from aws/212
2 parents 5467632 + 1a86b35 commit 60126ae

File tree

55 files changed

+942
-311
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+942
-311
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<component name="ProjectRunConfigurationManager">
2+
<configuration default="false" name="Run IDE - Core [2021.2]" type="GradleRunConfiguration" factoryName="Gradle" folderName="2021.2">
3+
<log_file alias="idea.log" path="$PROJECT_DIR$/jetbrains-core/build/idea-sandbox/system/log/idea.log" />
4+
<ExternalSystemSettings>
5+
<option name="env">
6+
<map>
7+
<entry key="ALTERNATIVE_IDE_PROFILE_NAME" value="2021.2" />
8+
</map>
9+
</option>
10+
<option name="executionName" />
11+
<option name="externalProjectPath" value="$PROJECT_DIR$/jetbrains-core" />
12+
<option name="externalSystemIdString" value="GRADLE" />
13+
<option name="scriptParameters" value="" />
14+
<option name="taskDescriptions">
15+
<list />
16+
</option>
17+
<option name="taskNames">
18+
<list>
19+
<option value="runIde" />
20+
</list>
21+
</option>
22+
<option name="vmOptions" value="" />
23+
</ExternalSystemSettings>
24+
<GradleScriptDebugEnabled>false</GradleScriptDebugEnabled>
25+
<method v="2" />
26+
</configuration>
27+
</component>
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<component name="ProjectRunConfigurationManager">
2+
<configuration default="false" name="Run IDE - Rider [2021.2]" type="GradleRunConfiguration" factoryName="Gradle" folderName="2021.2">
3+
<log_file alias="idea.log" path="$PROJECT_DIR$/jetbrains-rider/build/idea-sandbox/system/log/idea.log" />
4+
<ExternalSystemSettings>
5+
<option name="env">
6+
<map>
7+
<entry key="ALTERNATIVE_IDE_PROFILE_NAME" value="2021.2" />
8+
</map>
9+
</option>
10+
<option name="executionName" />
11+
<option name="externalProjectPath" value="$PROJECT_DIR$/jetbrains-rider" />
12+
<option name="externalSystemIdString" value="GRADLE" />
13+
<option name="scriptParameters" value="" />
14+
<option name="taskDescriptions">
15+
<list />
16+
</option>
17+
<option name="taskNames">
18+
<list>
19+
<option value="runIde" />
20+
</list>
21+
</option>
22+
<option name="vmOptions" value="" />
23+
</ExternalSystemSettings>
24+
<GradleScriptDebugEnabled>false</GradleScriptDebugEnabled>
25+
<method v="2" />
26+
</configuration>
27+
</component>
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<component name="ProjectRunConfigurationManager">
2+
<configuration default="false" name="Run IDE - Ultimate [2021.2]" type="GradleRunConfiguration" factoryName="Gradle" folderName="2021.2">
3+
<log_file alias="idea.log" path="$PROJECT_DIR$/jetbrains-ultimate/build/idea-sandbox/system/log/idea.log" />
4+
<ExternalSystemSettings>
5+
<option name="env">
6+
<map>
7+
<entry key="ALTERNATIVE_IDE_PROFILE_NAME" value="2021.2" />
8+
</map>
9+
</option>
10+
<option name="executionName" />
11+
<option name="externalProjectPath" value="$PROJECT_DIR$/jetbrains-ultimate" />
12+
<option name="externalSystemIdString" value="GRADLE" />
13+
<option name="scriptParameters" value="" />
14+
<option name="taskDescriptions">
15+
<list />
16+
</option>
17+
<option name="taskNames">
18+
<list>
19+
<option value="runIde" />
20+
</list>
21+
</option>
22+
<option name="vmOptions" value="" />
23+
</ExternalSystemSettings>
24+
<GradleScriptDebugEnabled>false</GradleScriptDebugEnabled>
25+
<method v="2" />
26+
</configuration>
27+
</component>

buildSrc/settings.gradle.kts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,15 @@ dependencyResolutionManagement {
1818
}
1919
mavenCentral()
2020
gradlePluginPortal()
21+
maven {
22+
url = uri("https://oss.sonatype.org/content/repositories/snapshots/")
23+
content {
24+
// only allowed to pull snapshots of gradle-intellij-plugin from here
25+
includeModule("org.jetbrains.intellij.plugins", "gradle-intellij-plugin")
26+
}
27+
mavenContent {
28+
snapshotsOnly()
29+
}
30+
}
2131
}
2232
}

buildSrc/src/main/kotlin/software/aws/toolkits/gradle/intellij/IdeVersions.kt

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ object IdeVersions {
4545
plugins = commonPlugins + listOf(
4646
"rider-plugins-appender" // Workaround for https://youtrack.jetbrains.com/issue/IDEA-179607
4747
),
48+
netFrameworkTarget = "net461",
4849
rdGenVersion = "0.203.161",
4950
nugetVersion = "2020.2.0"
5051
)
@@ -78,6 +79,7 @@ object IdeVersions {
7879
plugins = commonPlugins + listOf(
7980
"rider-plugins-appender" // Workaround for https://youtrack.jetbrains.com/issue/IDEA-179607
8081
),
82+
netFrameworkTarget = "net461",
8183
rdGenVersion = "0.203.161",
8284
nugetVersion = "2020.3.0"
8385
)
@@ -114,10 +116,48 @@ object IdeVersions {
114116
plugins = commonPlugins + listOf(
115117
"rider-plugins-appender" // Workaround for https://youtrack.jetbrains.com/issue/IDEA-179607
116118
),
119+
netFrameworkTarget = "net461",
117120
rdGenVersion = "0.211.234",
118121
nugetVersion = "2021.1.0"
119122
)
120123
),
124+
Profile(
125+
name = "2021.2",
126+
community = ProductProfile(
127+
sdkFlavor = IdeFlavor.IC,
128+
sdkVersion = "212.4638.7-EAP-SNAPSHOT",
129+
plugins = commonPlugins + listOf(
130+
"java",
131+
"com.intellij.gradle",
132+
"org.jetbrains.idea.maven",
133+
"PythonCore:212.4638.10",
134+
"Docker:212.4638.7"
135+
)
136+
),
137+
ultimate = ProductProfile(
138+
sdkFlavor = IdeFlavor.IU,
139+
sdkVersion = "212.4638.7-EAP-SNAPSHOT",
140+
plugins = commonPlugins + listOf(
141+
"JavaScript",
142+
// Transitive dependency needed for javascript
143+
// Can remove when https://github.com/JetBrains/gradle-intellij-plugin/issues/608 is fixed
144+
"com.intellij.css",
145+
"JavaScriptDebugger",
146+
"com.intellij.database",
147+
"Pythonid:212.4638.7",
148+
"org.jetbrains.plugins.go:212.4638.7"
149+
)
150+
),
151+
rider = RiderProfile(
152+
sdkVersion = "2021.2-SNAPSHOT",
153+
plugins = commonPlugins + listOf(
154+
"rider-plugins-appender" // Workaround for https://youtrack.jetbrains.com/issue/IDEA-179607
155+
),
156+
netFrameworkTarget = "net472",
157+
rdGenVersion = "0.212.315",
158+
nugetVersion = "2021.2.0-eap05"
159+
)
160+
),
121161
).associateBy { it.name }
122162

123163
fun ideProfile(project: Project): Profile = ideProfile(project.providers).get()
@@ -153,6 +193,7 @@ open class ProductProfile(
153193
class RiderProfile(
154194
sdkVersion: String,
155195
plugins: Array<String>,
196+
val netFrameworkTarget: String,
156197
val rdGenVersion: String, // https://www.myget.org/feed/rd-snapshots/package/maven/com.jetbrains.rd/rd-gen
157198
val nugetVersion: String // https://www.nuget.org/packages/JetBrains.Rider.SDK/
158199
) : ProductProfile(IdeFlavor.RD, sdkVersion, plugins)

gradle.properties

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,7 @@ jgitVersion=5.11.0.202103091610-r
2222

2323
gradleRetryPluginVersion=1.2.1
2424
gradleTestLoggerPlugin=3.0.0
25-
ideaPluginVersion=1.1
26-
25+
ideaPluginVersion=1.1.3
2726
# Note: Versions > 10 use process isolation which blows us out of memory in CI,
2827
# only upgrade if that is fixed or move to a different plugin
2928
ktintPluginVersion=9.4.1

jetbrains-core/it-202-203/software/aws/toolkits/jetbrains/services/ecr/DelegatedRemoteDockerApplicationRuntime.kt

Lines changed: 0 additions & 20 deletions
This file was deleted.

jetbrains-core/it-211+/software/aws/toolkits/jetbrains/services/ecr/DelegatedRemoteDockerApplicationRuntime.kt

Lines changed: 0 additions & 20 deletions
This file was deleted.

jetbrains-core/it/software/aws/toolkits/jetbrains/services/ecr/AbstractRemoteDockerApplicationRuntime.kt

Lines changed: 0 additions & 12 deletions
This file was deleted.

jetbrains-core/it/software/aws/toolkits/jetbrains/services/ecr/EcrPullIntegrationTest.kt

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33

44
package software.aws.toolkits.jetbrains.services.ecr
55

6-
import com.intellij.docker.remote.run.runtime.DockerAgentBuildImageConfig
76
import com.intellij.testFramework.ProjectRule
87
import kotlinx.coroutines.runBlocking
98
import org.assertj.core.api.Assertions.assertThat
@@ -14,6 +13,7 @@ import org.junit.rules.TemporaryFolder
1413
import software.amazon.awssdk.regions.Region
1514
import software.amazon.awssdk.services.ecr.EcrClient
1615
import software.aws.toolkits.core.rules.EcrTemporaryRepositoryRule
16+
import software.aws.toolkits.jetbrains.core.docker.ToolkitDockerAdapter
1717
import software.aws.toolkits.jetbrains.services.ecr.resources.Repository
1818
import java.util.UUID
1919

@@ -58,22 +58,27 @@ class EcrPullIntegrationTest {
5858
runBlocking {
5959
val serverInstance = EcrUtils.getDockerServerRuntimeInstance().runtimeInstance
6060
val ecrLogin = ecrClient.authorizationToken.authorizationData().first().getDockerLogin()
61-
val runtime = DelegatedRemoteDockerApplicationRuntime(
62-
project,
63-
DockerAgentBuildImageConfig(System.currentTimeMillis().toString(), dockerfile, false)
64-
)
61+
val dockerAdapter = ToolkitDockerAdapter(project, serverInstance)
62+
val imageId = dockerAdapter.buildLocalImage(dockerfile)!!
63+
6564
// gross transform because we only have the short SHA right now
66-
val localImageId = runtime.agent.getImages(null).first { it.imageId.startsWith("sha256:${runtime.agentApplication.imageId}") }.imageId
65+
val localImage = serverInstance.agent.getImages(null).first { it.imageId.startsWith("sha256:$imageId") }
66+
val localImageId = localImage.imageId
6767
val config = EcrUtils.buildDockerRepositoryModel(ecrLogin, remoteRepo, remoteTag)
68-
68+
val pushRequest = ImageEcrPushRequest(
69+
serverInstance,
70+
localImageId,
71+
remoteRepo,
72+
remoteTag
73+
)
6974
// push up and image and then delete the local tag
70-
EcrUtils.pushImage(projectRule.project, localImageId, serverInstance, config)
71-
runtime.agentApplication.deleteImage()
72-
assertThat(runtime.agent.getImages(null).firstOrNull { it.imageId == localImageId }).isNull()
75+
EcrUtils.pushImage(projectRule.project, ecrLogin, pushRequest)
76+
localImage.deleteImage()
77+
assertThat(serverInstance.agent.getImages(null).firstOrNull { it.imageId == localImageId }).isNull()
7378

7479
// pull it from the remote
75-
EcrUtils.pullImage(project, serverInstance, config).await()
76-
assertThat(runtime.agent.getImages(null).firstOrNull { it.imageId == localImageId }).isNotNull()
80+
dockerAdapter.pullImage(config).await()
81+
assertThat(serverInstance.agent.getImages(null).firstOrNull { it.imageId == localImageId }).isNotNull()
7782
}
7883
}
7984
}

0 commit comments

Comments
 (0)