Skip to content

Commit 1d0d06e

Browse files
BenFradetbenjben
authored andcommitted
Move the java-scala codebase to their own repositories (closes #200)
1 parent ba692b6 commit 1d0d06e

File tree

26 files changed

+4
-9508
lines changed

26 files changed

+4
-9508
lines changed

.travis.yml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,3 @@
1-
language: scala
2-
scala:
3-
- 2.11.11
4-
- 2.12.4
5-
jdk:
6-
- oraclejdk8
7-
- openjdk8
1+
language: ruby
82
script:
93
- ruby -e "require 'yaml'; YAML.load_file('resources/referers.yml')"
10-
- cd java-scala && sbt test

README.md

Lines changed: 3 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
# referer-parser
22

3-
Java/Scala: [![Build Status](https://travis-ci.org/snowplow/referer-parser.png)](https://travis-ci.org/snowplow/referer-parser)
4-
53
referer-parser is a database for extracting marketing attribution data (such as search terms) from referer URLs, inspired by the [ua-parser][ua-parser] project (an equivalent library for user agent parsing).
64

75
The referer-parser project also contains multiple libraries for working with the referer-parser database in different languages.
@@ -22,80 +20,13 @@ https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-pa
2220

2321
If there is an issue with the database necessitating a re-release within the month, the corresponding files will be overwritten.
2422

25-
## Maintainers
26-
27-
* Java/Scala: [Snowplow Analytics Ltd][snowplow-analytics]
28-
* node.js (JavaScript): [Martin Katrenik][mkatrenik]
29-
* .NET (C#): [Sepp Wijnands][swijnands] at [iPerform Software][iperform]
30-
* Go: [Thomas Sileo][tsileo]
31-
* Erlang [Silviu Caragea][silviucpp]
32-
* `referers.yml`: [Snowplow Analytics][snowplow-analytics]
33-
34-
## Usage: Java
35-
36-
The Java version of this library uses the updated API, and identifies search, social, webmail, internal and unknown referers:
37-
38-
```java
39-
import com.snowplowanalytics.refererparser.Parser;
40-
41-
...
42-
43-
String refererUrl = "http://www.google.com/search?q=gateway+oracle+cards+denise+linn&hl=en&client=safari";
44-
String pageUrl = "http://www.psychicbazaar.com/shop"; // Our current URL
45-
46-
Parser refererParser = new Parser();
47-
Referer r = refererParser.parse(refererUrl, pageUrl);
48-
49-
System.out.println(r.medium); // => "search"
50-
System.out.println(r.source); // => "Google"
51-
System.out.println(r.term); // => "gateway oracle cards denise linn"
52-
```
53-
54-
For more information, please see the Java/Scala [README][java-scala-readme].
55-
5623
## Usage: Scala
5724

58-
The Scala version of this library uses the updated API, and identifies search, social, webmail, internal and unknown referers:
59-
60-
```scala
61-
val refererUrl = "http://www.google.com/search?q=gateway+oracle+cards+denise+linn&hl=en&client=safari"
62-
val pageUrl = "http://www.psychicbazaar.com/shop" // Our current URL
63-
64-
import com.snowplowanalytics.refererparser.scala.Parser
65-
for (r <- Parser.parse(refererUrl, pageUrl)) {
66-
println(r.medium) // => "search"
67-
for (s <- r.source) {
68-
println(s) // => "Google"
69-
}
70-
for (t <- r.term) {
71-
println(t) // => "gateway oracle cards denise linn"
72-
}
73-
}
74-
```
25+
Check out the dedicated repository: https://github.com/snowplow-referer-parser/scala-referer-parser
7526

76-
You can also provide a list of domains which should be considered internal:
77-
78-
```scala
79-
val refererUrl = "http://www.subdomain1.snowplowanalytics.com"
80-
val pageUrl = "http://www.snowplowanalytics.com"
81-
val internalDomains = List(
82-
"www.subdomain1.snowplowanalytics.com", "www.subdomain2.snowplowanalytics.com"
83-
)
84-
85-
import com.snowplowanalytics.refererparser.scala.Parser
86-
87-
for (r <- Parser.parse(refererUrl, pageUrl, internalDomains)) {
88-
println(r.medium) // => "internal"
89-
for (s <- r.source) {
90-
println(s) // => null
91-
}
92-
for (t <- r.term) {
93-
println(t) // => null
94-
}
95-
}
96-
```
27+
## Usage: Java
9728

98-
For more information, please see the Java/Scala [README][java-scala-readme].
29+
Check out the dedicated repository: https://github.com/snowplow-referer-parser/java-referer-parser
9930

10031
## Usage: Ruby
10132

@@ -196,16 +127,8 @@ You can contact the Snowplow Analytics team through any of the [channels listed
196127

197128
`referers.yml` is based on [Piwik's][piwik] [`SearchEngines.php`][piwik-search-engines] and [`Socials.php`][piwik-socials], copyright 2012 Matthieu Aubry and available under the [GNU General Public License v3][gpl-license].
198129

199-
The Java/Scala port is copyright 2012-2014 [Snowplow Analytics Ltd][snowplow-analytics] and is available under the [Apache License, Version 2.0][apache-license].
200-
201130
The node.js (JavaScript) port is copyright 2013-2014 [Martin Katrenik][mkatrenik] and is available under the [Apache License, Version 2.0][apache-license].
202131

203-
The .NET (C#) port is copyright 2013-2014 [iPerform Software][iperform] and is available under the [Apache License, Version 2.0][apache-license].
204-
205-
The Go port is copyright 2014 [Thomas Sileo][tsileo] and is available under the [MIT License][mit-license].
206-
207-
The Erlang port is copyright 2017 [Silviu Caragea][silviucpp] and is available under the [MIT License][mit-license].
208-
209132
[ua-parser]: https://github.com/tobie/ua-parser
210133

211134
[snowplow]: https://github.com/snowplow/snowplow
@@ -224,7 +147,6 @@ The Erlang port is copyright 2017 [Silviu Caragea][silviucpp] and is available u
224147
[piwik-socials]: https://github.com/piwik/piwik/blob/master/core/DataFiles/Socials.php
225148

226149
[ruby-readme]: https://github.com/snowplow/referer-parser/blob/master/ruby/README.md
227-
[java-scala-readme]: https://github.com/snowplow/referer-parser/blob/master/java-scala/README.md
228150
[python-readme]: https://github.com/snowplow/referer-parser/blob/master/python/README.md
229151
[nodejs-readme]: https://github.com/snowplow/referer-parser/blob/master/nodejs/README.md
230152
[php-readme]: https://github.com/snowplow/referer-parser/blob/master/php/README.md

java-scala/.gitignore

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

java-scala/CHANGELOG

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

java-scala/LICENSE-2.0.txt

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

0 commit comments

Comments
 (0)