Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add PySiddhi support for siddhi 4.3.x and minor fixes #20

Merged
merged 1 commit into from
Jan 2, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions Tests/SPTests/EventSimulatorTests.py
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ def testDBSimulationOneSource(self):
"simulationType": "DATABASE_SIMULATION",
"streamName": "FooStream",
"siddhiAppName": "TestSiddhiApp",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false",
"driver": "com.mysql.jdbc.Driver",
"username": "root",
"password": "root",
Expand All @@ -372,7 +372,7 @@ def testDBSimulationOneSource(self):
s1 = SimulationSource(simulationType=SimulationSource.Type.DATABASE_SIMULATION)
s1.streamName = "FooStream"
s1.siddhiAppName = "TestSiddhiApp"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false"
s1.driver = "com.mysql.jdbc.Driver"
s1.username = "root"
s1.password = "root"
Expand Down Expand Up @@ -411,7 +411,7 @@ def testDBSimulationTwoSource(self):
s1 = SimulationSource(simulationType=SimulationSource.Type.DATABASE_SIMULATION)
s1.streamName = "FooStream"
s1.siddhiAppName = "TestSiddhiApp"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false"
s1.driver = "com.mysql.jdbc.Driver"
s1.username = "root"
s1.password = "root"
Expand All @@ -438,7 +438,7 @@ def testDBSimulationTwoSource(self):
"simulationType": "DATABASE_SIMULATION",
"streamName": "FooStream",
"siddhiAppName": "TestSiddhiApp",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false",
"driver": "com.mysql.jdbc.Driver",
"username": "root",
"password": "root",
Expand All @@ -450,7 +450,7 @@ def testDBSimulationTwoSource(self):
"simulationType": "DATABASE_SIMULATION",
"streamName": "FooStream",
"siddhiAppName": "TestSiddhiApp",
"dataSourceLocation": "jdbc:mysql://localhost:3306/Simulation",
"dataSourceLocation": "jdbc:mysql://localhost:3306/Simulation?useSSL=false",
"driver": "com.mysql.jdbc.Driver",
"username": "root",
"password": "root",
Expand All @@ -469,7 +469,7 @@ def testDBSimulationTwoSource(self):
s1 = SimulationSource(simulationType=SimulationSource.Type.DATABASE_SIMULATION)
s1.streamName = "FooStream"
s1.siddhiAppName = "TestSiddhiApp"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false"
s1.driver = "com.mysql.jdbc.Driver"
s1.username = "root"
s1.password = "root"
Expand All @@ -481,7 +481,7 @@ def testDBSimulationTwoSource(self):
s2 = SimulationSource(simulationType=SimulationSource.Type.DATABASE_SIMULATION)
s2.streamName = "FooStream"
s2.siddhiAppName = "TestSiddhiApp"
s2.dataSourceLocation = "jdbc:mysql://localhost:3306/Simulation"
s2.dataSourceLocation = "jdbc:mysql://localhost:3306/Simulation?useSSL=false"
s2.driver = "com.mysql.jdbc.Driver"
s2.username = "root"
s2.password = "root"
Expand Down Expand Up @@ -520,7 +520,7 @@ def testDBSimulationOneSourceWOColumnNames(self):
"simulationType": "DATABASE_SIMULATION",
"streamName": "FooStream",
"siddhiAppName": "TestSiddhiApp",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false",
"driver": "com.mysql.jdbc.Driver",
"username": "root",
"password": "root",
Expand All @@ -542,7 +542,7 @@ def testDBSimulationOneSourceWOColumnNames(self):
s1 = SimulationSource(simulationType=SimulationSource.Type.DATABASE_SIMULATION)
s1.streamName = "FooStream"
s1.siddhiAppName = "TestSiddhiApp"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false"
s1.driver = "com.mysql.jdbc.Driver"
s1.username = "root"
s1.password = "root"
Expand Down Expand Up @@ -752,7 +752,7 @@ def testDBandCSVSimulation(self):
"simulationType": "DATABASE_SIMULATION",
"streamName": "FooStream",
"siddhiAppName": "TestSiddhiApp",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation",
"dataSourceLocation": "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false",
"driver": "com.mysql.jdbc.Driver",
"username": "root",
"password": "root",
Expand Down Expand Up @@ -783,7 +783,7 @@ def testDBandCSVSimulation(self):
s1 = SimulationSource(simulationType=SimulationSource.Type.DATABASE_SIMULATION)
s1.streamName = "FooStream"
s1.siddhiAppName = "TestSiddhiApp"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation"
s1.dataSourceLocation = "jdbc:mysql://localhost:3306/DatabaseFeedSimulation?useSSL=false"
s1.driver = "com.mysql.jdbc.Driver"
s1.username = "root"
s1.password = "root"
Expand Down
2 changes: 1 addition & 1 deletion Tests/SiddhiCoreTests/Resources/Extensions4/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

<groupId>org.wso2.siddhi-python-api</groupId>
<artifactId>siddhi-python-api-extensions-downloader-for-tests</artifactId>
<version>1.0.1</version>
<version>1.1.0</version>
<description>Downloads extensions (JARS) used by Siddhi Python API Tests</description>
<packaging>pom</packaging>

Expand Down
12 changes: 10 additions & 2 deletions __PySiddhi4Proxy/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@

<groupId>org.wso2.siddhi-python-api</groupId>
<artifactId>siddhi-python-api-proxy-4</artifactId>
<version>1.0.1</version>
<version>1.1.0</version>

<dependencies>
<dependency>
<groupId>org.wso2.siddhi</groupId>
<artifactId>siddhi-core</artifactId>
<version>4.1.17</version>
<version>4.3.7</version>
</dependency>


Expand Down Expand Up @@ -123,6 +123,14 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
</plugin>
</plugins>
</build>

Expand Down
3 changes: 2 additions & 1 deletion __PySiddhi4Proxy/threadfix_c_code/makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ JAVAHOME = ${JAVA_HOME}

LINUX_PYTHON_PATH = /usr/include/python

MACOS_PYTHON_PATH = /usr/local/var/homebrew/linked/python/Frameworks/Python.framework/Versions/3.6/include/python3.6m
# Please provide the python path according to the python version of the machine
MACOS_PYTHON_PATH = /usr/local/var/homebrew/linked/python/Frameworks/Python.framework/Versions/3.7/include/python3.7m

OS = ${shell uname}

Expand Down
8 changes: 5 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ def run(self):

setup(
name="PySiddhi4",
version="1.0.1",
version="1.1.0",
packages=filtered_packages,
python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, <4',
install_requires=["requests","pyjnius", "future", "enum34 ; python_version<'3.4'"],
python_requires='>=2.7, ~=3.5',
install_requires=["requests","pyjnius", "future", "enum34 ; python_version<'4'"],
package_data={
"PySiddhi4": ["../__PySiddhi4Proxy/target/lib/*.jar",
"../__PySiddhi4Proxy/target/*.jar",
Expand All @@ -69,11 +69,13 @@ def run(self):
'Natural Language :: English',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX :: Linux',
'Operating System :: MacOS'
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Topic :: Software Development :: Libraries :: Java Libraries'
]
)