web service with cache for oracle db
alexgruperm / ws_ora Goto Github PK
View Code? Open in Web Editor NEWweb service with cache for oracle db
web service with cache for oracle db
We need a constructor with parameters LONG, CNT.
to eliminate code like this
WsStat(
currTs, 0,
new FixedList[CacheGetElm](cfg.getcntHistoryDeep),
new FixedList[CacheCleanElm](cfg.getcntHistoryDeep),
new FixedList[ConnStat](cfg.getcntHistoryDeep)
)
in def refCache
In response, we need the source of data: cache, db
For example:
{
"status" : "ok",
"src" : "cache",
"data" : {
...
Change output json format from "by cells" into array of array
"rows" : [
[
{
"name" : "ID",
"value" : "2"
},
{
"name" : "PARENT_ID",
"value" : "null"
},
{
"name" : "NAME",
"value" : "Контрактация"
},
{
"name" : "IS_EXISTS_META_PROPS",
"value" : "0"
}
],
to
[
[
{"ID" : 5},
{"PARENT_ID" : null},
{"NAME" : "Показатели"},
{"IS_EXISTS_META_PROPS" : 1}
],
[
{"ID" : 6},
{"PARENT_ID" : 5},
{"NAME" : "Показатели 2"},
{"IS_EXISTS_META_PROPS" : 0}
]
]
Now in "reftables" parameter we set the list of tables on which the cache item depends, for example
"reftables" : [
"admin.t_roles",
"admin.t_users_roles",
"data.table1",
"storage.table2"
]
We need to use masks:
"reftables" : [
"*.*"
]
"reftables" : [
"admin.*",
"data.table1",
"storage.table2"
]
Simple query (four numeric columns)
select * from XXXXX where rownum <= 8000
takes about 27 seconds.
In file Main.scala we need rewrite the run method and eliminate using
Runtime.global.unsafeRun
Service return for PKG_WIDGET.GET_DASHBOARD
"is_widget" => 1.0
"icon_add_basic_set" => 1.0
we need exactly
"is_widget" => "1"
"icon_add_basic_set" => "1"
We need to use the mode parameter convType str(default), num in function getColumnWsDatatype
to fetch all columns from DataSet with getString or getXXX -depends on column type.
For example, instead of
"reftables" => ["msk_arm_lead.widget_meta_property",
"msk_arm_lead.widget_type"]
we can use
"reftables" => ["msk_arm_lead.widget_*"]
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.