Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link

arumugarani sundaram

Greenhorn
+ Follow
since Nov 24, 2014
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
2
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by arumugarani sundaram

Hi,

Actually a BasicDBObject class is a list of Objects.
While querying you can directly cast to a DBObject. if you are not sure about what the object is, then you can add check whether the object is instanceOf DBObject.



if you are not sure about what the object is, then you can add check whether the object is instanceOf DBObject as below



Thanks,
Arumugarani
6 years ago
Hi,

mongo is a document data store. So, I think as far as ingredient and product tables are considered, you can have it as separate collection in mongo. If we come to manufacture part, we can club both the tables into a single collection manufacture where manufacture detail will be an array element of nested structure

So, ideally the manufacture collection will look like

{

manufacure_id:1,
manufacture_name:"sample",
manufacutre_plant:"test",
...
manufacture_details:
[
{
ingredient_id:1,
product_id:111
},
{
ingredient_id:2,
product_id:111
},
{
ingredient_id:3,
product_id:111
},
{
ingredient_id:1,
product_id:112
},
{
ingredient_id:5,
product_id:112
},
{
ingredient_id:3,
product_id:112
}
]
}

Hope it helps.

Thanks,
Arumugarani
7 years ago
Hi,

Please try to understand HDFS is distributed file system. If you design the system as clustered ones, the data will be split into multiple segments/chunks and distributed across clustered environment. bin/hadoop dfs ---------> it means that you are listing from HDFS not from an ordinary file system.

Hope you understand this.

The input will say that where the input files are available for processing and the output says where the processed output files are available.

Think of a file that contains the phone number for everyone in the country X; the people with a last name starting with A might be stored on server 1, B on server 2, and so on. In a Hadoop world, pieces of this phonebook would be stored across the cluster. To achieve availability as components fail, HDFS replicates these smaller pieces onto two additional servers by default.This redundancy offers multiple benefits, the most obvious being higher availability. When you query the HDFS, the data from clustered servers will be combined and re-constructed as a single one.

Hope this helps you to understand.

Thanks,
Arumugarani
7 years ago
The details in the question are not very clear. But, in our jboss server we used to map all the path params with slash /.

@Path("/{bill-id}/request")
@Path("/{user-id}")

Thanks,
Arumugarani
7 years ago
I am not very sure whether this solution helps you..

we can use context.write(key,value).. which will write the mapper results into output path. If you want the results to be written into some specific format, you can write you own customized calss for output format and you can use it in you context.write.

If you want a detailed answer, please describe the sample input and output and share your Mapper class.

Thanks,
Arumugarani

7 years ago
Hi,


I feed like xmlparse class itself has some issues.

did you check xmlparse output class? Is it displaying the results?

can you post your xml to debug further?

Thanks,
Arumugarani
7 years ago
Hi,

Mongo the querying part is kind of very easy.


I am not very sure how your json document is structured. You have given in the sampe "dept" param inside "stu" and "stu1". Is it valid? Suppose if you have 10 students, will you have stu1,stu2... not sure about json doc..

suppose your json doc is

{"_id":<MongoId>
"stu":{
"dept": "mca",
"place":"chennai"
}
}

Then another doc with

{"_id":<MongoId>
"stu":{
"dept": "mba",
"place":"chennai"
}
}

.....



{"_id":<MongoId>
"stu":{
"dept": "mca",
"place":"chennai"
}
}


Then your query param dept is inside "stu" object

So in mongo shell, you can query like

db.<collectionname>.find({"stu.dept":"mca"})


Hope this helps:)
7 years ago
String sql="SELECT node_id FROM node_group WHERE group_id=? and group_value=?";
SQLQuery query=session.createSQLQuery(sql);
query.setLong(0,id);
query.setBigDecimal(1,bigDecimalGroupValue);
List list=query.list();
return list;
I think the loop itself is not right to me.

I don't know android programming
but if you want to delay some activity you can use Thread.sleep for some fixed seconds

Hope this helps.
7 years ago