Skip to content

Commit f1c9f3e

Browse files
committed
---
yaml --- r: 3667 b: refs/heads/pubsub-alpha c: 736b6e1 h: refs/heads/master i: 3665: 965b4b0 3663: cbd38f8
1 parent ce58e45 commit f1c9f3e

8 files changed

Lines changed: 778 additions & 2 deletions

File tree

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 36a62ef856d199f8efd09501b5ba65c422c01f23
33
refs/heads/travis: e21ee7b88a5edc3f3d8c71f90c3fc32abf7e8dd6
44
refs/heads/gh-pages: 7406918e071dd2c5677a638ae2a06e7592b6542c
5-
refs/heads/pubsub-alpha: baee7d70fd9aa93d6f95b9ce8850ada77e2ccc7f
5+
refs/heads/pubsub-alpha: 736b6e127032f8f77bb06c0920e6d8a19bc7ec12
66
refs/heads/update-datastore: 47aae517c2cb33f1dccd909adaced73ec9d0f4df
77
refs/tags/0.0.9: 22f1839238f66c39e67ed4dfdcd273b1ae2e8444
88
refs/tags/v0.0.10: 207ebd2a3472fddee69fe1298eb90429e3306efd

branches/pubsub-alpha/gcloud-java-dns/src/main/java/com/google/gcloud/dns/DnsOptions.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,14 @@ public static Builder builder() {
9696
return new Builder();
9797
}
9898

99+
/**
100+
* Creates a default instance of {@code DnsOptions} with the project ID and credentials inferred
101+
* from the environment.
102+
*/
103+
public static DnsOptions defaultInstance() {
104+
return builder().build();
105+
}
106+
99107
@Override
100108
public boolean equals(Object obj) {
101109
return obj instanceof DnsOptions && baseEquals((DnsOptions) obj);

branches/pubsub-alpha/gcloud-java-examples/README.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,14 +63,30 @@ To run examples from your command line:
6363
```
6464
6565
* Here's an example run of `DatastoreExample`.
66-
66+
6767
Be sure to change the placeholder project ID "your-project-id" with your own project ID. Also note that you have to enable the Google Cloud Datastore API on the [Google Developers Console][developers-console] before running the following commands.
6868
```
6969
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.datastore.DatastoreExample" -Dexec.args="your-project-id my_name add my\ comment"
7070
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.datastore.DatastoreExample" -Dexec.args="your-project-id my_name display"
7171
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.datastore.DatastoreExample" -Dexec.args="your-project-id my_name delete"
7272
```
7373
74+
* Here's an example run of `DnsExample`.
75+
76+
Note that you have to enable the Google Cloud DNS API on the [Google Developers Console][developers-console] before running the following commands.
77+
You will need to replace the domain name `elaborateexample.com` with your own domain name with [verified ownership] (https://www.google.com/webmasters/verification/home).
78+
Also, note that the example creates and deletes DNS records of type A only. Operations with other record types are not implemented in the example.
79+
```
80+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="create some-sample-zone elaborateexample.com. description"
81+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="list"
82+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="list some-sample-zone records"
83+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="add-record some-sample-zone www.elaborateexample.com. 12.13.14.15 69"
84+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="get some-sample-zone"
85+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="delete-record some-sample-zone www.elaborateexample.com. 12.13.14.15 69"
86+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="list some-sample-zone changes ascending"
87+
mvn exec:java -Dexec.mainClass="com.google.gcloud.examples.dns.DnsExample" -Dexec.args="delete some-sample-zone"
88+
```
89+
7490
* Here's an example run of `ResourceManagerExample`.
7591
7692
Be sure to change the placeholder project ID "your-project-id" with your own globally unique project ID.

0 commit comments

Comments
 (0)