-
Notifications
You must be signed in to change notification settings - Fork 289
Setting Up the Release Process #3
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
Merged
Merged
Changes from all commits
Commits
Show all changes
55 commits
Select commit
Hold shift + click to select a range
428eedb
Initial code migration:
cfbbd6a
Reformatting code according to check-style plugin conventions
hiranya911 59842b8
Code reformatting: Fixing javadoc indentation
hiranya911 fef4ecf
More reformatting: Added google check style config
hiranya911 a606833
Code formatting continued
hiranya911 1d2ed82
Code formatting continued
hiranya911 8972b1b
Reformatting
hiranya911 e5509c3
Fixed all checkstyle violations; Build configured to fail on lint errors
0587d52
Updated checkstyle config
7f2f470
Working on re-enabling the integration tests
8ee5cfc
Temporarily removing IT test cases
dbc6ee6
Extending checkstyle coverage to test sourcesw
c66f35b
Cleaned up verbose test output
f7cbdc2
Adding 2 integration tests to verify the maven integration test support
7715b90
Moving test only trampolines to the test/ subtree; Adding a removed m…
c3591ed
Fixing integration tests
hiranya911 bc54329
Added event test
hiranya911 75df20f
Added the real time test
hiranya911 471d0a9
Adding data test back
hiranya911 f692bb6
Fixed the object serialization test
hiranya911 c368248
Adding a factory method to MapBuilder
hiranya911 a30ae95
Added transaction integration test
hiranya911 7714024
Added transaction test
hiranya911 2da7955
Added rules integration test
hiranya911 094d756
Updated rules test
hiranya911 f446c79
Merge branch 'hkj-initial-code-migration' into hkj-db-integration-tests
hiranya911 952c6b0
Cleaning up the test code; Removed unnecessary utils and constants
hiranya911 594bfbb
Added more factory methods for MapBuilder; Removed unused legacy depe…
hiranya911 5dc413f
Dropped the jackson test dependency
hiranya911 738c75e
Adding release profile
5e81a8b
Ignoring some maven specific temp files
922054d
Updated pom to use release + nexus plugin combo
337299f
Loading the version numbner from a Maven-filtered resource
aa88398
Adding the initial version of contribution guide
a0ef544
Merge branch 'hkj-db-integration-tests' into hkj-release-process
8b2ff85
Inferring the DB URL from project ID
2da5b03
Fixed test race condition
a24340c
Merge branch 'hkj-db-integration-tests' into hkj-release-process
7d39734
Fixing some race conditions in ITs
5f8e82a
Merge branch 'hkj-db-integration-tests' into hkj-release-process
4b0361c
Cleaning up EventHelper instances after use
hiranya911 e5eca5c
Merge branch 'hkj-db-integration-tests' into hkj-release-process
3d3be22
Adding back some logging code; Dropping fblocal URLs
eefc4ce
Dropping all references to fblocal
d13b1ec
Merge branch 'hkj-db-integration-tests' into hkj-release-process
e911387
Removing port numbers from test URLs
3c7f98f
Separated conjunctive assertions into separate ones for better error …
hiranya911 7efbd53
Merge branch 'hkj-db-integration-tests' into hkj-release-process
hiranya911 59d1689
Merge branch 'hkj-release-process' of github.com:firebase/firebase-ad…
0dc979c
Fixing merge conflict
b47dbf6
Allowing snapshot versions in database
78fdef7
Updated contributing guide
f5883d7
Updated titles and links
21e14d6
Fixing SCM URL
e0757cd
Downgrading guava version to 20.0 since 21.0 only works on Java 8 (ht…
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,135 @@ | ||
# Contributing | Firebase Admin Java SDK | ||
|
||
Thank you for contributing to the Firebase community! | ||
|
||
- [Have a usage question?](#question) | ||
- [Think you found a bug?](#issue) | ||
- [Have a feature request?](#feature) | ||
- [Want to submit a pull request?](#submit) | ||
- [Need to get set up locally?](#local-setup) | ||
|
||
|
||
## <a name="question"></a>Have a usage question? | ||
|
||
We get lots of those and we love helping you, but GitHub is not the best place for them. Issues | ||
which just ask about usage will be closed. Here are some resources to get help: | ||
|
||
- Go through the [guides](https://firebase.google.com/docs/admin/setup/) | ||
- Read the full [API reference](https://firebase.google.com/docs/reference/admin/java/) | ||
|
||
If the official documentation doesn't help, try asking a question on the | ||
[Firebase Google Group](https://groups.google.com/forum/#!forum/firebase-talk/) or one of our | ||
other [official support channels](https://firebase.google.com/support/). | ||
|
||
**Please avoid double posting across multiple channels!** | ||
|
||
|
||
## <a name="issue"></a>Think you found a bug? | ||
|
||
Yeah, we're definitely not perfect! | ||
|
||
Search through [old issues](https://github.com/firebase/firebase-admin-java/issues) before | ||
submitting a new issue as your question may have already been answered. | ||
|
||
If your issue appears to be a bug, and hasn't been reported, | ||
[open a new issue](https://github.com/firebase/firebase-admin-java/issues/new). Please use the | ||
provided bug report template and include a minimal repro. | ||
|
||
If you are up to the challenge, [submit a pull request](#submit) with a fix! | ||
|
||
|
||
## <a name="feature"></a>Have a feature request? | ||
|
||
Great, we love hearing how we can improve our products! Share you idea through our | ||
[feature request support channel](https://firebase.google.com/support/contact/bugs-features/). | ||
|
||
|
||
## <a name="submit"></a>Want to submit a pull request? | ||
|
||
Sweet, we'd love to accept your contribution! | ||
[Open a new pull request](https://github.com/firebase/firebase-admin-java/pull/new/master) and fill | ||
out the provided template. | ||
|
||
**If you want to implement a new feature, please open an issue with a proposal first so that we can | ||
figure out if the feature makes sense and how it will work.** | ||
|
||
Make sure your changes pass our linter and the tests all pass on your local machine. | ||
Most non-trivial changes should include some extra test coverage. If you aren't sure how to add | ||
tests, feel free to submit regardless and ask us for some advice. | ||
|
||
Finally, you will need to sign our | ||
[Contributor License Agreement](https://cla.developers.google.com/about/google-individual) | ||
before we can accept your pull request. | ||
|
||
|
||
## <a name="local-setup"></a>Need to get set up locally? | ||
|
||
### Initial Setup | ||
|
||
Install Java 7 or higher. You can also use Java 8, but please note that the Firebase Admin SDK must | ||
maintain full Java 7 compatibility. Therefore make sure that you do not use any Java 8 features | ||
(e.g. lambdas) when writing code for the Admin Java SDK. | ||
|
||
We use [Apache Maven](http://maven.apache.org/) for building, testing and releasing the Admin Java | ||
SDK code. Follow the [installation guide](http://maven.apache.org/install.html), and install Maven | ||
3.3 or higher. | ||
|
||
### Running Linters | ||
|
||
[Maven Checkstyle plugin](https://maven.apache.org/plugins/maven-checkstyle-plugin/) is configured | ||
to run everytime the build is invoked. This plugin verifies source code format, and enforces a | ||
number of other Java programming best practices. Any style violations will cause the build to break. | ||
|
||
Configuration for the Checkstyle plugin can be found in the `checkstyle.xml` file at the root of the | ||
repository. To execute only the linter without rest of the build pipeline, execute the following | ||
command: | ||
|
||
``` | ||
mvn validate | ||
``` | ||
|
||
If you are using Eclipse for development, you can install the | ||
[Eclipse Checkstyle plugin](http://eclipse-cs.sourceforge.net/#!/), and import the `checkstyle.xml` | ||
file into the IDE. This enables you to have the linter constantly checking your code as you develop. | ||
A similar [plugin](https://plugins.jetbrains.com/plugin/1065-checkstyle-idea) is available for | ||
IntelliJ IDEA as well. | ||
|
||
### Unit Testing | ||
|
||
Tests are implemented using the [Junit4](http://junit.org/junit4/) framework, and are housed under | ||
the `src/test` subdirectory. They get executed as part of the build, and test failures will cause | ||
the build to break. To run the unit tests without the rest of the build pipeline, execute the | ||
following command: | ||
|
||
``` | ||
mvn test | ||
``` | ||
|
||
### Integration Testing | ||
|
||
Integration tests are also written using Junit4. They coexist with the unit tests in the `src/test` | ||
subdirectory. Integration tests follow the naming convention `*IT.java` (e.g. `DataTestIT.java`), | ||
which enables the Maven Surefire and Failsafe plugins to differentiate between the two types of | ||
tests. Integration tests are executed against a real life Firebase project, and therefore | ||
requires an Internet connection. Create a new project in the | ||
[Firebase console](https://console.firebase.google.com/) if you do not already have one. Use a | ||
separate, dedicated project for integration tests since the test suite makes a large number of | ||
writes to the Firebase realtime database. Download the service account private key from the | ||
"Settings" page of the project. Now run the following command to invoke the integration test suite: | ||
|
||
``` | ||
mvn verify -Dfirebase.it.certificate=path/to/your/serviceAccount.json | ||
``` | ||
|
||
Make sure to specify the correct path to your downloaded service account key file as the | ||
`firebase.it.certificate` system property. | ||
|
||
The above command invokes both unit and integration test suites. To execute only the integration | ||
tests, run the command as follows: | ||
|
||
``` | ||
mvn verify -Dfirebase.it.certificate=path/to/your/serviceAccount.json -Dskip.surefire.tests=true | ||
``` | ||
|
||
|
||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,5 @@ target/ | |
*.iml | ||
.classpath | ||
.project | ||
.checkstyle | ||
release.properties |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
sdk.version=${project.version} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did we step back to an older version of Guava?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. As it turns out 21.0 only works on Java 8. Their documentation recommends using 20.0 for Java 7 compatibility: https://github.com/google/guava/wiki/Release21