Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add AttachedDisk class, related configurations and tests #917

Merged
merged 2 commits into from
Apr 25, 2016

Conversation

mziccard
Copy link
Contributor

@mziccard mziccard commented Apr 13, 2016

This PR adds support for Compute's instances attached disks.

Attached disks are provided to an instance upon creation or via the attachDisk API. Since attachDisk only supports attaching already existing persistent disks (no support for scratch disks or creation on the fly) our attachDisk method (coming in a following PR) will look like:

Operation attachDisk(InstanceId instance, PersistentDiskConfiguration configuration,
    OperationOption... options);

Operation attachDisk(InstanceId instance, String deviceName,
    PersistentDiskConfiguration configuration, OperationOption... options);

Operation attachDisk(InstanceId instance, String deviceName,
    PersistentDiskConfiguration configuration, int deviceIndex,
    OperationOption... options);

Also the InstanceInfo.of method will look like:

InstanceInfo of(InstanceId instance, MachineTypeId machineType,
    AttachedDisk attachedDisk, NetworkInterface networkinterface);

However an instance can be created only if an AttachedDisk with PersistentDiskConfiguration or CreateDiskConfiguration is passed, and this method does not enforce that constraint.

@mziccard mziccard added the api: compute Issues related to the Compute Engine API. label Apr 13, 2016
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Apr 13, 2016
@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 6e93362 on mziccard:compute-attached-disk into * on GoogleCloudPlatform:compute-alpha*.

@aozarov
Copy link
Contributor

aozarov commented Apr 18, 2016

I am confused.

The associated link, attached disks specify that both PERSISTENT AND SCRATCH are valid options as a disk type.

@mziccard
Copy link
Contributor Author

I am confused.
The associated link, attached disks specify that both PERSISTENT AND SCRATCH are valid options as a disk type.

I guess that is just a copy-paste from the description of an attached disk resource. In reality if I try to pass either a scratch disk or create a persistent disk on the fly (ScratchDiskConfiguration or CreateDiskConfiguration) I get the following error:

{
 "error": {
  "errors": [
   {
    "domain": "global",
    "reason": "invalid",
    "message": "Invalid value for field 'resource.initializeParams': ''. Cannot specify initialize params during attach disk, the persistent disk must exist."
   }
  ],
  "code": 400,
  "message": "Invalid value for field 'resource.initializeParams': ''. Cannot specify initialize params during attach disk, the persistent disk must exist."
 }
}

Which made me conclude that only attaching an existing persistent disk is supported.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 83.715% when pulling ba8b011 on mziccard:compute-attached-disk into 90df0e5 on GoogleCloudPlatform:compute-alpha.

* will use the first partition of the disk for its root filesystem. If not specified, the
* disk is not used as a boot disk.
* instance will use the first partition of the disk for its root filesystem. If not
* specified, the isk is not used as a boot disk.

This comment was marked as spam.

@aozarov
Copy link
Contributor

aozarov commented Apr 22, 2016

As discuessed in #928 I like this approach better. Looks good to me but I didn't look carefully at the details.

@mziccard mziccard merged commit 312cff9 into googleapis:compute-alpha Apr 25, 2016
mziccard added a commit to mziccard/gcloud-java that referenced this pull request Apr 29, 2016
)

* Add AttachedDisk class, related configurations and tests

* Minor changes to AttachedDisk
github-actions bot pushed a commit that referenced this pull request Jun 21, 2022
…onfig to v1.5.0 (#917)

[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [com.google.cloud:google-cloud-shared-config](https://github.com/googleapis/java-shared-config) | `1.4.0` -> `1.5.0` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.5.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.5.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.5.0/compatibility-slim/1.4.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-config/1.5.0/confidence-slim/1.4.0)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>googleapis/java-shared-config</summary>

### [`v1.5.0`](https://github.com/googleapis/java-shared-config/blob/HEAD/CHANGELOG.md#&#8203;150-httpsgithubcomgoogleapisjava-shared-configcomparev140v150-2022-06-10)

[Compare Source](https://github.com/googleapis/java-shared-config/compare/v1.4.0...v1.5.0)

##### Features

-   add build scripts for native image testing in Java 17 ([#&#8203;1440](https://github.com/googleapis/java-shared-config/issues/1440)) ([#&#8203;475](https://github.com/googleapis/java-shared-config/issues/475)) ([e4dfc1b](https://github.com/googleapis/java-shared-config/commit/e4dfc1ba29295158c78c8fcf94467d2a6a33538a))
-   to produce Java 8 compatible bytecode when using JDK 9+ ([2468276](https://github.com/googleapis/java-shared-config/commit/2468276145cdfe1ca911b52f765e026e77661a09))

##### Dependencies

-   update surefire.version to v3.0.0-m7 ([bbfe663](https://github.com/googleapis/java-shared-config/commit/bbfe66393af3e49612c9c1e4334ba39c133ea1d0))

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox.

---

This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-video-intelligence).
github-actions bot pushed a commit that referenced this pull request Jul 14, 2022
Source-Link: googleapis/synthtool@18d4e9b
Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:f8374176dc59291f05dd3fec927a9da2cda687a9ef4de32e77f699a2be12ab45
github-actions bot pushed a commit that referenced this pull request Aug 16, 2022
…-info-reports-plugin to v3.4.1 (#917)

[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [org.apache.maven.plugins:maven-project-info-reports-plugin](https://maven.apache.org/plugins/) | `3.4.0` -> `3.4.1` | [![age](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.4.1/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.4.1/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.4.1/compatibility-slim/3.4.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/org.apache.maven.plugins:maven-project-info-reports-plugin/3.4.1/confidence-slim/3.4.0)](https://docs.renovatebot.com/merge-confidence/) |

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost.

---

This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-monitoring).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzMi4xNTkuMSIsInVwZGF0ZWRJblZlciI6IjMyLjE1OS4xIn0=-->
github-actions bot pushed a commit that referenced this pull request Sep 19, 2022
🤖 I have created a release *beep* *boop*
---


## [4.0.5](googleapis/java-dataproc@v4.0.4...v4.0.5) (2022-09-16)


### Dependencies

* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.3 ([#915](googleapis/java-dataproc#915)) ([f1b89a1](googleapis/java-dataproc@f1b89a1))

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
github-actions bot pushed a commit that referenced this pull request Oct 4, 2022
🤖 I have created a release *beep* *boop*
---


## [3.0.10](https://github.com/googleapis/java-recaptchaenterprise/compare/v3.0.9...v3.0.10) (2022-09-30)


### Dependencies

* Update dependency cachetools to v5 ([#912](https://github.com/googleapis/java-recaptchaenterprise/issues/912)) ([4159fc9](https://github.com/googleapis/java-recaptchaenterprise/commit/4159fc9c2ba53bc563a7e09f3d27822cad14ede7))
* Update dependency certifi to v2022.9.24 ([#900](https://github.com/googleapis/java-recaptchaenterprise/issues/900)) ([53295c2](https://github.com/googleapis/java-recaptchaenterprise/commit/53295c27b5f6e6bd158c28724c19a61c04151b1f))
* Update dependency charset-normalizer to v2.1.1 ([#907](https://github.com/googleapis/java-recaptchaenterprise/issues/907)) ([b37e4be](https://github.com/googleapis/java-recaptchaenterprise/commit/b37e4befa4100a81194c5377f36e85118968627f))
* Update dependency gcp-releasetool to v1.8.8 ([#903](https://github.com/googleapis/java-recaptchaenterprise/issues/903)) ([1d64421](https://github.com/googleapis/java-recaptchaenterprise/commit/1d64421af98f2e77df87f2560b1afce4394f67f8))
* Update dependency google-auth to v2.11.1 ([#904](https://github.com/googleapis/java-recaptchaenterprise/issues/904)) ([6828992](https://github.com/googleapis/java-recaptchaenterprise/commit/682899284938f44285dce994dc54f6a330bcad2b))
* Update dependency google-cloud-core to v2.3.2 ([#905](https://github.com/googleapis/java-recaptchaenterprise/issues/905)) ([cbdf325](https://github.com/googleapis/java-recaptchaenterprise/commit/cbdf325035285d2e446ae73794b67bb653d15488))
* Update dependency googleapis-common-protos to v1.56.4 ([#906](https://github.com/googleapis/java-recaptchaenterprise/issues/906)) ([5050174](https://github.com/googleapis/java-recaptchaenterprise/commit/5050174da1fc1e7ef450c7eed7d1626d42353e26))
* Update dependency markupsafe to v2.1.1 ([#901](https://github.com/googleapis/java-recaptchaenterprise/issues/901)) ([b69312b](https://github.com/googleapis/java-recaptchaenterprise/commit/b69312b49dc9ea402e49838fd0d19ad29e1e648c))
* Update dependency org.seleniumhq.selenium:selenium-chrome-driver to v4.5.0 ([#916](https://github.com/googleapis/java-recaptchaenterprise/issues/916)) ([7f3c8f5](https://github.com/googleapis/java-recaptchaenterprise/commit/7f3c8f509715d5e0e5bbe9ed0f23d3c06b9be192))
* Update dependency org.seleniumhq.selenium:selenium-java to v4.5.0 ([#917](https://github.com/googleapis/java-recaptchaenterprise/issues/917)) ([4c55f09](https://github.com/googleapis/java-recaptchaenterprise/commit/4c55f09c717c2d20aeebbe73a5e3744d369a4d95))
* Update dependency protobuf to v3.20.2 ([#902](https://github.com/googleapis/java-recaptchaenterprise/issues/902)) ([aca7cfb](https://github.com/googleapis/java-recaptchaenterprise/commit/aca7cfbad09d106025602a61079ca3e9a9d9fda1))
* Update dependency protobuf to v4 ([#913](https://github.com/googleapis/java-recaptchaenterprise/issues/913)) ([0b2ab6b](https://github.com/googleapis/java-recaptchaenterprise/commit/0b2ab6b246758e6d411679cd156e6f935a9d4f13))
* Update dependency pyjwt to v2.5.0 ([#908](https://github.com/googleapis/java-recaptchaenterprise/issues/908)) ([a3e1c2f](https://github.com/googleapis/java-recaptchaenterprise/commit/a3e1c2f178073ef0f17ea338040b6859337b0146))
* Update dependency requests to v2.28.1 ([#909](https://github.com/googleapis/java-recaptchaenterprise/issues/909)) ([bbe8f9b](https://github.com/googleapis/java-recaptchaenterprise/commit/bbe8f9bd59ed333959a33a815326fe973d0aab7c))
* Update dependency typing-extensions to v4.3.0 ([#910](https://github.com/googleapis/java-recaptchaenterprise/issues/910)) ([6b2630e](https://github.com/googleapis/java-recaptchaenterprise/commit/6b2630eaeed410409f6d0521b6a6bd7fc435f905))
* Update dependency zipp to v3.8.1 ([#911](https://github.com/googleapis/java-recaptchaenterprise/issues/911)) ([e94c7c0](https://github.com/googleapis/java-recaptchaenterprise/commit/e94c7c0ee03a2ea2035e33308c87059fdeb06499))

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
github-actions bot pushed a commit that referenced this pull request Oct 5, 2022
🤖 I have created a release *beep* *boop*
---


## [2.11.0](https://github.com/googleapis/java-securitycenter/compare/v2.10.0...v2.11.0) (2022-10-03)


### Features

* Added parent display name i.e. source display name for a finding as one of the finding attributes ([#915](https://github.com/googleapis/java-securitycenter/issues/915)) ([034d25a](https://github.com/googleapis/java-securitycenter/commit/034d25a3191ccc82dd4e9fe69124af3c24b1029f))


### Dependencies

* Update dependency cachetools to v5 ([#933](https://github.com/googleapis/java-securitycenter/issues/933)) ([5b2b39d](https://github.com/googleapis/java-securitycenter/commit/5b2b39dabf51c323316033c558efce77c2c19bf9))
* Update dependency com.google.cloud:google-cloud-bigquery to v2.16.1 ([#917](https://github.com/googleapis/java-securitycenter/issues/917)) ([58ed894](https://github.com/googleapis/java-securitycenter/commit/58ed8942ca8012cf0456bfe431d21e7d553f1fd0))
* Update dependency com.google.cloud:google-cloud-pubsub to v1.120.16 ([#913](https://github.com/googleapis/java-securitycenter/issues/913)) ([1eaf4b3](https://github.com/googleapis/java-securitycenter/commit/1eaf4b3b295ba7e248f88ef14a377d1e865ac5c3))
* Update dependency com.google.cloud:google-cloud-pubsub to v1.120.17 ([#923](https://github.com/googleapis/java-securitycenter/issues/923)) ([60d65d3](https://github.com/googleapis/java-securitycenter/commit/60d65d35a3c50f8cedeb8ef9b4db0480d667a976))
* Update dependency com.google.cloud:google-cloud-pubsub to v1.120.18 ([#924](https://github.com/googleapis/java-securitycenter/issues/924)) ([f94db64](https://github.com/googleapis/java-securitycenter/commit/f94db64c37b4e0c734ee8bd42a6d174feb2251ba))
* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.4 ([#937](https://github.com/googleapis/java-securitycenter/issues/937)) ([001091d](https://github.com/googleapis/java-securitycenter/commit/001091d1d178d81e3cec06f3847687c8905be49a))
* Update dependency com.google.protobuf:protobuf-java-util to v3.21.6 ([#914](https://github.com/googleapis/java-securitycenter/issues/914)) ([992d37a](https://github.com/googleapis/java-securitycenter/commit/992d37a4fe95b598b638d159aa86e41e324a63ff))
* Update dependency com.google.protobuf:protobuf-java-util to v3.21.7 ([#935](https://github.com/googleapis/java-securitycenter/issues/935)) ([2353016](https://github.com/googleapis/java-securitycenter/commit/23530169d5c988e30c9a1c43a0405243dd6614ad))
* Update dependency markupsafe to v2.1.1 ([#927](https://github.com/googleapis/java-securitycenter/issues/927)) ([2c42b32](https://github.com/googleapis/java-securitycenter/commit/2c42b32a1831e08a8f0f5e4e600e18ca075d5c10))
* Update dependency protobuf to v3.20.2 ([#928](https://github.com/googleapis/java-securitycenter/issues/928)) ([faf7200](https://github.com/googleapis/java-securitycenter/commit/faf72009d3deea9bd869cc6e93a08d28325f2ace))
* Update dependency protobuf to v4 ([#934](https://github.com/googleapis/java-securitycenter/issues/934)) ([19f8da3](https://github.com/googleapis/java-securitycenter/commit/19f8da31814ae8f957b142655c45cdcb5254c696))
* Update dependency pyjwt to v2.5.0 ([#929](https://github.com/googleapis/java-securitycenter/issues/929)) ([a5b8ae2](https://github.com/googleapis/java-securitycenter/commit/a5b8ae2802dfaea8745eab65fa7c4ac83ebd973e))
* Update dependency requests to v2.28.1 ([#930](https://github.com/googleapis/java-securitycenter/issues/930)) ([ca80e91](https://github.com/googleapis/java-securitycenter/commit/ca80e911c33af260892a95998d15c1dd024c67d4))
* Update dependency typing-extensions to v4.3.0 ([#931](https://github.com/googleapis/java-securitycenter/issues/931)) ([12fda13](https://github.com/googleapis/java-securitycenter/commit/12fda1317eb93337827ee03918b91d0c3cbe1a15))
* Update dependency zipp to v3.8.1 ([#932](https://github.com/googleapis/java-securitycenter/issues/932)) ([15a6c7f](https://github.com/googleapis/java-securitycenter/commit/15a6c7f01f4e6da74e037852857af1e0cceaad11))

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
github-actions bot pushed a commit to renovate-bot/google-cloud-java that referenced this pull request Oct 8, 2022
🤖 I have created a release *beep* *boop*
---


### Updating meta-information for bleeding-edge SNAPSHOT release.

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
suztomo pushed a commit that referenced this pull request Feb 1, 2023
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: compute Issues related to the Compute Engine API. cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants