Giter Site home page Giter Site logo

repo-crawler's Introduction

Build Status

Repository and revision crawler for Teamwork Cloud

Run the crawler

  1. Download twc.repo-crawler-<version>-all.jar from GitHub releases
  2. java -jar twc.repo-crawler-<version>-all.jar <args> with arguments (see below)

Example arguments

Running the jar without arguments prints out the usage instructions.

  • Running the crawler without workspace, resource, branch, and revision will result in crawling the repository structure of the given scope
  • Running the crawler with workspace, resource, branch, and revision will result in crawling the model content of the given revision

Repository structure of OpenSE Cookbook workspace on twc.openmbee.org

-S twc.openmbee.org -P 8111 -ssl -W 9c368adc-10cc-45d9-bec6-27aedc80e68b -C 2000 -u openmbeeguest -pw guest

OpenSE Cookbook model on twc.openmbee.org

-S twc.openmbee.org -P 8111 -ssl -W 9c368adc-10cc-45d9-bec6-27aedc80e68b -R c6bede89-cd5e-487b-aca8-a4f384370759 -B 29110c0f-bdc1-4294-ae24-9fd608629cac -REV 350 -C 2000 -u openmbeeguest -pw guest

TMT on twc.openmbee.org

-S twc.openmbee.org -P 8111 -ssl -W 9c368adc-10cc-45d9-bec6-27aedc80e68b -R 6819171d-1f52-4792-a08d-15d50d47985a -B a95e8bd1-f7d2-433e-a0a1-0c1cd7702e59 -REV 229 -C 2000 -u openmbeeguest -pw guest

Configuring self-signed certificate when using SSL on Teamwork Cloud OSMC API

  • Java has to start with -Djavax.net.ssl.trustStore=<path to JKS file> -Djavax.net.ssl.trustStorePassword=<password of JKS file>
    • Note: These are JVM parameters that should be added before the -jar part
    • You can add -Djavax.net.debug=all to check whether Java loaded the certificate correctly
  • Make sure that ssl is enabled in CLI arguments

Running from source

  1. Clone this repository or download the sources for a release.

IntelliJ IDEA

  1. Install IntelliJ IDEA with Kotlin plugin.
  2. Open IntelliJ IDEA and open project. File -> Open.. -> <project_path> (Select Gradle if needed.)
  3. Build -> Build Project
  4. Run -> Run... -> com.incquerylabs.twc.repo.crawler.Crawler.kt (set arguments in Configuration)

Gradle

  1. ./gradlew run --args='<args>' with arguments (see above)

Shadow Jar

  1. ./gradlew shadowJar
  2. java -jar build/libs/twc.repo-crawler-<version>-all.jar <args> with arguments (see above)

repo-crawler's People

Contributors

abelhegedus avatar beothy avatar fuzesimate avatar pappist avatar ujhelyiz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

mktiti gabor-one

repo-crawler's Issues

Support reading configuration from file instead of command line

When the repo crawler is executed without parameters, look for a file called config.json in the working directory and parse it instead of getting command line parameters.

The configuration file should contain at least the required fields for the current version (e.g. username, password, server, port, etc.).

Refactor crawling to retrieve several elements at once

TWC provides a method to download elements at once. Issue POST request to /elements, i.e., /osmc/resources//revisions//elements, /osmc/resources//branches//elements. The request body is a list of UUID separated by commas, e.g., 4eeb2e6d-9cbc-4f59-9d74-69263e52ba54,520bc74d-b5b4-40d5-87cb-9d0b8aba5d2e,7a057ae7-6281-462d-9dcd-de9931633f5c and the Content-Type in the request header should be “text/plain”.

Print name of workspaces, resources, branches when crawling repository structure

We should improve repo-crawler in a way that helps users select a revision to test. This can be done in several ways:

  • Print the label/name of visited structure elements to standard output when receiving this information
  • Store the structure information in-memory and save it to a file at the end of the execution
  • Stream structure information to a file while running

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.