Skip to content
Snippets Groups Projects
Commit 74f5a182 authored by IsolatedSushi's avatar IsolatedSushi
Browse files

Initial

parent 28644366
No related branches found
No related tags found
1 merge request!14Added local projector with python and QT
{"partitions":[{"topic": "testPointData", "partition":0,"offset":-1}]}
\ No newline at end of file
import kafka
import faker
from kafka import KafkaProducer
import json
import time
import random
def json_serializer(data):
return json.dumps(data).encode("utf-8")
pointID = 0
def generatePoint():
global pointID
pointID += 1
x = random.randrange(0,100)
y = random.randrange(0,100)
return {"id": pointID,"x":x,"y":y}
producer = KafkaProducer(bootstrap_servers=['localhost:9092'],value_serializer=json_serializer)
topicName = "testPointData"
if __name__ == "__main__":
while True:
point = generatePoint()
producer.send(topicName,point)
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/../.." vcs="Git" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="BranchesTreeState">
<expand>
<path>
<item name="ROOT" type="e8cecc67:BranchNodeDescriptor" />
<item name="LOCAL_ROOT" type="e8cecc67:BranchNodeDescriptor" />
</path>
<path>
<item name="ROOT" type="e8cecc67:BranchNodeDescriptor" />
<item name="REMOTE_ROOT" type="e8cecc67:BranchNodeDescriptor" />
</path>
<path>
<item name="ROOT" type="e8cecc67:BranchNodeDescriptor" />
<item name="REMOTE_ROOT" type="e8cecc67:BranchNodeDescriptor" />
<item name="GROUP_NODE:origin" type="e8cecc67:BranchNodeDescriptor" />
</path>
</expand>
<select />
</component>
<component name="ChangeListManager">
<list default="true" id="11b77ae2-54d1-42ba-ad07-493b394675af" name="Default Changelist" comment="" />
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
<option name="LAST_RESOLUTION" value="IGNORE" />
</component>
<component name="Git.Settings">
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$/../.." />
</component>
<component name="ProjectId" id="1pFfq5wZC1dlGgLwTqVOMGFURV7" />
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
<component name="ProjectViewState">
<option name="hideEmptyMiddlePackages" value="true" />
<option name="showLibraryContents" value="true" />
</component>
<component name="PropertiesComponent">
<property name="RunOnceActivity.OpenProjectViewOnStart" value="true" />
</component>
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
<component name="TaskManager">
<task active="true" id="Default" summary="Default task">
<changelist id="11b77ae2-54d1-42ba-ad07-493b394675af" name="Default Changelist" comment="" />
<created>1614783947035</created>
<option name="number" value="Default" />
<option name="presentableId" value="Default" />
<updated>1614783947035</updated>
</task>
<servers />
</component>
<component name="Vcs.Log.Tabs.Properties">
<option name="TAB_STATES">
<map>
<entry key="MAIN">
<value>
<State />
</value>
</entry>
</map>
</option>
</component>
<component name="WindowStateProjectService">
<state x="1060" y="455" key="FileChooserDialogImpl" timestamp="1614783953088">
<screen x="0" y="0" width="2560" height="1400" />
</state>
<state x="1060" y="455" key="FileChooserDialogImpl/0.0.2560.1400/2560.0.1920.1040@0.0.2560.1400" timestamp="1614783953088" />
</component>
</project>
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment