{"id":15992658,"url":"https://github.com/pmlopes/sogeti-gurunight-2015","last_synced_at":"2026-06-13T12:03:10.221Z","repository":{"id":142726133,"uuid":"46332182","full_name":"pmlopes/sogeti-gurunight-2015","owner":"pmlopes","description":null,"archived":false,"fork":false,"pushed_at":"2015-11-17T12:38:41.000Z","size":41178,"stargazers_count":0,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-25T17:36:59.526Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pmlopes.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-11-17T08:07:25.000Z","updated_at":"2015-11-17T12:38:42.000Z","dependencies_parsed_at":"2023-04-23T07:53:39.214Z","dependency_job_id":null,"html_url":"https://github.com/pmlopes/sogeti-gurunight-2015","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/pmlopes/sogeti-gurunight-2015","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmlopes%2Fsogeti-gurunight-2015","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmlopes%2Fsogeti-gurunight-2015/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmlopes%2Fsogeti-gurunight-2015/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmlopes%2Fsogeti-gurunight-2015/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pmlopes","download_url":"https://codeload.github.com/pmlopes/sogeti-gurunight-2015/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmlopes%2Fsogeti-gurunight-2015/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34283391,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-13T02:00:06.617Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-08T06:40:29.700Z","updated_at":"2026-06-13T12:03:10.200Z","avatar_url":"https://github.com/pmlopes.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# vert.x micro-service workshop\n\nIn this workshop, you are going to develop a micro-service application called _vert2go_. This workshop covers:\n\n* how to build micro-services with vert.x\n* how you can use the event bus to bind your micro-services\n* how to consume a REST API\n* how to build an application using several persistence technologies\n* how to provide a REST API, and build proxies\n* how to deploy some micro-service to Openshift\n* how to centralize your logs\n* how to deploy a vert.x micro-service in a docker container\n* how to monitor your application\n\nThe _vert2go_ application is a recommendation application where users can rates the place they like.\n\nThe slides for the talk are [online](http://pmlopes.github.io/sogeti-gurunight-2015/).\n\n**Prerequisites:**\n\n* Java 8 (JDK)\n* Git\n* Apache Maven\n* Docker (or docker-machine)\n* An IDE\n* RoboMongo (optional)\n\n\n## Using docker machine\n\nDocker runs natively on Linux. Because the Docker daemon uses Linux-specific kernel features, you can’t run Docker \nnatively in OS X or Windows. Instead, you must use docker-machine to create and attach to a virtual machine (VM). This\n machine is a Linux VM that hosts Docker for you on your Mac or Windows. If you are on Mac OS X or Windows, you can use \n docker via docker machine (https://docs.docker.com/machine/).\n\n1. Install docker and docker-machine from https://www.docker.com/docker-toolbox. Installation instructions are there: http://docs.docker.com/mac/step_one/\n2. Once done run `docker run hello-world` to verify your installation \n  \nThe installation process will create a VM that has a minimal linux to run docker.\n\n## Components\n\n### Data Storage Service\n\nThis service shows how to connect to a mongodb database and genereate a API interface that will generate bindings for\nthe 2 languages used across the demo, groovy and javascript.\n\n```\ncd data-storage-service\nmvn clean package\njava -jar target/data-storage-service-1.0-SNAPSHOT-fat.jar --cluster --conf=src/conf/config.json\n```\n\n### Data Provisioning\n\nThis REST consumer will consume a REST service and populate the mongo collection directly it does not need to be part of\na cluster\n\n```\ncd data-provisioning\nmvn clean package\njava -jar target/data-provisioning-1.0-SNAPSHOT-fat.jar --conf=src/conf/config.json\n```\n\n### Data Storage Client\n\nThis is a simple client written in `Groovy` that show the usage of service proxies generated from the `data storage\nservice`. Since this client has no knowledge on mongo and uses a proxy it needs to be part of the cluster to find where\nto delegate the the action from the proxy.\n\n```\ncd data-storage-client\nmvn clean package\njava -jar target/data-provisioning-1.0-SNAPSHOT-fat.jar --cluster\n```\n\n### Frontend\n\nThis is the web part of the application it will show the usage of the `sockjs` bridge and that generated proxies can be\nconsumed also from the browser. This part of the code show that a `Verticle` can be written in `javascript`.\n\n```\ncd frontend\nmvn clean package\njava -jar target/frontend-1.0-SNAPSHOT-fat.jar --cluster\n```\n\n### Map Render Service\n\nThis component show a part of the application that can be deployed on the cloud and we will consume its service using\nREST. It works as the other components but since we are deploying it on [OpenShift](http://www.openshift.com) there are\na few extra steps.\n\nFor the first time we need to create an app:\n\n```\nrhc create-app map0render0service https://raw.githubusercontent.com/vert-x3/vertx-openshift-cartridge/master/metadata/manifest.yml\n```\n\nAnd then\n\n```\ncd frontend\nmvn clean package\n\ncd openshift\ngit add -A\ngit commit -m \"deploy my application\"\ngit push\n```\n\n### Map Render Proxy\n\nWe will consume the map service as a local proxy and add caching headers this we will deploy on `Docker`.\n\n```\ncd map-server-proxy\nmvn clean install\nmvn docker:build\nmvn docker:start\n```\n\nIf one refreshes the frontend javascript application the map should start showing on the right side of the screen.\n\n### Recommendation Service\n\nThis shows again how to connect to `redis` and use `pub/sub` mode to pubish votes if one opens 2 browsers and clicks on\none restaurant and votes the counters should update in realtime on both web clients.\n\n```\ncd recommendation-service\nmvn clean package\njava -jar target/recommendation-service-1.0-SNAPSHOT-fat.jar --cluster --conf=src/conf/config.json\n```\n\n## Extras\n\n### Centralized logging\n\nreplace the jul configuration content on `data-storage-service` with the example on `etc` and add the `GELF` dependency\nto the `pom.xml`.\n\nStart `graylog2` and enable the UDP transport.\n\nRebuild and restart the service\n\n```\ncd data-storage-service\nmvn clean package\njava -jar target/data-storage-service-1.0-SNAPSHOT-fat.jar --cluster --conf=src/conf/config.json\n```\n\nUsing the client or the web browser load some data, the logs should now be collected in a `graylog` server.\n\n### Metrics\n\n#### Hawkular\n\nStart the server see the scripts folder. Add a bridge to hawkular to the deployment\n\n```\ncd eventbus-to-hawkular-bridge\nmvn clean package\njava -jar target/eventbus-to-hawkular-bridge-1.0-SNAPSHOT-fat.jar --cluster --conf=src/conf/config.json\n```\n\nRunning some queries to the data storage service should generate some metrics to be called.\n\n#### Grafana\n\nStart grafana (see scripts) Add a connection use `Influx 0.8` and connect to the hawkular server, then add a graph to\nthe dashboard using the name `vertx2go.metrics` and you should start seeing the average requests metrics in a visual\nform.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpmlopes%2Fsogeti-gurunight-2015","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpmlopes%2Fsogeti-gurunight-2015","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpmlopes%2Fsogeti-gurunight-2015/lists"}