Skip to content

Commit 593ff35

Browse files
authored
Merge pull request #21 from delphi-hub/develop
Merging 'Develop'
2 parents 989e425 + 59c21b6 commit 593ff35

File tree

3 files changed

+176
-1
lines changed

3 files changed

+176
-1
lines changed

README.md

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# Delphi Web API
2+
3+
The web API implementation for the Delphi platform.
4+
5+
We are currently in pre-alpha state! There is no release and the code in
6+
this repository is purely experimental!
7+
8+
|branch | status | codacy | snyk |
9+
| :---: | :---: | :---: | :---: |
10+
| master | [![Build Status](https://travis-ci.org/delphi-hub/delphi-webapi.svg?branch=master)](https://travis-ci.org/delphi-hub/delphi-webapi) | [![Codacy Badge](https://api.codacy.com/project/badge/Grade/8ebe27850ffb4139af6280fd1cd6d540)](https://www.codacy.com/app/delphi-hub/delphi-webapi?utm_source=github.com&utm_medium=referral&utm_content=delphi-hub/delphi-webapi&utm_campaign=Badge_Grade)| [![Known Vulnerabilities](https://snyk.io/test/github/delphi-hub/delphi-webapi/badge.svg?targetFile=build.sbt)](https://snyk.io/test/github/delphi-hub/delphi-webapi/?targetFile=build.sbt) |
11+
| develop | [![Build Status](https://travis-ci.org/delphi-hub/delphi-webapi.svg?branch=develop)](https://travis-ci.org/delphi-hub/delphi-webapi) | [![Codacy Badge](https://api.codacy.com/project/badge/Grade/8ebe27850ffb4139af6280fd1cd6d540?branch=develop)](https://www.codacy.com/app/delphi-hub/delphi-webapi?branch=develop&utm_source=github.com&utm_medium=referral&utm_content=delphi-hub/delphi-webapi&utm_campaign=Badge_Grade) | [![Known Vulnerabilities](https://snyk.io/test/github/delphi-hub/delphi-webapi/develop/badge.svg?targetFile=build.sbt)](https://snyk.io/test/github/delphi-hub/delphi-webapi/develop/?targetFile=build.sbt) |
12+
13+
## What is the Delphi Web API?
14+
15+
It is the primary access point to the Delphi system.
16+
17+
## How does it work?
18+
19+
The Delphi Web API communicates with the underlying Elasticsearch database to provide access to data.
20+
21+
## How can I use it?
22+
23+
If you just wish to query the results, maybe the public instance at https://delphi.cs.uni-paderborn.de is the right choice for you.
24+
25+
If you want to run your own infrastructure, you can start the web API
26+
```
27+
sbt run
28+
```
29+
30+
It expects a running instance of elasticsearch on port 9200 on the same machine.
31+
32+
## Community
33+
34+
Feel welcome to join our chatroom on Gitter: [![Join the chat at https://gitter.im/delphi-hub/delphi](https://badges.gitter.im/delphi-hub/delphi.svg)](https://gitter.im/delphi-hub/delphi?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
35+
36+
37+
## Contributing
38+
39+
Contributions are *very* welcome!
40+
41+
Before contributing, please read our [Code of Conduct](CODE_OF_CONDUCT.md).
42+
43+
Refer to the [Contribution Guide](CONTRIBUTING.md) for details about the workflow.
44+
We use Pull Requests to collect contributions. Especially look out for "help wanted" issues
45+
[![GitHub issues by-label](https://img.shields.io/github/issues/delphi-hub/delphi-webapi/help%20wanted.svg)](https://github.com/delphi-hub/delphi-webapi/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22),
46+
but feel free to work on other issues as well.
47+
You can ask for clarification in the issues directly, or use our Gitter
48+
chat for a more interactive experience.
49+
50+
[![GitHub issues](https://img.shields.io/github/issues/delphi-hub/delphi-webapi.svg)](https://github.com/delphi-hub/delphi-webapi/issues)
51+
52+
53+
## License
54+
55+
The Delphi Web API is open source and available under Apache 2 License.
56+
57+
[![GitHub license](https://img.shields.io/github/license/delphi-hub/delphi-webapi.svg)](https://github.com/delphi-hub/delphi-webapi/blob/master/LICENSE)

build.sbt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ libraryDependencies ++= Seq(
3232
lazy val webapi = (project in file(".")).
3333
enablePlugins(JavaAppPackaging).
3434
enablePlugins(DockerPlugin).
35+
enablePlugins(ScalastylePlugin).
3536
settings (
3637
dockerBaseImage := "openjdk:jre-alpine"
3738
).
@@ -42,4 +43,4 @@ lazy val webapi = (project in file(".")).
4243
buildInfoPackage := "de.upb.cs.swt.delphi.webapi"
4344
)
4445

45-
scalastyleConfig := baseDirectory.value / "project" / "scalastyle_config.xml"
46+
scalastyleConfig := baseDirectory.value / "project" / "scalastyle-config.xml"

project/scalastyle-config.xml

Lines changed: 117 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
<scalastyle>
2+
<name>Scalastyle standard configuration</name>
3+
<check level="warning" class="org.scalastyle.file.FileTabChecker" enabled="true"></check>
4+
<check level="warning" class="org.scalastyle.file.FileLengthChecker" enabled="true">
5+
<parameters>
6+
<parameter name="maxFileLength"><![CDATA[800]]></parameter>
7+
</parameters>
8+
</check>
9+
<check level="warning" class="org.scalastyle.file.HeaderMatchesChecker" enabled="true">
10+
<parameters>
11+
<parameter name="header"><![CDATA[// Copyright (C) 2011-2012 the original author or authors.
12+
// See the LICENCE.txt file distributed with this work for additional
13+
// information regarding copyright ownership.
14+
//
15+
// Licensed under the Apache License, Version 2.0 (the "License");
16+
// you may not use this file except in compliance with the License.
17+
// You may obtain a copy of the License at
18+
//
19+
// http://www.apache.org/licenses/LICENSE-2.0
20+
//
21+
// Unless required by applicable law or agreed to in writing, software
22+
// distributed under the License is distributed on an "AS IS" BASIS,
23+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
24+
// See the License for the specific language governing permissions and
25+
// limitations under the License.]]></parameter>
26+
</parameters>
27+
</check>
28+
<check level="warning" class="org.scalastyle.scalariform.SpacesAfterPlusChecker" enabled="true"></check>
29+
<check level="warning" class="org.scalastyle.file.WhitespaceEndOfLineChecker" enabled="true"></check>
30+
<check level="warning" class="org.scalastyle.scalariform.SpacesBeforePlusChecker" enabled="true"></check>
31+
<check level="warning" class="org.scalastyle.file.FileLineLengthChecker" enabled="true">
32+
<parameters>
33+
<parameter name="maxLineLength"><![CDATA[160]]></parameter>
34+
<parameter name="tabSize"><![CDATA[4]]></parameter>
35+
</parameters>
36+
</check>
37+
<check level="warning" class="org.scalastyle.scalariform.ClassNamesChecker" enabled="true">
38+
<parameters>
39+
<parameter name="regex"><![CDATA[[A-Z][A-Za-z]*]]></parameter>
40+
</parameters>
41+
</check>
42+
<check level="warning" class="org.scalastyle.scalariform.ObjectNamesChecker" enabled="true">
43+
<parameters>
44+
<parameter name="regex"><![CDATA[[A-Z][A-Za-z]*]]></parameter>
45+
</parameters>
46+
</check>
47+
<check level="warning" class="org.scalastyle.scalariform.PackageObjectNamesChecker" enabled="true">
48+
<parameters>
49+
<parameter name="regex"><![CDATA[^[a-z][A-Za-z]*$]]></parameter>
50+
</parameters>
51+
</check>
52+
<check level="warning" class="org.scalastyle.scalariform.EqualsHashCodeChecker" enabled="true"></check>
53+
<check level="warning" class="org.scalastyle.scalariform.IllegalImportsChecker" enabled="true">
54+
<parameters>
55+
<parameter name="illegalImports"><![CDATA[sun._,java.awt._]]></parameter>
56+
</parameters>
57+
</check>
58+
<check level="warning" class="org.scalastyle.scalariform.ParameterNumberChecker" enabled="true">
59+
<parameters>
60+
<parameter name="maxParameters"><![CDATA[8]]></parameter>
61+
</parameters>
62+
</check>
63+
<check level="warning" class="org.scalastyle.scalariform.MagicNumberChecker" enabled="true">
64+
<parameters>
65+
<parameter name="ignore"><![CDATA[-1,0,1,2,3]]></parameter>
66+
</parameters>
67+
</check>
68+
<check level="warning" class="org.scalastyle.scalariform.NoWhitespaceBeforeLeftBracketChecker" enabled="true"></check>
69+
<check level="warning" class="org.scalastyle.scalariform.NoWhitespaceAfterLeftBracketChecker" enabled="true"></check>
70+
<check level="warning" class="org.scalastyle.scalariform.ReturnChecker" enabled="true"></check>
71+
<check level="warning" class="org.scalastyle.scalariform.NullChecker" enabled="true"></check>
72+
<check level="warning" class="org.scalastyle.scalariform.NoCloneChecker" enabled="true"></check>
73+
<check level="warning" class="org.scalastyle.scalariform.NoFinalizeChecker" enabled="true"></check>
74+
<check level="warning" class="org.scalastyle.scalariform.CovariantEqualsChecker" enabled="true"></check>
75+
<check level="warning" class="org.scalastyle.scalariform.StructuralTypeChecker" enabled="true"></check>
76+
<check level="warning" class="org.scalastyle.file.RegexChecker" enabled="true">
77+
<parameters>
78+
<parameter name="regex"><![CDATA[println]]></parameter>
79+
</parameters>
80+
</check>
81+
<check level="warning" class="org.scalastyle.scalariform.NumberOfTypesChecker" enabled="true">
82+
<parameters>
83+
<parameter name="maxTypes"><![CDATA[30]]></parameter>
84+
</parameters>
85+
</check>
86+
<check level="warning" class="org.scalastyle.scalariform.CyclomaticComplexityChecker" enabled="true">
87+
<parameters>
88+
<parameter name="maximum"><![CDATA[10]]></parameter>
89+
</parameters>
90+
</check>
91+
<check level="warning" class="org.scalastyle.scalariform.UppercaseLChecker" enabled="true"></check>
92+
<check level="warning" class="org.scalastyle.scalariform.SimplifyBooleanExpressionChecker" enabled="true"></check>
93+
<check level="warning" class="org.scalastyle.scalariform.IfBraceChecker" enabled="true">
94+
<parameters>
95+
<parameter name="singleLineAllowed"><![CDATA[true]]></parameter>
96+
<parameter name="doubleLineAllowed"><![CDATA[false]]></parameter>
97+
</parameters>
98+
</check>
99+
<check level="warning" class="org.scalastyle.scalariform.MethodLengthChecker" enabled="true">
100+
<parameters>
101+
<parameter name="maxLength"><![CDATA[50]]></parameter>
102+
</parameters>
103+
</check>
104+
<check level="warning" class="org.scalastyle.scalariform.MethodNamesChecker" enabled="true">
105+
<parameters>
106+
<parameter name="regex"><![CDATA[^[a-z][A-Za-z0-9]*$]]></parameter>
107+
</parameters>
108+
</check>
109+
<check level="warning" class="org.scalastyle.scalariform.NumberOfMethodsInTypeChecker" enabled="true">
110+
<parameters>
111+
<parameter name="maxMethods"><![CDATA[30]]></parameter>
112+
</parameters>
113+
</check>
114+
<check level="warning" class="org.scalastyle.scalariform.PublicMethodsHaveTypeChecker" enabled="true"></check>
115+
<check level="warning" class="org.scalastyle.file.NewLineAtEofChecker" enabled="true"></check>
116+
<check level="warning" class="org.scalastyle.file.NoNewLineAtEofChecker" enabled="false"></check>
117+
</scalastyle>

0 commit comments

Comments
 (0)